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

Minor improvements to GUI system #1690

Merged
merged 11 commits into from
Jun 9, 2023

Conversation

eschan145
Copy link
Contributor

The parameter docs look very ugly and compacted with the native RST formatting. Switching to Google-style would also leave me with more space to fit more characters per line.

eschan145 and others added 5 commits April 4, 2023 16:08
Added a lot of documentation and a good tutorial on the GUI concepts. Also added more reStructuredText formatting.
Thanks @pushfoo!

Co-authored-by: Paul <36696816+pushfoo@users.noreply.github.com>
* Wrapped lines to eighty characters
I intend to add some more commits later. I have to say, though, this traditional RST parameter formatting looks really ugly and I may need to squish text into very small areas.

I additionally added a `caret_color` parameter to `UIInputText` allowing users to specify a color for the caret.
* Fixed extra trailing whitespace
* Fixed missing colon
* Fixed missing import
@einarf einarf requested a review from eruvanos April 7, 2023 16:26
arcade/gui/widgets/text.py Outdated Show resolved Hide resolved
arcade/gui/widgets/text.py Outdated Show resolved Hide resolved
arcade/gui/widgets/text.py Outdated Show resolved Hide resolved
arcade/gui/widgets/text.py Outdated Show resolved Hide resolved
Copy link
Member

@pushfoo pushfoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch on Caret being RGB-only in pyglet's source. That's something which needs to be addressed upstream. I'll give this PR a more thorough look later.

EDIT: I filed a ticket with pyglet checking for any blockers for making Caret take RGBA pyglet/pyglet#805

arcade/gui/widgets/text.py Outdated Show resolved Hide resolved
@eruvanos eruvanos added the gui Related to arcade GUI (sub module arcade.gui) label Apr 19, 2023
@eruvanos
Copy link
Member

@eschan145 For me it looks good in general, just fix the build error and we can merge it

@pushfoo
Copy link
Member

pushfoo commented May 2, 2023

Something may be wrong with Sphinx here. The error still occurs locally after removing the top-level docstring from UITextWidget.

Copy link
Member

@pushfoo pushfoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. It's actually the \n in UITextWidget.multiline causing the error; make it \\n
  2. Our Sphinx version is broken, but I have a fix for that too (see Fix doc build warning misattributions by upgrading Sphinx #1745)

I have further suggestions, but the above should get this building & mergable. Having trouble fixing this isn't OP's fault.

arcade/gui/widgets/text.py Outdated Show resolved Hide resolved
eruvanos and others added 2 commits May 9, 2023 20:44
@einarf
Copy link
Member

einarf commented Jun 9, 2023

Fixed the lingering issue with RGB just to check if things build. I'm guessing it should be RGBOrA, but I wasn't completely sure. @eruvanos knows?

@eruvanos eruvanos merged commit 28c01ab into pythonarcade:development Jun 9, 2023
6 checks passed
@eruvanos
Copy link
Member

eruvanos commented Jun 9, 2023

Finally merged, thanks for your work

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
gui Related to arcade GUI (sub module arcade.gui)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants