caolanm at redhat.com
Fri Mar 5 12:17:26 UTC 2021
On Fri, 2021-03-05 at 12:17 +0100, Dante Doménech wrote:
> I'm trying to find a piece of code.
> When you run ./instdir/program/soffice --math for opening the math
> module there must be a point in which you initialize everything
> (smviewshell, smdochell, smeditwindow, smelementsdockingwindow, ...).
> The question is where can I find that code?
You can launch in a debugger and set breakpoints in their ctor to see
when they are created. SmModule::SmModule should be the first thing
called, but just once, so its possible that SmModule is useful to you.
On a typical startup then a SmDocShell is created, followed by
SmViewShell, SmEditWindow (which itself owns another embedded
SmDocShell) and SmElementsDockingWindow.
SmCmdBoxWrapper (which owns the SmEditWindow) and
SmElementsDockingWindow are registered to be created for SmViewShell at
So the launching code somewhere in sfx will create a SmDocShell and
then create a SmViewShell to put it into to and create all those
registered childwindows for the SmViewShell
More information about the LibreOffice