Skip to content
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

Plans to implement align support? #327

Closed
1 task
Speiger opened this issue Oct 30, 2023 · 5 comments
Closed
1 task

Plans to implement align support? #327

Speiger opened this issue Oct 30, 2023 · 5 comments

Comments

@Speiger
Copy link

Speiger commented Oct 30, 2023

Mod loader

Forge

Minecraft version

1.19.2 or newer

Mod version

Any

Modloader version

Any

Modpack info

non

If bug:

  • Can you reproduce this issue with relevant mods only?

If bug: The latest.log file

No response

Issue description

Are there plans to implement align support?
I don't mean the "left/right" row that already exists, but actual Text Alignment support?

Technically i use the one probe, but i have seen a lot of jade requests and after a addon maker made it work we saw that there isn't any support for text alignments.

Because we do have some cases where that would be useful. For example category headers.
(Screenshot by CrossVas who made the addon)
image

Growth/Stats/Storage/Environment are headers that we align actually in TOP because it looks better centered.

Or do we have to implement these ourselves?

@Snownee
Copy link
Owner

Snownee commented Oct 31, 2023

It is pretty easy to do it by creating a custom element. I will do it, but I haven't decided how to make it part of the API yet.

@Speiger
Copy link
Author

Speiger commented Oct 31, 2023

I know its easy to implement,
and via API, maybe have a component specific interface? That way configurations can be added afterwards?
like: ITextElement, IProgressElement, etc,
Or move it into the style implementation like TOP does it?

@Speiger
Copy link
Author

Speiger commented Nov 6, 2023

@Snownee thank you, though you kinda failed the assignment.
The question was: Do we get text alignment support.
You add a function that implements 1 possibility because I specifically mentioned it.
Would you like another issue be opened for right aligned text support or do you plan not to add that too?

@Snownee
Copy link
Owner

Snownee commented Nov 6, 2023

I'm not happy with the current implementation, so I plan to make the alignment element-based, which means adding an Align.CENTER.

@Speiger
Copy link
Author

Speiger commented Nov 6, 2023

@Snownee i would move the alignment function to the "add" function as a optional way to add things.
And make the align function that you have based on the component instead of based on the registration part.

Snownee added a commit that referenced this issue Nov 8, 2023
Snownee added a commit that referenced this issue Dec 8, 2023
Snownee added a commit that referenced this issue Dec 8, 2023
Snownee added a commit that referenced this issue Dec 23, 2023
Snownee added a commit that referenced this issue Dec 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants