summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibGUI/Label.h
AgeCommit message (Collapse)Author
2021-07-29LibGUI: Do not wrap text in statusbar segmentssin-ack
This commit adds a new property to Label which allows one to enable or disable text wrapping. Statusbar now uses this property to disable text wrapping in its segments, since text wrapping in statusbars doesn't make sense.
2021-07-26Userland: Move text wrapping/elision into the new TextLayout :^)sin-ack
This class now contains all the fun bits about laying out text in a rect. It will handle line wrapping at a certain width, cutting off lines that don't fit the given rect, and handling text elision. Painter::draw_text now internally uses this. Future work here would be not laying out text twice (once actually preparing the lines to be rendered and once to get the bounding box), and possibly adding left elision if necessary. Additionally, this commit makes the Utf32View versions of Painter::draw_text convert to Utf8View internally. The intention is to completely remove those versions, but they're kept at the moment to keep the scope of this PR small.
2021-04-22Everything: Move to SPDX license identifiers in all files.Brian Gianforcaro
SPDX License Identifiers are a more compact / standardized way of representing file license information. See: https://spdx.dev/resources/use/#identifiers This was done with the `ambr` search and replace tool. ambr --no-parent-ignore --key-from-file --rep-from-file key.txt rep.txt *
2021-03-02LibGUI: Add word wrapping to Labelsthankyouverycool
Adds basic word wrap support to Label widgets. Doesn't yet negotiate autosize or Center/Bottom TextAlignments perfectly.
2021-01-12Libraries: Move to Userland/Libraries/Andreas Kling