I'd like to know if in my TeX
editor, TeXstudio
, the buttons can be customized? i.e:
The marked button produces $ $
, and I'd like to have ${}$
This other button produces \\
and I'd like to have
\par
%
Is that possible?
I don't know if you can edit existing buttons, but you can make new ones, and you can have them insert arbitrary code.
Go to Macros --> Edit macros, and make a new macro with the code you want inserted in the "LaTeX content" box:
The %|
construct is a placeholder only, it indicates where the cursor is placed when you use this macro.
(See Help --> User manual, the section on "Personal macros". See also Defining New ShortCuts in TexStudio)
Go to Options --> Configure TeXstudio, and look in the Toolbars tab. The toolbar you want to modify is called "Central", so choose that in the first drop-down menu. In the second drop-down menu, choose "All menus". Find the macro you just created, and doubleclick to move it over to the toolbar:
You can choose a different icon by right clicking on the toolbar entry and navigating to an image file. (I don't know where you can find the ones that TeXstudio uses.)
You can move items up and down by dragging with the mouse
You don't really want to always use ${ .. }$
for inline math, for one thing it inhibits line breaking. And why use \par
, and not just an empty line?
${ }$
? (Probably not a good idea.)\par
in a document and${}$
similarly is somewhat dangerous to add automatically since{}
in math mode typically affects spacing.