mirror of
https://github.com/kunkundi/crossdesk.git
synced 2025-10-27 04:35:34 +08:00
Redesign elements styles
This commit is contained in:
@@ -18,13 +18,18 @@ int Render::ConnectionStatusWindow() {
|
||||
connection_status_window_height_));
|
||||
|
||||
ImGui::SetWindowFontScale(0.5f);
|
||||
// ImGui::PushStyleColor(ImGuiCol_WindowBg, ImVec4(1.0, 1.0, 1.0, 1.0));
|
||||
ImGui::PushStyleVar(ImGuiStyleVar_FrameRounding, 3.0f);
|
||||
|
||||
ImGui::PushStyleColor(ImGuiCol_WindowBg, ImVec4(1.0, 1.0, 1.0, 1.0));
|
||||
ImGui::PushStyleVar(ImGuiStyleVar_WindowBorderSize, 1.0f);
|
||||
ImGui::PushStyleVar(ImGuiStyleVar_WindowRounding, 5.0f);
|
||||
|
||||
ImGui::Begin("ConnectionStatusWindow", nullptr,
|
||||
ImGuiWindowFlags_NoResize | ImGuiWindowFlags_NoCollapse |
|
||||
ImGuiWindowFlags_NoMove | ImGuiWindowFlags_NoTitleBar |
|
||||
ImGuiWindowFlags_NoSavedSettings);
|
||||
ImGui::PopStyleVar(2);
|
||||
ImGui::PopStyleColor();
|
||||
ImGui::SetWindowFontScale(1.0f);
|
||||
|
||||
ImGui::SetWindowFontScale(0.6f);
|
||||
@@ -75,8 +80,11 @@ int Render::ConnectionStatusWindow() {
|
||||
ImGui::SetCursorPosX((window_width - IPUT_WINDOW_WIDTH / 2) * 0.5f);
|
||||
ImGui::SetCursorPosY(window_height * 0.4f);
|
||||
ImGui::SetNextItemWidth(IPUT_WINDOW_WIDTH / 2);
|
||||
|
||||
ImGui::PushStyleVar(ImGuiStyleVar_FrameBorderSize, 1.0f);
|
||||
ImGui::InputText("##password", (char *)remote_password_.c_str(), 7,
|
||||
ImGuiInputTextFlags_CharsNoBlank);
|
||||
ImGui::PopStyleVar();
|
||||
|
||||
ImGui::SetCursorPosX(window_width * 0.28f);
|
||||
ImGui::SetCursorPosY(window_height * 0.75f);
|
||||
@@ -117,8 +125,7 @@ int Render::ConnectionStatusWindow() {
|
||||
|
||||
ImGui::SetWindowFontScale(0.5f);
|
||||
ImGui::End();
|
||||
ImGui::PopStyleVar(2);
|
||||
// ImGui::PopStyleColor();
|
||||
ImGui::PopStyleVar();
|
||||
ImGui::SetWindowFontScale(1.0f);
|
||||
}
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user