mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-07 05:28:47 +02:00
Merge branch 'master' into docking
# Conflicts: # examples/imgui_examples.sln # examples/imgui_impl_dx12.cpp # examples/imgui_impl_dx12.h # examples/imgui_impl_opengl3.cpp # imgui.cpp # imgui_demo.cpp # imgui_internal.h # imgui_widgets.cpp
This commit is contained in:
@ -104,6 +104,19 @@ Other changes:
|
||||
VERSION 1.79 WIP (In Progress)
|
||||
-----------------------------------------------------------------------
|
||||
|
||||
Breaking Changes:
|
||||
|
||||
- Fonts: Removed ImFont::DisplayOffset in favor of ImFontConfig::GlyphOffset. DisplayOffset was applied
|
||||
after scaling and not very meaningful/useful outside of being needed by the default ProggyClean font.
|
||||
It was also getting in the way of better font scaling, so let's get rid of it now!
|
||||
If you used DisplayOffset it was probably in association to rasterizing a font at a specific size,
|
||||
in which case the corresponding offset may be reported into GlyphOffset. (#1619)
|
||||
- Renamed OpenPopupContextItem() back to OpenPopupOnItemClick(), REVERTED CHANGE FROM 1.77.
|
||||
For variety of reason this is more self-explanatory.
|
||||
- Removed return value from OpenPopupOnItemClick() - returned true on mouse release on item - because it
|
||||
is inconsistent with other popups API and makes others misleading. It's also and unnecessary: you can
|
||||
use IsWindowAppearing() after BeginPopup() for a similar result.
|
||||
|
||||
Other Changes:
|
||||
|
||||
- Window: Fixed using non-zero pivot in SetNextWindowPos() when the window is collapsed. (#3433)
|
||||
@ -111,6 +124,7 @@ Other Changes:
|
||||
- Nav: Fixed using Alt to toggle the Menu layer when inside a Modal window. (#787)
|
||||
- Scrolling: Fixed SetScrollHere functions edge snapping when called during a frame where ContentSize
|
||||
is changing (issue introduced in 1.78). (#3452).
|
||||
- InputText: Added support for Page Up/Down in InputTextMultiline(). (#3430) [@Xipiryon]
|
||||
- InputText: Added selection helpers in ImGuiInputTextCallbackData().
|
||||
- InputText: Added ImGuiInputTextFlags_CallbackEdit to modify internally owned buffer after an edit.
|
||||
(note that InputText() already returns true on edit, the callback is useful mainly to manipulate the
|
||||
@ -119,27 +133,53 @@ Other Changes:
|
||||
It is a rather unusual or useless combination of features but no reason it shouldn't work!
|
||||
- InputText: Fixed minor scrolling glitch when erasing trailing lines in InputTextMultiline().
|
||||
- InputText: Fixed cursor being partially covered after using Ctrl+End key.
|
||||
- InputText: Fixed callback's helper DeleteChars() function when cursor is inside the deleted block. (#3454).
|
||||
- InputText: Fixed callback's helper DeleteChars() function when cursor is inside the deleted block. (#3454)
|
||||
- InputText: Made pressing Down arrow on the last line when it doesn't have a carriage return not move to
|
||||
the end of the line (so it is consistent with Up arrow, and behave same as Notepad and Visual Studio.
|
||||
Note that some other text editors instead would move the crusor to the end of the line). [@Xipiryon]
|
||||
- DragFloat, DragScalar: Fixed ImGuiSliderFlags_ClampOnInput not being honored in the special case
|
||||
where v_min == v_max. (#3361)
|
||||
- SliderInt, SliderScalar: Fixed reaching of maximum value with inverted integer min/max ranges, both
|
||||
with signed and unsigned types. Added reverse Sliders to Demo. (#3432, #3449) [@rokups]
|
||||
- Text: Bypass unnecessary formatting when using the TextColored()/TextWrapped()/TextDisabled() helpers
|
||||
with a "%s" format string. (#3466)
|
||||
- BeginMenuBar: Fixed minor bug where CursorPosMax gets pushed to CursorPos prior to calling BeginMenuBar(),
|
||||
so e.g. calling the function at the end of a window would often add +ItemSpacing.y to scrolling range.
|
||||
- TreeNode, CollapsingHeader: Made clicking on arrow toggle toggle the open state on the Mouse Down event
|
||||
rather than the Mouse Down+Up sequence, even if the _OpenOnArrow flag isn't set. This is standard behavior
|
||||
and amends the change done in 1.76 which only affected cases were _OpenOnArrow flag was set.
|
||||
(This is also necessary to support full multi/range-select/drag and drop operations.)
|
||||
- Tab Bar: Added TabItemButton() to submit tab that behave like a button. (#3291) [@Xipiryon]
|
||||
- Tab Bar: Added ImGuiTabItemFlags_Leading and ImGuiTabItemFlags_Trailing flags to position tabs or button
|
||||
at either end of the tab bar. Those tabs won't be part of the scrolling region, and when reordering cannot
|
||||
be moving outside of their section. Most often used with TabItemButton(). (#3291) [@Xipiryon]
|
||||
- Tab Bar: Added ImGuiTabItemFlags_NoReorder flag to disable reordering a given tab.
|
||||
- Tab Bar: Keep tab item close button visible while dragging a tab (independent of hovering state).
|
||||
- Tab Bar: Fixed a small bug where closing a tab that is not selected would leave a tab hole for a frame.
|
||||
- Tab Bar: Fixed a small bug where scrolling buttons (with ImGuiTabBarFlags_FittingPolicyScroll) would
|
||||
generate an unnecessary extra draw call.
|
||||
- Tab Bar: Fixed a small bug where toggling a tab bar from Reorderable to not Reorderable would leave
|
||||
tabs reordered in the tab list popup. [@Xipiryon]
|
||||
- Columns: Fix inverted ClipRect being passed to renderer when using certain primitives inside of
|
||||
a fully clipped column. (#3475) [@szreder]
|
||||
- Popups, Tooltips: Fix edge cases issues with positionning popups and tooltips when they are larger than
|
||||
viewport on either or both axises. [@Rokups]
|
||||
- Fonts: AddFontDefault() adjust its vertical offset based on floor(size/13) instead of always +1.
|
||||
- Metrics: Various tweaks, listing windows front-to-back, greying inactive items when possible.
|
||||
- Demo: Add simple InputText() callbacks demo (aside from the more elaborate ones in 'Examples->Console').
|
||||
- Backends: OpenGL3: Fix to avoid compiling/calling glBindSampler() on ES or pre 3.3 contexts which have
|
||||
the defines set by a loader. (#3467, #1985) [@jjwebb]
|
||||
- Backends: Vulkan: Some internal refactor aimed at allowing multi-viewport feature to create their
|
||||
own render pass. (#3455, #3459) [@FunMiles]
|
||||
- Backends: DX12: Clarified that imgui_impl_dx12 can be compiled on 32-bit systems by redefining
|
||||
the ImTextureID to be 64-bit (e.g. '#define ImTextureID ImU64' in imconfig.h). (#301)
|
||||
- Backends: DX12: Fix debug layer warning when scissor rect is zero-sized. (#3472, #3462) [@StoneWolf]
|
||||
- Examples: Vulkan: Reworked buffer resize handling, fix for Linux/X11. (#3390, #2626) [@RoryO]
|
||||
- Examples: Vulkan: Switch validation layer to use "VK_LAYER_KHRONOS_validation" instead of
|
||||
"VK_LAYER_LUNARG_standard_validation" which is deprecated (#3459) [@FunMiles]
|
||||
- Examples: DX12: Enable breaking on any warning/error when debug interface is enabled.
|
||||
- Examples: DX12: Added '#define ImTextureID ImU64' in project and build files to also allow building
|
||||
on 32-bit systems. Added project to default Visual Studio solution file. (#301)
|
||||
|
||||
|
||||
-----------------------------------------------------------------------
|
||||
@ -252,6 +292,7 @@ Breaking Changes:
|
||||
note that this is a Beta api and will likely be reworked in order to support multi-DPI across
|
||||
multiple monitors.
|
||||
- Renamed OpenPopupOnItemClick() to OpenPopupContextItem(). Kept inline redirection function (will obsolete).
|
||||
[NOTE: THIS WAS REVERTED IN 1.79]
|
||||
- Removed BeginPopupContextWindow(const char*, int mouse_button, bool also_over_items) in favor
|
||||
of BeginPopupContextWindow(const char*, ImGuiPopupFlags flags) with ImGuiPopupFlags_NoOverItems.
|
||||
Kept inline redirection function (will obsolete).
|
||||
@ -1535,7 +1576,7 @@ Breaking Changes:
|
||||
- removed the default global context and font atlas instance, which were confusing for users of DLL reloading and users of multiple contexts.
|
||||
- Renamed ImGuiStyleVar_Count_ to ImGuiStyleVar_COUNT and ImGuiMouseCursor_Count_ to ImGuiMouseCursor_COUNT for consistency with other public enums.
|
||||
- Fonts: Moved sample TTF files from extra_fonts/ to misc/fonts/. If you loaded files directly from the imgui repo you may need to update your paths.
|
||||
- Fonts: changed ImFont::DisplayOffset.y to defaults to 0 instead of +1. Fixed vertical rounding of Ascent/Descent to match TrueType renderer.
|
||||
- Fonts: Changed ImFont::DisplayOffset.y to defaults to 0 instead of +1. Fixed vertical rounding of Ascent/Descent to match TrueType renderer.
|
||||
If you were adding or subtracting (not assigning) to ImFont::DisplayOffset check if your fonts are correctly aligned vertically. (#1619)
|
||||
- BeginDragDropSource(): temporarily removed the optional mouse_button=0 parameter because it is not really usable in many situations at the moment.
|
||||
- Obsoleted IsAnyWindowHovered() in favor of IsWindowHovered(ImGuiHoveredFlags_AnyWindow). Kept redirection function (will obsolete).
|
||||
|
@ -142,13 +142,6 @@ ImGui::SliderFloat("float", &f, 0.0f, 1.0f);
|
||||

|
||||
<br>_(settings: Dark style (left), Light style (right) / Font: NotoSansCJKjp-Medium, 20px / Rounding: 5)_
|
||||
|
||||
|
||||
**Offset font vertically by altering the `io.Font->DisplayOffset` value:**
|
||||
```cpp
|
||||
ImFont* font = io.Fonts->AddFontFromFileTTF("font.ttf", size_pixels);
|
||||
font->DisplayOffset.y = 1; // Render 1 pixel down
|
||||
```
|
||||
|
||||
**Font Atlas too large?**
|
||||
|
||||
- If you have very large number of glyphs or multiple fonts, the texture may become too big for your graphics API. The typical result of failing to upload a texture is if every glyphs appears as white rectangles.
|
||||
@ -337,13 +330,13 @@ DroidSans.ttf
|
||||
ProggyClean.ttf
|
||||
Copyright (c) 2004, 2005 Tristan Grimmer
|
||||
MIT License
|
||||
recommended loading setting: Size = 13.0, DisplayOffset.Y = +1
|
||||
recommended loading setting: Size = 13.0, GlyphOffset.y = +1
|
||||
http://www.proggyfonts.net/
|
||||
|
||||
ProggyTiny.ttf
|
||||
Copyright (c) 2004, 2005 Tristan Grimmer
|
||||
MIT License
|
||||
recommended loading setting: Size = 10.0, DisplayOffset.Y = +1
|
||||
recommended loading setting: Size = 10.0, GlyphOffset.y = +1
|
||||
http://www.proggyfonts.net/
|
||||
|
||||
Karla-Regular.ttf
|
||||
|
@ -98,7 +98,7 @@ Calling the `ImGui::ShowDemoWindow()` function will create a demo window showcas
|
||||

|
||||
|
||||
You should be able to build the examples from sources (tested on Windows/Mac/Linux). If you don't, let us know! If you want to have a quick look at some Dear ImGui features, you can download Windows binaries of the demo app here:
|
||||
- [imgui-demo-binaries-20200412.zip](http://www.dearimgui.org/binaries/imgui-demo-binaries-20200412.zip) (Windows, 1.76, built 2020/04/12, master branch) or [older demo binaries](http://www.dearimgui.org/binaries).
|
||||
- [imgui-demo-binaries-20200918.zip](https://www.dearimgui.org/binaries/imgui-demo-binaries-20200918.zip) (Windows, 1.78 WIP, built 2020/09/18, master branch) or [older demo binaries](https://www.dearimgui.org/binaries).
|
||||
|
||||
The demo applications are not DPI aware so expect some blurriness on a 4K screen. For DPI awareness in your application, you can load/reload your font at different scale, and scale your style with `style.ScaleAllSizes()` (see [FAQ](https://www.dearimgui.org/faq)).
|
||||
|
||||
@ -114,7 +114,7 @@ Officially maintained bindings (in repository):
|
||||
- Frameworks: Emscripten, Allegro5, Marmalade.
|
||||
|
||||
Third-party bindings (see [Bindings](https://github.com/ocornut/imgui/wiki/Bindings/) page):
|
||||
- Languages: C, C# and: Beef, ChaiScript, D, Go, Haskell, Haxe/hxcpp, Java, JavaScript, Julia, Kotlin, Lua, Odin, Pascal, PureBasic, Python, Ruby, Rust, Swift...
|
||||
- Languages: C, C# and: Beef, ChaiScript, Crystal, D, Go, Haskell, Haxe/hxcpp, Java, JavaScript, Julia, Kotlin, Lua, Odin, Pascal, PureBasic, Python, Ruby, Rust, Swift...
|
||||
- Frameworks: AGS/Adventure Game Studio, Amethyst, bsf, Cinder, Cocos2d-x, Diligent Engine, Flexium, GML/Game Maker Studio2, Godot, GTK3+OpenGL3, Irrlicht Engine, LÖVE+LUA, Magnum, NanoRT, nCine, Nim Game Lib, Ogre, openFrameworks, OSG/OpenSceneGraph, Orx, Photoshop, px_render, Qt/QtDirect3D, SFML, Sokol, Unity, Unreal Engine 4, vtk, Win32 GDI, WxWidgets.
|
||||
- Note that C bindings ([cimgui](https://github.com/cimgui/cimgui)) are auto-generated, you can use its json/lua output to generate bindings for other languages.
|
||||
|
||||
|
@ -247,7 +247,6 @@ It's mostly a bunch of personal notes, probably incomplete. Feel free to query i
|
||||
- popups/modals: although it is sometimes convenient that popups/modals lifetime is owned by imgui, we could also a bool-owned-by-user api as long as Begin() return value testing is enforced.
|
||||
|
||||
- tooltip: drag and drop with tooltip near monitor edges lose/changes its last direction instead of locking one. The drag and drop tooltip should always follow without changing direction.
|
||||
- tooltip: tooltip that doesn't fit in entire screen seems to lose their "last preferred direction" and may teleport when moving mouse.
|
||||
- tooltip: allow to set the width of a tooltip to allow TextWrapped() etc. while keeping the height automatic.
|
||||
- tooltip: tooltips with delay timers? or general timer policy? (instantaneous vs timed): IsItemHovered() with timer + implicit aabb-id for items with no ID. (#1485)
|
||||
- tooltip: drag tooltip hovering over source widget with IsItemHovered/SetTooltip flickers.
|
||||
|
Reference in New Issue
Block a user