How to make long texts automatically wrap to next line?

benice shared this question 6 years ago
Answered

Hi All,


I have two questions:


Q1:

I have a long FormulaText (FormulaText[f, true, true]) displayed in the graphics view.

How can I make it fit in with the graphics width and automatically wrap to next line?


Q2:

Is it possible to show only a part of an axis? (Please see the attached image.)


benice67494d03631a73b29ef63727f9c5c448

f63b813f8dbc0d20fc899379c61b3582

Comments (5)

photo
1

Q2: These is an option in version 4.2 where you can set the axis to show only positive values. But you can't automatically select to "blot out" a part of an axis. Not unless you hide the axis and constuct your own, which takes some time to do (alternatively being really clever with the Sequence command)


As for Q1 I don't think so but there is probably some clever LaTeX code for line breaks that you can insert if you build the formula yourself.

photo
1

Q2: These is an option in version 4.2 where you can set the axis to show only positive values. But you can't automatically select to "blot out" a part of an axis. Not unless you hide the axis and constuct your own, which takes some time to do (alternatively being really clever with the Sequence command)

Thanks for your kind reply. Currently I use a white rectangle to cover the unnecessary part of the y-axis.


As for Q1 I don't think so but there is probably some clever LaTeX code for line breaks that you can insert if you build the formula yourself.

I'm sorry, I forgot to say that the function f is arbitrary and its definition can be changed by the user through an Input Box.

photo
1

Q2: You can set the background color of the text to white (rather than transparent) using the Style Bar

photo
1

Hi, for Q1, I don't have a answer for all formulatexts because I cut anywhere : all the same value of length of the chain (so it can be within a formula + the text displayed does not have the same length than the formula text one) but maybe, it can be used as a start to improve.

Michel

https://ggbm.at/557945

photo
1

Q2: You can set the background color of the text to white (rather than transparent) using the Style Bar

Hi, thank you for the trick.


Hi, for Q1, I don't have a answer for all formulatexts because I cut anywhere : all the same value of length of the chain (so it can be within a formula + the text displayed does not have the same length than the formula text one) but maybe, it can be used as a start to improve.

Michel

Hi, thank you for the file. It works fine for normal text. For LaTeX text, the problem is that we cannot cut off the LaTeX control sequences.

© 2019 International GeoGebra Institute