mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-07 13:35:49 +02:00
Merge branch 'master' into navigation
# Conflicts: # imgui.cpp # imgui_demo.cpp
This commit is contained in:
@ -183,7 +183,7 @@ void ImGui::ShowTestWindow(bool* p_open)
|
||||
if (no_collapse) window_flags |= ImGuiWindowFlags_NoCollapse;
|
||||
if (!no_menu) window_flags |= ImGuiWindowFlags_MenuBar;
|
||||
if (no_nav) window_flags |= ImGuiWindowFlags_NoNavInputs;
|
||||
ImGui::SetNextWindowSize(ImVec2(550,680), ImGuiSetCond_FirstUseEver);
|
||||
ImGui::SetNextWindowSize(ImVec2(550,680), ImGuiCond_FirstUseEver);
|
||||
if (!ImGui::Begin("ImGui Demo", p_open, window_flags))
|
||||
{
|
||||
// Early out if the window is collapsed, as an optimization.
|
||||
@ -858,8 +858,8 @@ void ImGui::ShowTestWindow(bool* p_open)
|
||||
if (ImGui::Button("Uint8 + HSV"))
|
||||
ImGui::SetColorEditOptions(ImGuiColorEditFlags_Uint8 | ImGuiColorEditFlags_HSV);
|
||||
ImGui::SameLine();
|
||||
if (ImGui::Button("Float + HDR + NoClamp"))
|
||||
ImGui::SetColorEditOptions(ImGuiColorEditFlags_Float | ImGuiColorEditFlags_RGB | ImGuiColorEditFlags_HDR);
|
||||
if (ImGui::Button("Float + HDR"))
|
||||
ImGui::SetColorEditOptions(ImGuiColorEditFlags_Float | ImGuiColorEditFlags_RGB);
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
@ -2131,12 +2131,12 @@ static void ShowExampleAppManipulatingWindowTitle(bool*)
|
||||
// You can use the "##" and "###" markers to manipulate the display/ID.
|
||||
|
||||
// Using "##" to display same title but have unique identifier.
|
||||
ImGui::SetNextWindowPos(ImVec2(100,100), ImGuiSetCond_FirstUseEver);
|
||||
ImGui::SetNextWindowPos(ImVec2(100,100), ImGuiCond_FirstUseEver);
|
||||
ImGui::Begin("Same title as another window##1");
|
||||
ImGui::Text("This is window 1.\nMy title is the same as window 2, but my identifier is unique.");
|
||||
ImGui::End();
|
||||
|
||||
ImGui::SetNextWindowPos(ImVec2(100,200), ImGuiSetCond_FirstUseEver);
|
||||
ImGui::SetNextWindowPos(ImVec2(100,200), ImGuiCond_FirstUseEver);
|
||||
ImGui::Begin("Same title as another window##2");
|
||||
ImGui::Text("This is window 2.\nMy title is the same as window 1, but my identifier is unique.");
|
||||
ImGui::End();
|
||||
@ -2144,7 +2144,7 @@ static void ShowExampleAppManipulatingWindowTitle(bool*)
|
||||
// Using "###" to display a changing title but keep a static identifier "AnimatedTitle"
|
||||
char buf[128];
|
||||
sprintf(buf, "Animated title %c %d###AnimatedTitle", "|/-\\"[(int)(ImGui::GetTime()/0.25f)&3], rand());
|
||||
ImGui::SetNextWindowPos(ImVec2(100,300), ImGuiSetCond_FirstUseEver);
|
||||
ImGui::SetNextWindowPos(ImVec2(100,300), ImGuiCond_FirstUseEver);
|
||||
ImGui::Begin(buf);
|
||||
ImGui::Text("This window has a changing title.");
|
||||
ImGui::End();
|
||||
@ -2153,7 +2153,7 @@ static void ShowExampleAppManipulatingWindowTitle(bool*)
|
||||
// Demonstrate using the low-level ImDrawList to draw custom shapes.
|
||||
static void ShowExampleAppCustomRendering(bool* p_open)
|
||||
{
|
||||
ImGui::SetNextWindowSize(ImVec2(350,560), ImGuiSetCond_FirstUseEver);
|
||||
ImGui::SetNextWindowSize(ImVec2(350,560), ImGuiCond_FirstUseEver);
|
||||
if (!ImGui::Begin("Example: Custom rendering", p_open))
|
||||
{
|
||||
ImGui::End();
|
||||
@ -2306,7 +2306,7 @@ struct ExampleAppConsole
|
||||
|
||||
void Draw(const char* title, bool* p_open)
|
||||
{
|
||||
ImGui::SetNextWindowSize(ImVec2(520,600), ImGuiSetCond_FirstUseEver);
|
||||
ImGui::SetNextWindowSize(ImVec2(520,600), ImGuiCond_FirstUseEver);
|
||||
if (!ImGui::Begin(title, p_open))
|
||||
{
|
||||
ImGui::End();
|
||||
@ -2567,7 +2567,7 @@ struct ExampleAppLog
|
||||
|
||||
void Draw(const char* title, bool* p_open = NULL)
|
||||
{
|
||||
ImGui::SetNextWindowSize(ImVec2(500,400), ImGuiSetCond_FirstUseEver);
|
||||
ImGui::SetNextWindowSize(ImVec2(500,400), ImGuiCond_FirstUseEver);
|
||||
ImGui::Begin(title, p_open);
|
||||
if (ImGui::Button("Clear")) Clear();
|
||||
ImGui::SameLine();
|
||||
@ -2624,7 +2624,7 @@ static void ShowExampleAppLog(bool* p_open)
|
||||
// Demonstrate create a window with multiple child windows.
|
||||
static void ShowExampleAppLayout(bool* p_open)
|
||||
{
|
||||
ImGui::SetNextWindowSize(ImVec2(500, 440), ImGuiSetCond_FirstUseEver);
|
||||
ImGui::SetNextWindowSize(ImVec2(500, 440), ImGuiCond_FirstUseEver);
|
||||
if (ImGui::Begin("Example: Layout", p_open, ImGuiWindowFlags_MenuBar))
|
||||
{
|
||||
if (ImGui::BeginMenuBar())
|
||||
@ -2670,7 +2670,7 @@ static void ShowExampleAppLayout(bool* p_open)
|
||||
// Demonstrate create a simple property editor.
|
||||
static void ShowExampleAppPropertyEditor(bool* p_open)
|
||||
{
|
||||
ImGui::SetNextWindowSize(ImVec2(430,450), ImGuiSetCond_FirstUseEver);
|
||||
ImGui::SetNextWindowSize(ImVec2(430,450), ImGuiCond_FirstUseEver);
|
||||
if (!ImGui::Begin("Example: Property editor", p_open))
|
||||
{
|
||||
ImGui::End();
|
||||
@ -2743,7 +2743,7 @@ static void ShowExampleAppPropertyEditor(bool* p_open)
|
||||
// Demonstrate/test rendering huge amount of text, and the incidence of clipping.
|
||||
static void ShowExampleAppLongText(bool* p_open)
|
||||
{
|
||||
ImGui::SetNextWindowSize(ImVec2(520,600), ImGuiSetCond_FirstUseEver);
|
||||
ImGui::SetNextWindowSize(ImVec2(520,600), ImGuiCond_FirstUseEver);
|
||||
if (!ImGui::Begin("Example: Long text display", p_open))
|
||||
{
|
||||
ImGui::End();
|
||||
|
Reference in New Issue
Block a user