Bug 127956 - Can't scale Equation Box when typing the equation
Summary: Can't scale Equation Box when typing the equation
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Formula Editor (show other bugs)
Version:
(earliest affected)
6.3.1.2 release
Hardware: All All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: needsDevAdvice
Depends on:
Blocks: Formula-Editor
  Show dependency treegraph
 
Reported: 2019-10-03 19:18 UTC by Arian
Modified: 2019-10-08 13:45 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 Arian 2019-10-03 19:18:35 UTC
Description:
While writing the eqaution in LibreOffice Draw as the equation get to a certain length, the text box of the equation will remain of the same size and you cannot scale up or down while writing he equation neither you can scale it out of "equation mode" as I call it. Could a dynamic resizing be added so that the size of the box changes with the size of the equation while you're typing it?

Steps to Reproduce:
1.Type a equation longer than of the size of the box.
2.when the equation gets too big some parts will not be visible.
3.Try scaling the box.

Actual Results:
Cannot scale although the cursor changes to the arrows that would usually indicate that you can scale something.

Expected Results:
I would expect that you could scale the text box for the equation at leats while writing the equation


Reproducible: Always


User Profile Reset: No



Additional Info:
Comment 1 Xisco Faulí 2019-10-04 13:41:56 UTC
resizing equations was possible for a while, but the commit was reverted
https://cgit.freedesktop.org/libreoffice/core/commit/?id=51221bbf0c7cca0a329393dac2059818006ab338
as it introduced another problem.
Closing as a duplicate of bug 85860

*** This bug has been marked as a duplicate of bug 85860 ***
Comment 2 V Stuart Foote 2019-10-04 14:54:49 UTC
Not really true.

When you are entering your formula you are creating a StarMath (sm) syntax OLE object. The "equation mode" is the OLE linkage to LibreOffice's sm Math formula editor module.

When you first insert your formula, a default OLE sm object of fixed size is positioned on canvas--but the formula entry is then performed in the Math editor

From Draw or another LO module, you do not graphically control the OLE object, you can only reposition and anchor it. 

Precise layout of the sm Formulas (composition of it 'nodes') is done from the Formula editor's Format menu (it is present working in OLE mode or directly in Math)--setting font, size and spacing for the layout of the fonts. But, simple scaling of the formulas is done by wrapping them in a size ## { } stanza. ## pretty much any number.

The rendered size of the OLE on the document canvas will not change until the OLE is refreshed by returning to the document canvas--Draw in this case. The OLE object's grips will expand to the new bounds, and the formula can be repositioned as needed. But in effect you can scale it, just not graphically.

bug 99792 is open to make the OLE grips functional for resize after OLE edits are complete.

So some question if dynamic resize of the OLE object's frame while entering formula from OLE mode would really be a good UX.
Comment 3 V Stuart Foote 2019-10-04 15:01:08 UTC
(In reply to Xisco Faulí from comment #1)
> resizing equations was possible for a while, but the commit was reverted
> https://cgit.freedesktop.org/libreoffice/core/commit/
> ?id=51221bbf0c7cca0a329393dac2059818006ab338
> as it introduced another problem.
> Closing as a duplicate of bug 85860
> 

Not really the issue here. sm Formulas are a strange beast--their OLE frame responds only to the node composition as defined in the Formula editor. There is no linkage for them to respond to changes in their Frame.
Comment 4 Heiko Tietze 2019-10-08 12:15:45 UTC
It scales with typing in Writer, not sure why it shouldn't in Draw/Impress. Alternatively we could automatically scroll to the end of the window.
Comment 5 V Stuart Foote 2019-10-08 13:45:04 UTC
(In reply to V Stuart Foote from comment #2)
> 
> The rendered size of the OLE on the document canvas will not change until
> the OLE is refreshed by returning to the document canvas--Draw in this case.
> The OLE object's grips will expand to the new bounds, and the formula can be
> repositioned as needed. But in effect you can scale it, just not graphically.
> 


(In reply to Heiko Tietze from comment #4)
> It scales with typing in Writer, not sure why it shouldn't in Draw/Impress.
> Alternatively we could automatically scroll to the end of the window.

OK, setting a 'size ## {' does behave differently--Draw & Impress vs Writer & Calc. Draw & Impress you have to leave the OLE module for the resulting frame to update canvas and scale. But in Writer and Calc the update will refresh its frame on canvas without leaving the OLE module. Toward implementing bug 99792 guess the behavior should be made the same.