Bug 163685 - Provide ability for user to add - remove formula examples to the sm Elements -> Examples panel
Summary: Provide ability for user to add - remove formula examples to the sm Elements ...
Status: ASSIGNED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Formula Editor (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium enhancement
Assignee: Heiko Tietze
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Formula-Editor Elements-Pane
  Show dependency treegraph
 
Reported: 2024-10-30 11:46 UTC by sm8ps
Modified: 2024-11-19 17:05 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description sm8ps 2024-10-30 11:46:02 UTC
I commonly use certain types of formulae over and over and it would be nice if I could somehow embed them into the pre-defined examples. In fact, I have never used any of those so it would be great if there was a way to edit the list of samples altogether. I have not been able to poinpoint the location of the given samples in my filesystem so I suppose they are somehow embedded in the source-code.

Maybe the most comfortable would be loading the examples from a certain location that could be a configurable path, similar to templates in Writer.

Thanks for any comments and consideration, and many thanks for the great office 
suite!
Comment 1 V Stuart Foote 2024-10-30 12:29:30 UTC
The examples are hard coded in source. Currently no means via UI and profile to modify the examples or provide user curated collection of their preferred formula.

But agree that would be a good enhancement to the sm Formula editor. Doubly so given the pain most LaTeX users have with formula entry (e.g. bug 73593 or bug 96208) allowing a means to do the entry/conversion once and have it available would be helpful.

=-ref-=  

[1] https://opengrok.libreoffice.org/xref/core/starmath/source/ElementsDockingWindow.cxx
Comment 2 V Stuart Foote 2024-10-30 12:31:49 UTC
A more direct link to the formula examples in the Elements panel:

https://opengrok.libreoffice.org/xref/core/starmath/source/ElementsDockingWindow.cxx?r=c37022ff#436
Comment 3 Heiko Tietze 2024-10-31 09:07:32 UTC
I'd rather go with another category "User-defined". When selected we show an Add button (and Delete) that allows to store the current function.
Comment 4 V Stuart Foote 2024-10-31 11:38:48 UTC
(In reply to Heiko Tietze from comment #3)
> I'd rather go with another category "User-defined". When selected we show an
> Add button (and Delete) that allows to store the current function.

That makes a lot of sense! Just leave the hardcoded examples alone. And probably cleanest UI as a new SB deck. Feasible since Mike migrated the Elements and Properties panels into the SB framework (bug 125931).

Also would imagine such "User-defined" StarMath/MathML snippets would go into a path on the user's profile with a config folder there (similar to autocorr and autotext), and not dumped into the registrymodifications.xcu
Comment 5 sm8ps 2024-11-05 17:14:20 UTC Comment hidden (off-topic)
Comment 6 Heiko Tietze 2024-11-06 07:28:32 UTC Comment hidden (off-topic)