mirror of
https://github.com/ocornut/imgui.git
synced 2026-02-14 07:43:30 +00:00
Docs: fixed some typos (#9217)
This commit is contained in:
12
imgui.cpp
12
imgui.cpp
@@ -486,7 +486,7 @@ IMPLEMENTING SUPPORT for ImGuiBackendFlags_RendererHasTextures:
|
||||
io.Fonts->AddFontFromFileTTF("FontAwesome4.ttf", 0.0f, &cfg2);
|
||||
- You can use `Metrics/Debugger->Fonts->Font->Input Glyphs Overlap Detection Tool` to see list of glyphs available in multiple font sources. This can facilitate understanding which font input is providing which glyph.
|
||||
- Fonts: **IMPORTANT** on Thread Safety:
|
||||
- A few functions such as font->CalcTextSizeA() were, by sheer luck (== accidentally) thread-safe even thou we had never provided that guarantee. They are definitively not thread-safe anymore as new glyphs may be loaded.
|
||||
- A few functions such as font->CalcTextSizeA() were, by sheer luck (== accidentally) thread-safe even though we had never provided that guarantee. They are definitively not thread-safe anymore as new glyphs may be loaded.
|
||||
- Fonts: ImFont::FontSize was removed and does not make sense anymore. ImFont::LegacySize is the size passed to AddFont().
|
||||
- Fonts: Removed support for PushFont(NULL) which was a shortcut for "default font".
|
||||
- Fonts: Renamed/moved 'io.FontGlobalScale' to 'style.FontScaleMain'.
|
||||
@@ -1467,7 +1467,7 @@ ImGuiStyle::ImGuiStyle()
|
||||
ColumnsMinSpacing = 6.0f; // Minimum horizontal spacing between two columns. Preferably > (FramePadding.x + 1).
|
||||
ScrollbarSize = 14.0f; // Width of the vertical scrollbar, Height of the horizontal scrollbar
|
||||
ScrollbarRounding = 9.0f; // Radius of grab corners rounding for scrollbar
|
||||
ScrollbarPadding = 2.0f; // Padding of scrollbar grab within its frame (same for both axises)
|
||||
ScrollbarPadding = 2.0f; // Padding of scrollbar grab within its frame (same for both axes)
|
||||
GrabMinSize = 12.0f; // Minimum width/height of a grab box for slider/scrollbar
|
||||
GrabRounding = 0.0f; // Radius of grabs corners rounding. Set to 0.0f to have rectangular slider grabs.
|
||||
LogSliderDeadzone = 4.0f; // The size in pixels of the dead-zone around zero on logarithmic sliders that cross zero.
|
||||
@@ -5215,7 +5215,7 @@ void ImGui::StartMouseMovingWindow(ImGuiWindow* window)
|
||||
g.MovingWindow = window;
|
||||
}
|
||||
|
||||
// This is not 100% symetric with StartMouseMovingWindow().
|
||||
// This is not 100% symmetric with StartMouseMovingWindow().
|
||||
// We do NOT clear ActiveID, because:
|
||||
// - It would lead to rather confusing recursive code paths. Caller can call ClearActiveID() if desired.
|
||||
// - Some code intentionally cancel moving but keep the ActiveID to lock inputs (e.g. code path taken when clicking a disabled item).
|
||||
@@ -5296,7 +5296,7 @@ void ImGui::UpdateMouseMovingWindowEndFrame()
|
||||
StartMouseMovingWindow(hovered_window); //-V595
|
||||
|
||||
// FIXME: In principle we might be able to call StopMouseMovingWindow() below.
|
||||
// Please note how StartMouseMovingWindow() and StopMouseMovingWindow() and not entirely symetrical, at the later doesn't clear ActiveId.
|
||||
// Please note how StartMouseMovingWindow() and StopMouseMovingWindow() and not entirely symmetrical, at the later doesn't clear ActiveId.
|
||||
|
||||
// Cancel moving if clicked outside of title bar
|
||||
if ((hovered_window->BgClickFlags & ImGuiWindowBgClickFlags_Move) == 0) // set by io.ConfigWindowsMoveFromTitleBarOnly
|
||||
@@ -6704,7 +6704,7 @@ static ImVec2 CalcWindowAutoFitSize(ImGuiWindow* window, const ImVec2& size_cont
|
||||
size_desired[ImGuiAxis_Y] = (axis_mask & 2) ? size_contents.y + size_pad.y + decoration_h_without_scrollbars : window->Size.y;
|
||||
|
||||
// Determine maximum window size
|
||||
// Child windows are layed within their parent (unless they are also popups/menus) and thus have no restriction
|
||||
// Child windows are laid within their parent (unless they are also popups/menus) and thus have no restriction
|
||||
ImVec2 size_max = ((window->Flags & ImGuiWindowFlags_ChildWindow) && !(window->Flags & ImGuiWindowFlags_Popup)) ? ImVec2(FLT_MAX, FLT_MAX) : ImGui::GetMainViewport()->WorkSize - style.DisplaySafeAreaPadding * 2.0f;
|
||||
|
||||
if (window->Flags & ImGuiWindowFlags_Tooltip)
|
||||
@@ -8030,7 +8030,7 @@ bool ImGui::Begin(const char* name, bool* p_open, ImGuiWindowFlags flags)
|
||||
g.TooltipPreviousWindow = window;
|
||||
|
||||
// Set default BgClickFlags
|
||||
// This is set at the end of this function, so UpdateWindowManualResize()/ClampWindowPos() may use last-frame value if overriden by user code.
|
||||
// This is set at the end of this function, so UpdateWindowManualResize()/ClampWindowPos() may use last-frame value if overridden by user code.
|
||||
// FIXME: The general intent is that we will later expose config options to default to enable scrolling + select scrolling mouse button.
|
||||
window->BgClickFlags = (flags & ImGuiWindowFlags_ChildWindow) ? parent_window->BgClickFlags : (g.IO.ConfigWindowsMoveFromTitleBarOnly ? ImGuiWindowBgClickFlags_None : ImGuiWindowBgClickFlags_Move);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user