| 2944 | } |
| 2945 | |
| 2946 | void ImGui::PopStyleColor(int count) |
| 2947 | { |
| 2948 | ImGuiContext& g = *GImGui; |
| 2949 | if (g.ColorStack.Size < count) |
| 2950 | { |
| 2951 | IM_ASSERT_USER_ERROR(g.ColorStack.Size > count, "Calling PopStyleColor() too many times: stack underflow."); |
| 2952 | count = g.ColorStack.Size; |
| 2953 | } |
| 2954 | while (count > 0) |
| 2955 | { |
| 2956 | ImGuiColorMod& backup = g.ColorStack.back(); |
| 2957 | g.Style.Colors[backup.Col] = backup.BackupValue; |
| 2958 | g.ColorStack.pop_back(); |
| 2959 | count--; |
| 2960 | } |
| 2961 | } |
| 2962 | |
| 2963 | struct ImGuiStyleVarInfo |
| 2964 | { |