Labels and bounding boxes

63 views
Skip to first unread message

Hendrik S

unread,
Oct 2, 2018, 10:20:25 AM10/2/18
to MathGL
Hi Alexey, unfortunately I need a little support again.
It looks like a lot has changed regarding styling and size options.

1. Axis label: We use '@' to scale the axis label down a little (documentation: @ – smaller size ), but it seems the scaling factor has changed. Or is @ 'deprecated' and we should rather use option 'size -[somevalue]'?
2. The text in the bounding boxes is not vertical-center aligned anymore. I haven't found an option to control the positioning of the bounding box relative to the text (or vice versa).
    It seems that the text itself is somewhat shifted down a little. While the distance to the bottom line of the bounding box is fine, the distance to the top line seems to be too much.

Attached are a couple of images showing the previous state, the current state (with MathGL 2.4.2.1) and a diff image for two examples.
Thanks in advance,
   Hendrik
a_mgl_15x.jpg
a_mgl_2421.jpg
a_diff.jpg
b_mgl_15x.jpg
b_mgl_2421.jpg
b_diff.jpg

Alexey Balakin

unread,
Oct 12, 2018, 10:51:25 AM10/12/18
to mat...@googlegroups.com
Dear Hendric,

I'm sorry for delay -- I was ill last week :(

02.10.2018 17:20, Hendrik S пишет:
> Hi Alexey, unfortunately I need a little support again.
> It looks like a lot has changed regarding styling and size options.
>
> 1. Axis label: We use '@' to scale the axis label down a little
> (documentation: @ – smaller size ), but it seems the scaling factor
> has changed. Or is @ 'deprecated' and we should rather use option
> 'size -[somevalue]'?
No, the @-style still working. But axis ticks are always use default
style, and I don't remember when it was differently. You should change
font style-and-size before the axis drawing.

> 2. The text in the bounding boxes is not vertical-center aligned
> anymore. I haven't found an option to control the positioning of the
> bounding box relative to the text (or vice versa).
>     It seems that the text itself is somewhat shifted down a little.
> While the distance to the bottom line of the bounding box is fine, the
> distance to the top line seems to be too much.
Don't understand this point??? Can you send an example and desired picture?

Kind regards,
Alexey Balakin

Hendrik S

unread,
Oct 15, 2018, 3:37:07 AM10/15/18
to MathGL


Am Freitag, 12. Oktober 2018 16:51:25 UTC+2 schrieb Alexey Balakin:
Dear Hendric,

I'm sorry for delay -- I was ill last week :(
No problem, hope you feeling better. :)
 
> 2. The text in the bounding boxes is not vertical-center aligned
> anymore. I haven't found an option to control the positioning of the
> bounding box relative to the text (or vice versa).
>     It seems that the text itself is somewhat shifted down a little.
> While the distance to the bottom line of the bounding box is fine, the
> distance to the top line seems to be too much.
Don't understand this point??? Can you send an example and desired picture?
I have attached an image with an example side by side. 
On the left, the bounding box around the "Point" label is fine. 
On the right (which is drawn with the latest MathGL) the upper boundary of the bounding box is too high. 
The spacing between the text and the upper boundary is twice the spacing between text and lower boundary. 


Kind regards,
Alexey Balakin
Untitled.png

Alexey Balakin

unread,
Oct 16, 2018, 9:55:24 AM10/16/18
to mat...@googlegroups.com
Dear Hendrik,

15.10.2018 10:37, Hendrik S пишет:
> 2. The text in the bounding boxes is not vertical-center aligned
> anymore. I haven't found an option to control the positioning of the
> bounding box relative to the text (or vice versa).
>     It seems that the text itself is somewhat shifted down a little.
> While the distance to the bottom line of the bounding box is fine, the
> distance to the top line seems to be too much.
Don't understand this point??? Can you send an example and desired picture?
I have attached an image with an example side by side. 
On the left, the bounding box around the "Point" label is fine. 
On the right (which is drawn with the latest MathGL) the upper boundary of the bounding box is too high. 
The spacing between the text and the upper boundary is twice the spacing between text and lower boundary.
I see. The problem is that formal font definition have very large space above the usual text (there are very tall symbols). Now, I take the full height for simplicity that cause extra space at upper boundary.

I'll make box drawing more accurate by taking actual height of symbols inside. I hope that I'll do it at weekend or early. Thank you for the issue.

Kind regards,
Alexey Balakin

Hendrik S

unread,
Oct 18, 2018, 4:57:57 AM10/18/18
to MathGL
That sounds great. Thanks for the effort.

Best,
   Hendrik

Alexey Balakin

unread,
Oct 26, 2018, 5:44:40 PM10/26/18
to mat...@googlegroups.com
Dear Hendrik,

I've just added this feature to the SVN [rev.1592]. You can check it.

Kind regards,
Alexey Balakin

18.10.2018 11:57, Hendrik S пишет:
--
You received this message because you are subscribed to the Google Groups "MathGL" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mathgl+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


-- 
Kind regards,
Alexey Balakin
Reply all
Reply to author
Forward
0 new messages