omar
6eacddb50f
Viewport: Changed Monitor field to use Pos+Size (more consistent), changed FullMin,FullMax to MainPos,MainSize. Made main viewport accessible in PlatformIO on first frame. Fixed casing of ImGuiViewportFlags_TopMost flag. ( #1542 )
2018-05-10 13:10:04 +02:00
omar
4ff23d3306
Merge branch 'master' into viewport
...
# Conflicts:
# examples/imgui_impl_dx9.cpp
# imgui.cpp
# imgui.h
2018-05-07 22:23:58 +02:00
omar
0bf43b3a1b
Settings: Added LoadIniSettingsFromDisk(), LoadIniSettingsFromMemory(), SaveIniSettingsToDisk(), SaveIniSettingsToMemory(), io.WantSaveIniSettings. ( #923 , #993 )
2018-05-07 22:18:45 +02:00
omar
023cc25c7c
Internals: Removed unnecessary allocation indirection for g.LogClipboard (this only made sense when there was a global context instance)
2018-05-07 22:15:25 +02:00
omar
35e74c72ab
imgui_freetype: skip missing glyphs as well to match our stb loader ( #1671 , #1703 )
2018-05-07 20:32:17 +02:00
omar
6eda9ed3fb
Skip missing font glyphs V2 revert changes to stb_truetype.h (
2018-05-07 19:57:53 +02:00
omar
787a475650
Skip missing font glyphs to 1) avoid using space for missing glyphs and 2) allow merging fonts with overlapping ranges. Demo: Fixed displaying ? instead of greyed out empty box. ( #1671 , #1703 )
2018-05-07 18:03:00 +02:00
omar
807c4f0ea4
Ran a spell checker for sanity.
2018-05-07 14:44:35 +02:00
omar
4310bad32a
Examples: DirectX9: Comments, updated changelog, notes about usage of imconfig.h ( #1790 , #1687 )
2018-05-07 11:52:48 +02:00
SR_team
d0051ce5cb
add renderstate D3DRS_SHADEMODE for Dx9 impl
...
add backuping transform for Dx9 impl
(#1790 , #1687 )
2018-05-07 11:52:48 +02:00
omar
c7687fc1d6
Viewports: Comments on ImGuiConfigFlags_DpiEnableScaleViewports and ImGuiConfigFlags_DpiEnableScaleFonts. ( #1542 )
2018-05-07 10:44:08 +02:00
omar
dbe16b6a70
Made IMGUI_DISABLE_OBSOLETE_FUNCTIONS exceptionally not affect the layout of ImGuiIO. ( #1695 )
2018-05-04 14:55:38 +02:00
omar
ef05141a06
Internals: InputScalarEx: Tweak internals so there is a fast path for the simple case.
...
(in particular because it makes it clear what the extra code is for, so people tempted to create their own InputText data transform/handler understand how little is actually needed)
2018-04-30 20:12:14 +02:00
omar
ed756d474e
Internals: Added ImGuiDataType_Uint32 data type which is usable with InputScalarEx().
2018-04-30 20:02:33 +02:00
omar
7df985bc5c
Nav: Fixed hovering a Selectable() with the mouse so that it update the navigation cursor. Fixed c8b9b2c6
which was incorrect ( #787 )
2018-04-30 19:40:25 +02:00
omar
a1da7f9860
Internals: Tweaked ParseFormatPrecision(), clarified its more limited purpose, allowing 2-digits precisions since it makes (some) sense for doubles. ( #648 )
2018-04-30 16:52:16 +02:00
omar
92f0165f85
DragFloat, SliderFloat: Rounding scalar using the provided format string instead of parsed precision. ( #648 )
2018-04-30 16:44:57 +02:00
omar
6881d065b8
DragFloat/SliderFloat internal InputScalar trip trailing decoration off the format string when presenting an edit box to the user. ( #648 )
2018-04-30 15:59:59 +02:00
omar
d7e24416dd
DragFloat/SliderFloat internal InputScalar relies on the user supplied format string to format and parse value. ( #648 )
...
The trailing text after the format will be displayed in the InputText but not affect back parsing. Ideally we can try to strip it later.
2018-04-30 15:21:51 +02:00
omar
429f48bb4f
Clarified usage of ListBoxHeader() before we rename those functions + fixed demo code that didn't honor it correctly. ( #1783 )
2018-04-29 12:20:22 +02:00
omar
f2e9dddeca
DragDrop: Removed const qualifier from ImGuiPayload 's void* data, easing casting on user side.
2018-04-28 10:43:15 +02:00
Branimir Karadžić
d317951b37
Demo: Fixed demo from using obsolete functions.
2018-04-28 10:33:48 +02:00
omar
f80314754c
InputFloat,InputFloat2,InputFloat3,InputFloat4: Added variations taking a more flexible and consistent optional "const char* format" parameter instead of "int decimal_precision". This allow using custom formats to display values in scientific notation, and is generally more consistent with other API. Obsoleted functions using the optional "int decimal_precision" parameter. ( #648 )
2018-04-28 00:11:40 +02:00
omar
73445ff248
Renamed all "display_format" arguments to "format" to emphasis that they also affect rounding of values. ( #648 , #642 )
2018-04-27 23:44:27 +02:00
omar
8a38271a7c
SliderFloat, DragFloat: Fix to allow input of scientific notation when Ctrl+Clicking a slider or drag, matching the change done in c19b2781
for InputFloat(). ( #648 , #1011 )
2018-04-27 23:18:28 +02:00
omar
066550de68
DragFloat, DragInt: Cancel mouse tweak when current value is initially past the min/max boundaries and mouse is pushing in the same direction (keyboard/gamepad version already did this).
2018-04-27 19:15:25 +02:00
omar
a84aff1875
Internals: DragBehavior: tweaks internals.
2018-04-27 18:22:10 +02:00
omar
1d99b5f963
Internals: Reordered parameters of DataTypeFormatString() internal helper functions and shallow tweaks.
2018-04-27 18:19:59 +02:00
omar
101f9b42b7
InputText: Fixed returning true when edition is cancelled with Esc and the current buffer matches the initial value.
2018-04-27 17:32:03 +02:00
omar
28edece04f
Comments, minor tweaks
2018-04-27 17:32:03 +02:00
omar
c47d34cf70
Viewport: Exposing SetNextWindowViewport(). Used in demo and old/obsolete SetNextWindowPosCenter() (which is an interesting case). Fixed back-end likely crash calling GetFocus() after viewport destruction. Fixed metrics crash.
2018-04-27 15:13:22 +02:00
omar
cd51f37fc0
Viewport, Platform: Refresh monitor list (win32, glfw) + avoid calling GetWindowFocus before platform window creation to not require of backend to null-check things inconsistently. ( #1542 )
2018-04-26 16:18:47 +02:00
omar
da70c837da
Viewport: Removed unnecessary fields (now that the coordinate system is consistent accross viewports): MouseRefPrevViewport, MouseClickedPosViewportId. ( #1542 )
2018-04-26 15:30:19 +02:00
omar
f1ae07e532
Viewport, Platform: Using Platform_GetWindowFocus to provide a much stronger heuristic of platform z-order, in replacement for when the back-end cannot provide io.MouseHoveredViewport. The pressure for it to work well increased with the use of viewports by popups/menus. ( #1542 )
2018-04-26 11:52:38 +02:00
Bruce Mitchener
f8c9c33d33
Fixed static analyzers warnings with bool literals ( #1775 )
...
* Use `false` instead of `0` for a bool literal.
* Simplify calls to RadioButton to not need bool literals.
2018-04-26 09:51:46 +02:00
omar
d9cd494eaf
Viewport: Moved ScaleWindow* code in a proper location. Various comments.
2018-04-25 23:21:26 +02:00
omar
27ac9f4761
Comments ( #1695 )
2018-04-25 22:16:16 +02:00
omar
eb1c36fdfb
Added IMGUI_CHECKVERSION() macro to compare version string and data structure sizes in order to catch issues with mismatching compilation unit settings. ( #1695 , #1769 )
2018-04-25 22:07:14 +02:00
omar
5979233a3c
Misc: tweaks + minor changes merged from master to reduce branch drift. Removed code that ended up unused.
2018-04-25 18:23:39 +02:00
omar
0b1d6a0d52
Merge branch 'master' into viewport
...
# Conflicts:
# imgui.cpp
# imgui.h
# imgui_internal.h
2018-04-25 18:13:23 +02:00
omar
711a63befc
Misc: Stop moving window if mouse position becomes invalid. Flagged menus are _NoMove for sanity.
2018-04-25 17:58:54 +02:00
omar
d317d90610
Misc: NavCalcPreferredRefPos selects between mouse and nav reference position + added sanity assert (merged from viewport branch to minimize branch drift).
2018-04-25 17:58:54 +02:00
omar
9cbca8c127
Begin: Shuffled some code, _should_ have no side-effect. Clear NextWindowData in one call and more consistently. (merged from viewport branch to minimize branch drift).
2018-04-25 17:58:54 +02:00
omar
e3453d0dc4
Misc: Comments and shallow/small changes (merged from viewport branch to minimize branch drift).
2018-04-25 17:58:53 +02:00
Bruce Mitchener
b28535d1da
ImGuiTextBuffer::appendfv needs to va_end the args_copy.
2018-04-25 17:40:39 +02:00
omar
7b433605f9
Viewport: Avoid creating viewport on drag (fix cc882b0723
)
2018-04-25 15:38:32 +02:00
omar
3b9b1956cd
Merge branch 'master' into viewport
...
# Conflicts:
# examples/allegro5_example/imgui_impl_a5.cpp
# examples/allegro5_example/imgui_impl_a5.h
# examples/allegro5_example/imgui_impl_allegro5.cpp
# examples/allegro5_example/imgui_impl_allegro5.h
# examples/allegro5_example/main.cpp
# examples/imgui_impl_allegro5.cpp
# examples/imgui_impl_allegro5.h
# imgui.cpp
# imgui_internal.h
2018-04-25 15:32:04 +02:00
omar
01fa934222
Internals: Removed unecessary Pos/PosFloat separation, only reason appears to be mostly pre-1.0. The only piece of code that I expected sub-pixel window position to matter actually already round its delta (wrongly so, will fix later/separately if we want).
2018-04-25 15:24:26 +02:00
omar
7a41e0b1ea
Platform: Added platform_io.Platform_SetWindowFocus, Platform_GetWindowFocus function wrappers (unused yet). Exact specs tbd because our simplified concept of focus doesn't necessary match the more complex OS native concepts. ( #1542 )
2018-04-25 15:15:14 +02:00
omar
cc882b0723
Viewport: Tidying up AddUpdateViewport() calls. Moved flags argument. Removed extraneous mid-frame call to FindPlatformMonitorFromRect(). ( #1542 )
2018-04-25 15:14:51 +02:00