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

Add custom background line colour to TextEdit and remove marked lines #42775

Merged
merged 1 commit into from
May 22, 2021

Conversation

Paulb23
Copy link
Member

@Paulb23 Paulb23 commented Oct 13, 2020

Separating this from my WIP branch as part of #31739

Added a way to set/get the background colour of a line, the background colour is now drawn on the minimap. This supersedes marked lines which have been removed.

During the process I cleaned up some duplicated theme loading code between each of the editors.

closes #34165
closes godotengine/godot-proposals/issues/987

@Paulb23 Paulb23 added this to the 4.0 milestone Oct 13, 2020
@Paulb23 Paulb23 force-pushed the code_edit_line_background branch from 2648cf6 to 643ed20 Compare December 5, 2020 18:41
@akien-mga akien-mga requested a review from bruvzg January 25, 2021 23:42
@akien-mga akien-mga requested a review from a team January 25, 2021 23:57
@Paulb23 Paulb23 force-pushed the code_edit_line_background branch from 643ed20 to c5b9874 Compare January 30, 2021 12:49
@Paulb23 Paulb23 force-pushed the code_edit_line_background branch from c5b9874 to 4340f9f Compare February 13, 2021 17:33
@Paulb23 Paulb23 force-pushed the code_edit_line_background branch from 4340f9f to 6f18d9e Compare May 22, 2021 13:13
@Paulb23 Paulb23 requested review from a team as code owners May 22, 2021 13:13
text_editor->add_theme_color_override("completion_existing_color", EDITOR_GET("text_editor/highlighting/completion_existing_color"));
text_editor->add_theme_color_override("completion_scroll_color", EDITOR_GET("text_editor/highlighting/completion_scroll_color"));
text_editor->add_theme_color_override("completion_font_color", EDITOR_GET("text_editor/highlighting/completion_font_color"));
text_editor->add_theme_color_override("font_color", EDITOR_GET("text_editor/highlighting/text_color"));
Copy link
Member

Choose a reason for hiding this comment

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

It's worth noting that font_color and font_color_selected are the only theme items whose name differs from the matching editor setting (text_color and text_selected_color). Do we want to harmonize them?

Copy link
Contributor

@YuriSizov YuriSizov May 22, 2021

Choose a reason for hiding this comment

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

font_color is like our default font color property in a lot of controls 🤔 But text_color makes more sense for this particular editor setting. I'd keep it.

Though font_color_selected should be changed to font_selected_color or selection_font_color.

Copy link
Member Author

Choose a reason for hiding this comment

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

Nice catch should been font_selected_color.

Yeah text sounds better to me, though only for the editor, don't want to make TextEdit itself have a different naming scheme to the rest of the controls.

@akien-mga akien-mga requested a review from Calinou May 22, 2021 13:24
@akien-mga akien-mga requested a review from a team May 22, 2021 13:25
@Paulb23 Paulb23 force-pushed the code_edit_line_background branch from 6f18d9e to 00e10a8 Compare May 22, 2021 13:45
@akien-mga akien-mga merged commit 4828667 into godotengine:master May 22, 2021
@akien-mga
Copy link
Member

Thanks!

@Paulb23 Paulb23 deleted the code_edit_line_background branch May 22, 2021 15:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants