mirror of
https://github.com/ocornut/imgui.git
synced 2026-01-09 23:54:20 +00:00
Fonts: Added PushFontSize(), PopFontSize() api. Added font_size param to PushFont() as well.
Fonts: Fixed PopFont() recovery. (To squash into "Added PushFontSize(), PopFontSize() api."
This commit is contained in:
parent
80404fae30
commit
daaf0e4ef3
4 changed files with 73 additions and 40 deletions
|
|
@ -869,6 +869,12 @@ struct ImDrawDataBuilder
|
|||
ImDrawDataBuilder() { memset(this, 0, sizeof(*this)); }
|
||||
};
|
||||
|
||||
struct ImFontStackData
|
||||
{
|
||||
ImFont* Font;
|
||||
float FontSize;
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// [SECTION] Style support
|
||||
//-----------------------------------------------------------------------------
|
||||
|
|
@ -2237,7 +2243,7 @@ struct ImGuiContext
|
|||
ImGuiCol DebugFlashStyleColorIdx; // (Keep close to ColorStack to share cache line)
|
||||
ImVector<ImGuiColorMod> ColorStack; // Stack for PushStyleColor()/PopStyleColor() - inherited by Begin()
|
||||
ImVector<ImGuiStyleMod> StyleVarStack; // Stack for PushStyleVar()/PopStyleVar() - inherited by Begin()
|
||||
ImVector<ImFont*> FontStack; // Stack for PushFont()/PopFont() - inherited by Begin()
|
||||
ImVector<ImFontStackData> FontStack; // Stack for PushFont()/PopFont() - inherited by Begin()
|
||||
ImVector<ImGuiFocusScopeData> FocusScopeStack; // Stack for PushFocusScope()/PopFocusScope() - inherited by BeginChild(), pushed into by Begin()
|
||||
ImVector<ImGuiItemFlags> ItemFlagsStack; // Stack for PushItemFlag()/PopItemFlag() - inherited by Begin()
|
||||
ImVector<ImGuiGroupData> GroupStack; // Stack for BeginGroup()/EndGroup() - not inherited by Begin()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue