-
-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Increasing label font size without specifying a width causes the text to clip #47
Comments
Hi, can you use the git version os haxeui-* (include hxWidgets). Just to see if the behaviour is the same (it very we may be). Cheers, |
I tried to use the git versions for all of them, but I wasn't able to for
With this setup, the clipping issue is the same. When I did try to build with
I do notice that |
try something like:
the active version is surrounded by "[" and "]" so you want them all to say "[git]" (dont worry about hxcpp though, that one is fine) |
Ah, I was wondering what those brackets meant (very new to Haxe 😅). Not sure what's different about those commands compared to what I did before (maybe I used the SSH git URL or something silly), but it worked this time:
Unfortunately, the clipping issue is still present. |
OK, thats fine then, its not a version issue its an issue that has been present since "forever"... thanks for confirming! Cheers, |
Expected Behavior
The label should increase in size to fit the text inside it instead of clipping the text. This is the behavior observed in other backends I've tried (
html5
,heaps-hl
); it only seems to clip while using thehxwidgets
backend.Current Behavior
The label doesn't scale to fit the text it contains if you change the font size via CSS. The label retains its dimensions as if the default font size were used, thus clipping the text if the font size is bigger than default. This only seems to occur if the width of the label isn't specified.
Steps to Reproduce (for bugs)
hxwidgets
backend (haxelib run haxeui-core create hxwidgets
)assets/main-view.xml
(e.g.<label text="this text will clip" style="font-size:30px" />
)Media
Using the
![image](https://private-user-images.githubusercontent.com/2818781/267120555-13dc1877-d74b-46b9-a11e-3dbbb794ae4a.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjU3NDYyODQsIm5iZiI6MTcyNTc0NTk4NCwicGF0aCI6Ii8yODE4NzgxLzI2NzEyMDU1NS0xM2RjMTg3Ny1kNzRiLTQ2YjktYTExZS0zZGJiYjc5NGFlNGEucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDkwNyUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA5MDdUMjE1MzA0WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9ZjM2NDg0YTY5ZTgwNTcyNWQ2NTE3MTVlMjAwN2UxY2ZlNGFmZTA4MWRhOTdmOTE4NWI1N2FjM2Y1Y2JjYzgxZSZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.Cgs-mpx1vgXzddDlDtTqWHAGD1l71awtmXGTKWxdXCQ)
heaps-hl
backend (no clipping):Same code using the
![image](https://private-user-images.githubusercontent.com/2818781/267120749-bbc8c610-f0a8-4ad3-a506-226ca53fcd83.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjU3NDYyODQsIm5iZiI6MTcyNTc0NTk4NCwicGF0aCI6Ii8yODE4NzgxLzI2NzEyMDc0OS1iYmM4YzYxMC1mMGE4LTRhZDMtYTUwNi0yMjZjYTUzZmNkODMucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDkwNyUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA5MDdUMjE1MzA0WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9N2E2YjU4NzUwNDUxODJiMTdmNzk2Mjk1MzdlNDYzYTVjMTk0NmVlZDE2ZWM0NTIzYWQ1MWIxNjBlYzhjMjRjNiZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.401Im4So29oHTO0x_a2jmWiDJNWyRUwjKLHZgAi8Hoc)
hxwidgets
backend (clipping):Code that produced these screenshots below.
Test app / minimal test case
Default
hxwidgets
app with the following modifications:assets/main-view.xml
:src/MainView.hx
:Your Environment
Replicated in:
The text was updated successfully, but these errors were encountered: