Benjamin Otte
0a4c08a7be
inscription: Multiparagraph text is always multiline
...
Wrap this text and clip towards the bottom, no matter how high the
inscription is.
2022-06-13 06:49:12 +02:00
Benjamin Otte
883011f252
inscription: Do not try to align layouts that have a proper width set
...
Pango knows where to put the text.
2022-06-13 06:49:12 +02:00
Georges Basile Stavracas Neto
c93a01d627
Inscription: Derive row alignment from xalign
...
Texts usually want the alignment of each row to match the xalign of
the text itself.
Derive the alignment of the PangoLayout from the xalign property of
the inscription. Because Pango doesn't provide float row alignment,
map left, center and right from the xalign in 1 / 3 steps.
2022-06-13 05:35:47 +02:00
Benjamin Otte
6d15549f51
inscription: Add ::wrap-mode
...
We use a different wrap-mode than GtkLabel, because we cannot just
resize the widget to make long words fit, we have to fit the size we are
given.
2022-06-12 03:10:50 +02:00
Benjamin Otte
393ef4d0a2
inscription: Fixate layout at top when it doesn't fit
...
Ellipsized and clipped layouts shouldn't reposition themselves according
to yalign when they don't fully fit.
2022-06-11 16:28:27 +02:00
Benjamin Otte
bf5edc6b7c
reftests: Add test for the overflow methods
...
Reference is using labels again
2022-06-11 02:15:08 +02:00
Benjamin Otte
7c034cc283
inscription: Set css name
...
We use "label" just like GtkLabel as the two widgets differ in the way
they are measured, but they should be styled the same.
If it turns out we change our opinion on this for specific cases, we
can add style classes later.
2022-06-11 02:15:08 +02:00
Benjamin Otte
e437a9c348
inscription: Add a11y support for text interface
...
This is entirely untested.
2022-06-11 02:15:08 +02:00
Benjamin Otte
1517c1813c
inscription: Add ::text-overflow
...
Can't name it ::overflow, because that's taken by GtkWidget already
2022-06-11 02:15:08 +02:00
Benjamin Otte
01fcfc5c2a
inscription: Add ::markup
...
Utility property that sets both the ::text and ::attributes properties,
mainly intended for use in ui files to ease translation support and bindings.
2022-06-11 02:15:08 +02:00
Benjamin Otte
3f4c88aad1
inscription: Add ::attributes property
2022-06-11 02:15:08 +02:00
Benjamin Otte
b6a8080b2f
Add GtkInscription
...
A label alternative that renders itself into a given rectangle.
The main use case is cells in column view.
Related: #3334
2022-06-09 05:58:27 +02:00