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

CSSTUDIO-1976 Escape newlines in TextField "text" to prevent newlines from being removed in Label widgets. #2731

Merged
merged 1 commit into from
Jul 11, 2023

Conversation

abrahamwolk
Copy link
Collaborator

@abrahamwolk abrahamwolk commented Jul 11, 2023

This merge-request adds a mechanism that escapes newline characters from the TextField associated with the text of Label Widgets under widget Properties.

It fixes an issue that can be reproduced as follows:

  1. Create a Label widget.
  2. Enter a text that contains newlines, such as (by clicking on the "Open Editor" button with label "..."):
Line 1
Line 2
Line 3
  1. Click anywhere else in the OPI, so that the Label widget is now de-selected.
  2. The newline characters of the entered text have now been removed, and the text of the Label widget is now:
    Line 1Line 2Line 3

I have tested the fix under Linux and Windows.

Copy link
Collaborator

@kasemir kasemir left a comment

Choose a reason for hiding this comment

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

Good one!

@abrahamwolk abrahamwolk merged commit 12e032e into master Jul 11, 2023
2 checks passed
@abrahamwolk abrahamwolk deleted the CSSTUDIO-1976 branch July 11, 2023 13:35
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

Successfully merging this pull request may close these issues.

2 participants