Ask Your Question

Dafault superscript relative size [closed]

asked 2012-11-30 00:56:45 +0100

ReTango gravatar image

Hi, I am writing mathematical documents on writer, and I use a lot superscript. I use the standard short-cut: ctrl-shift-p. I recently discovered that I can change the relative size of the superscript, which is great because the default size is too small for me. If I select a charcater that is already as superscript, I go to "Character Format" -> Position, uncheck "Automatic", set "Raise/lower by" to 25%, and "Relative font size" to 25%. It works perfectly. However, when I am typing and enter a new superscript, it goes again with the default value: "Automatic" checked, Raise/lower by" at 33% (grayed), and "Relative font size" at 58%. This is annoying since I have to re-edit each superscript. As soon as I uncheck "Automatic", Libreoffice remembers the 25% and 75% values, but anyway I have to go into each superscript and edit it. Is there a way I can set the default superscript (the one that appears when I press ctrl-shift-p) to my own values?

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by Alex Kemp
close date 2015-10-19 02:39:06.375042

2 Answers

Sort by » oldest newest most voted

answered 2012-11-30 01:42:51 +0100

CyanCG gravatar image

When using the shortcut ctrl-shift-p, what is applied is actually manual formatting instead of a character style. If you wish to repeatedly use the same superscript formatting, the best solution is the following:

  1. create a new character style with the desired superscript properties;

  2. assign this character style to a custom keyboard shortcut via the “Tools > Customize” menu (the shortcuts are defined under the “customize keyboard” tab);

  3. apply this character style using the defined keyboard shortcut.

If you want to automatically apply your custom character style to existing, manually-formatted superscripts, the easiest way right now is to use the “Alternative Search and Replace Dialog” extension, which can be found on the LibreOffice extensions website. With this extension, you can search for and apply a style to all instances of a given manual formatting.

edit flag offensive delete link more

answered 2012-11-30 02:24:51 +0100

ReTango gravatar image

Dear CyanCG, Thanks a lot for the prompt response! I already did that and it worked almost perfectly. There is a small point though.. with the standard "ctrl-shift-p" shortcut, I was able both to turn on and off superscript. If I assign this shortcut to my newly defined style, I can only use the shortcut to turn on superscript.. I press it again and it does not turn it off. I imagine I can define a new shortcut (different from "ctrl-shift-p") that sets the character style to "Default" and thus turns off superscript.. But I would need two different shortcuts. Is there a way I can have the shortcut to the new style turn superscript both on and off ? Thanks a lot again!!

edit flag offensive delete link more


Assigning a shortcut to the default style is what I do myself, but as for having the same shortcut conditionally turn the style on or off... I don't know. Maybe scripting would be necessary. Or perhaps an advanced option in the keyboards shortcuts dialog would allow that?

CyanCG gravatar imageCyanCG ( 2012-12-01 00:57:04 +0100 )edit

By the way, if my answer suits you, could you mark it as accepted so that others who come across the question find the answer easily?

CyanCG gravatar imageCyanCG ( 2012-12-01 01:00:19 +0100 )edit

Of course, thanks a lot for the tip, I am already using it...

ReTango gravatar imageReTango ( 2012-12-03 19:31:21 +0100 )edit

You're very welcome, and I'll continue researching the issue of conditionally applying or removing a style with the same command. I am a novice when it comes to scripting and macros, but I'm sure there must be a way to do it programmatically.

CyanCG gravatar imageCyanCG ( 2012-12-03 21:45:20 +0100 )edit

Question Tools


Asked: 2012-11-30 00:56:45 +0100

Seen: 2,337 times

Last updated: Nov 30 '12