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

Added "cx" and "cy" property to the label to change center of Label #22

wants to merge 4 commits into
base: master


Copy link

neoxharsh commented Oct 22, 2019

I have added "cx" and "cy" property to the label, such that setting those will move the center of the text rather than the top left corner of the text. My apologies if it is already available.

Eg. for PyPortal

timeDisplay = label.Label(font,text='12:60:60',color=color) = 160 = 120

This comment has been minimized.

Copy link

tannewt commented Nov 2, 2019

I like how you are using the Group's x and y to handle this! I'd rather not add separate cx and cy properties though. Instead, I'd like to see one or two properties that set the anchor position. Right how it's fixed as Center Left but you'd like Center Center.

With the anchor property, changes to the bounding box, x, or y (overridden) would trigger changing the Group's x and y.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
2 participants
You can’t perform that action at this time.