| 13147 | } |
| 13148 | |
| 13149 | static void WindowSettingsHandler_ReadLine(ImGuiContext*, ImGuiSettingsHandler*, void* entry, const char* line) |
| 13150 | { |
| 13151 | ImGuiWindowSettings* settings = (ImGuiWindowSettings*)entry; |
| 13152 | int x, y; |
| 13153 | int i; |
| 13154 | if (sscanf(line, "Pos=%i,%i", &x, &y) == 2) { settings->Pos = ImVec2ih((short)x, (short)y); } |
| 13155 | else if (sscanf(line, "Size=%i,%i", &x, &y) == 2) { settings->Size = ImVec2ih((short)x, (short)y); } |
| 13156 | else if (sscanf(line, "Collapsed=%d", &i) == 1) { settings->Collapsed = (i != 0); } |
| 13157 | } |
| 13158 | |
| 13159 | // Apply to existing windows (if any) |
| 13160 | static void WindowSettingsHandler_ApplyAll(ImGuiContext* ctx, ImGuiSettingsHandler*) |