[Scummvm-git-logs] scummvm master -> 83c3456ccdcdce55e3c2001f11125eac37ab9cde
sev-
noreply at scummvm.org
Fri Jun 7 00:49:11 UTC 2024
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
83c3456ccd DIRECTOR: DT: Made more colors configurable
Commit: 83c3456ccdcdce55e3c2001f11125eac37ab9cde
https://github.com/scummvm/scummvm/commit/83c3456ccdcdce55e3c2001f11125eac37ab9cde
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2024-06-07T02:48:46+02:00
Commit Message:
DIRECTOR: DT: Made more colors configurable
Changed paths:
engines/director/debugger/debugtools.cpp
engines/director/debugger/dt-internal.h
diff --git a/engines/director/debugger/debugtools.cpp b/engines/director/debugger/debugtools.cpp
index 72ed100946d..7e4e15d034e 100644
--- a/engines/director/debugger/debugtools.cpp
+++ b/engines/director/debugger/debugtools.cpp
@@ -203,7 +203,7 @@ void showImage(const ImGuiImage &image, const char *name, float thumbnailSize) {
}
void displayVariable(const Common::String &name, bool changed) {
- ImU32 var_color = ImGui::GetColorU32(ImVec4(0.9f, 0.9f, 0.0f, 1.0f));
+ ImU32 var_color = ImGui::GetColorU32(_state->_colors._var_ref);
const ImU32 disp_color_disabled = ImGui::GetColorU32(ImVec4(0.9f, 0.08f, 0.0f, 0.0f));
const ImU32 disp_color_enabled = ImGui::GetColorU32(ImVec4(0.9f, 0.08f, 0.0f, 1.0f));
@@ -232,7 +232,7 @@ void displayVariable(const Common::String &name, bool changed) {
}
if (changed)
- var_color = ImGui::GetColorU32(_state->_colors._changed_var_color);
+ var_color = ImGui::GetColorU32(_state->_colors._var_ref_changed);
if (color == disp_color_disabled && ImGui::IsItemHovered()) {
color = disp_color_hover;
@@ -272,7 +272,7 @@ void setScriptToDisplay(const ImGuiScript &script) {
void displayScriptRef(CastMemberID &scriptId) {
if (scriptId.member) {
- ImGui::TextColored(ImVec4(0.5f, 0.5f, 1.0f, 1.0f), "%d", scriptId.member);
+ ImGui::TextColored(_state->_colors._script_ref, "%d", scriptId.member);
ImGui::SetItemTooltip(scriptId.asString().c_str());
@@ -293,7 +293,7 @@ static void showSettings() {
ImGui::ColorEdit4("Breakpoint disabled", &_state->_colors._bp_color_disabled.x);
ImGui::ColorEdit4("Breakpoint enabled", &_state->_colors._bp_color_enabled.x);
ImGui::ColorEdit4("Breakpoint hover", &_state->_colors._bp_color_hover.x);
- ImGui::Separator();
+ ImGui::SeparatorText("Lingo highlighting");
ImGui::ColorEdit4("Line", &_state->_colors._line_color.x);
ImGui::ColorEdit4("Call", &_state->_colors._call_color.x);
ImGui::ColorEdit4("Builtin", &_state->_colors._builtin_color.x);
@@ -303,6 +303,10 @@ static void showSettings() {
ImGui::ColorEdit4("Type", &_state->_colors._type_color.x);
ImGui::ColorEdit4("Keyword", &_state->_colors._keyword_color.x);
ImGui::ColorEdit4("The entity", &_state->_colors._the_color.x);
+ ImGui::SeparatorText("References");
+ ImGui::ColorEdit4("Script", &_state->_colors._script_ref.x);
+ ImGui::ColorEdit4("Variable", &_state->_colors._var_ref.x);
+ ImGui::ColorEdit4("Variable changed", &_state->_colors._var_ref_changed.x);
}
ImGui::End();
}
diff --git a/engines/director/debugger/dt-internal.h b/engines/director/debugger/dt-internal.h
index 92a9df0f1b7..3d5c85dce2a 100644
--- a/engines/director/debugger/dt-internal.h
+++ b/engines/director/debugger/dt-internal.h
@@ -134,7 +134,9 @@ typedef struct ImGuiState {
ImVec4 _keyword_color = ImColor(IM_COL32(0xC1, 0xC1, 0xC1, 0xFF));
ImVec4 _the_color = ImColor(IM_COL32(0xFF, 0x49, 0xEF, 0xFF));
- ImVec4 _changed_var_color = ImColor(IM_COL32(0xFF, 0x00, 0x00, 0xFF));
+ ImVec4 _script_ref = ImColor(IM_COL32(0x7f, 0x7f, 0xff, 0xfff));
+ ImVec4 _var_ref = ImColor(IM_COL32(0xe6, 0xe6, 0x00, 0xff));
+ ImVec4 _var_ref_changed = ImColor(IM_COL32(0xFF, 0x00, 0x00, 0xFF));
} _colors;
struct {
More information about the Scummvm-git-logs
mailing list