Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

rustbasic
Copy link
Contributor

@rustbasic rustbasic commented Aug 17, 2024

Function to specify Align to Label

There are cases where you want to display Label on the left or right regardless of other Layout specifications.

Before : Note the part showing the rust source code.
20240818-1

After : Note the part showing the rust source code.
20240818-2

@rustbasic rustbasic changed the title Function to specify Align to Lable Function to specify Align to Label Aug 18, 2024
@bircni
Copy link
Contributor

bircni commented Aug 18, 2024

maybe change the function name to text_align as this only aligns the text inside the label not the label itself

@rustbasic
Copy link
Contributor Author

maybe change the function name to text_align as this only aligns the text inside the label not the label itself

Yes, that would be great too. Let's wait for emilk's review.

@emilk emilk changed the title Function to specify Align to Label Add Label::halign Aug 26, 2024
@emilk emilk added egui feature New feature or request labels Aug 26, 2024
@emilk emilk merged commit 47c0aeb into emilk:master Aug 26, 2024
486c pushed a commit to 486c/egui that referenced this pull request Oct 9, 2024
Function to specify `Align` to `Label`

There are cases where you want to display `Label` on the left or right
regardless of other `Layout` specifications.

Before : Note the part showing the rust source code.

![20240818-1](https://github.com/user-attachments/assets/a08f7594-1ec1-4c6a-b96d-1a5f735d02c1)

After : Note the part showing the rust source code.

![20240818-2](https://github.com/user-attachments/assets/807ff9cf-f8cd-4415-9c78-b62869d1696d)

---------

Co-authored-by: Emil Ernerfeldt <[email protected]>
hacknus pushed a commit to hacknus/egui that referenced this pull request Oct 30, 2024
Function to specify `Align` to `Label`

There are cases where you want to display `Label` on the left or right
regardless of other `Layout` specifications.

Before : Note the part showing the rust source code.

![20240818-1](https://github.com/user-attachments/assets/a08f7594-1ec1-4c6a-b96d-1a5f735d02c1)

After : Note the part showing the rust source code.

![20240818-2](https://github.com/user-attachments/assets/807ff9cf-f8cd-4415-9c78-b62869d1696d)

---------

Co-authored-by: Emil Ernerfeldt <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

egui feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants