Coder Social home page Coder Social logo

imtui's Introduction

imtui

Actions Status ImTui v1.0.4 badge Dear ImGui version badge

ImTui is an immediate mode text-based user interface library. Supports 256 ANSI colors and mouse/keyboard input.

ImTui basic
A very basic ImTui example


Slack client
Text-based client for Slack


Tables
Tables example


HNTerm
Text-based client for Hacker News


WTF util
Text-based configuration editor for the WTF Dashboard

Live demo in the browser

Even though this library is supposed to be used in the terminal, for convenience here is an Emscripten build to demonstrate what it looks like, by simulating a console in the browser:

Note: the demos work best with Chrome

Details

This library is 99.9% based on the popular Dear ImGui library. ImTui simply provides an ncurses interface in order to draw and interact with widgets in the terminal. The entire Dear ImGui interface is available out-of-the-box.

For basic usage of ImTui, check one of the available samples:

Building

ImTui depends only on libncurses

Linux and Mac:

git clone https://github.com/ggerganov/imtui --recursive
cd imtui
mkdir build && cd build
cmake ..
make

./bin/imtui-example-ncurses0

Windows:

Partial Windows support is currently available using MSYS2 + MinGW + PDCurses:

# install required packages in an MSYS2 terminal:
pacman -S git cmake make mingw-w64-x86_64-dlfcn mingw-w64-x86_64-gcc mingw-w64-x86_64-pdcurses mingw-w64-x86_64-curl

# build
git clone https://github.com/ggerganov/imtui --recursive
cd imtui
mkdir build && cd build
cmake ..
make

./bin/hnterm.exe

For more information, checkout the following discussion: #19

Emscripten:

git clone https://github.com/ggerganov/imtui --recursive
cd imtui
mkdir build && cd build
emconfigure cmake ..
make

imtui's People

Contributors

257 avatar clbx avatar dvj avatar ggerganov avatar jcalabro avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

imtui's Issues

No output in tmux / screen

Using imtui from within a tmux session, I get a completely blank screen. Looking in the debugger, the render loop does appear to be running, but nothing is visible. I believe tmux uses the alternate screen itself, so maybe we're toggling out of that mode and sending output to the wrong place? I also tested from screen and see the same behaviour, so I don't think it's a bug in tmux.

VSlider knob clips at top and often also at the bottom

This is visible in the imtui online demo (so it should be easy to see): if you go under Widgets / Vertical Sliders the sliders have knobs that are 2 rows tall, except when at the very top they are being rendered as one row tall... but clearly with the space where the second row would be being rendered, so it isn't like it is somehow off the top of the slider or anything. Some of the sliders (the ones towards the left) are exhibiting the same behavior at the bottom.

Mouse events reported in terminal

When I run imtui-example-ncurses0 or hnterm (with mouse support enabled) in my Linux terminal, the mouse events are reported into the terminal after the apps are exited.

I believe that it is because of the printf("\033[?1003h\n");. When I add a code to disable mouse movement printf("\033[?1003l\n"); before the application is exited, everything is fine and mouse events are not reported into the terminal anymore.

I also found some useful information about it here.

messed up installation

I've just discovered this library and would like to rewrite my existing tui tool's codebase using it but the installation is messed up. There's no make install or any instructions to install. I've tried to configure the CMakeLists and paths but who has the time for the pain. There's no documentation or whatsoever that can make using the library fun and enjoyable. I really want to use the library nd I'd be grateful if this was fixed.

Help using imtui in personal project

First of all apologies for this newbie question, but I am struggling with too many things at the same time: imtui, c++, cmakefiles, static vs dynamic libraries, etc. so I am not sure where the error may be, or whether my approach may not be the better one.

Let me try to break out my problem in parts to make it easier for you to understand and advice

First of all, what I actually want to do
I want to create a dummy hello-world imtui example from scratch, and build it in my own ~/projects/imtui-hello folder, with as minimal cmake/dependencies as possible. This is, ideally I'd like to have a hello-imtui.cpp file so I can do something like g++ -Wall [-I SOME_INCLUDE -DSOME_OPTION -SOMETHING_ELSE] ./imtui.cpp.

Can I do a simple build like that or do I actually need to use a CMakeFileLists.txt? Do I need to have the imgui forked dependency cloned on my hello-world folder (i.e. as in imtui/third-party/imgui? What if I install (make install) the (forked) imgui on its own to my system so I do not need to have a cloned imgui for each dummy folder I want to experiment with?

Now, I know there is an examples/ncurses0 but I want to do something much more minimal (dummy box with "hello world" text) than this. Additionally, I am also totally getting lost with the amount of CMake stuff that I do not know how to "re-use" it for this bare minimum experimentation folder

What I have done
I've properly build imtui, and ran the examples that are generated on bin folder. I have also installed imtui by issuing a make install. This is, imtui is working and, in theory, properly installed.

I am on Fedora 35 if that's of any help


Again, apologies if I am missing something basic here...

Linking problem with ImTui

Hello,

I am currently trying to include ImTui to my current console project. I followed instructions and it seems there is some linking problems (probably trivial, I am not too familiar with c/c++ world). I am using CMake and linked all ImTui .a files, I also have ncurses linked to my project. Result when I try to build and run my project:

/usr/bin/ld: /home/shardine/projects/neonlit/client/../lib/libimtui-ncurses.a(imtui-impl-ncurses.cpp.o): in function `ImTui_ImplNcurses_Init(bool, float, float)':
imtui-impl-ncurses.cpp:(.text+0xd2): undefined reference to `initscr'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0xd7): undefined reference to `use_default_colors'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0xdc): undefined reference to `start_color'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0xe1): undefined reference to `cbreak'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0xe6): undefined reference to `noecho'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0xed): undefined reference to `curs_set'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0xf4): undefined reference to `stdscr'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0xfe): undefined reference to `nodelay'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0x105): undefined reference to `stdscr'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0x10c): undefined reference to `wtimeout'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0x116): undefined reference to `set_escdelay'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0x11d): undefined reference to `stdscr'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0x127): undefined reference to `keypad'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0x25b): undefined reference to `stdscr'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0x313): undefined reference to `mouseinterval'
/usr/bin/ld: imtui-impl-ncurses.cpp:(.text+0x31f): undefined reference to `mousemask'

so all the link problems seems to be with ncurses. Do you know what I am doing wrong here?

Best regards.

No display on tmux

It might be more like an issue of tmux. Both hnterm and imtui-example-ncurses0 worked well in my terminal, but when I run them using tmux, I didn't see anything.

That happened on macOS Catalina with any kind of terminal. I used default .tmux.conf.

Missing ImGUI controls

Some controls are not rendered correctly in ImTUI. Here are some some obvious ones:

  • Separator
  • Spacing
  • Password InputText flag has no effect

I wish you could add support for these controls too. I guess the problem comes from how these elements are rendered.

Trouble linking ImTui

Apologies if this is a bit of a noob comment, I am a bit new to Linux apps. I am trying to create an app via WSL and every time I try to use the ImGui or ImTui functions I get an undefined reference to a bunch of ImGui functions. I followed the build instructions and then used make install to install it in the /usr/ directory.

The command I am using to build my program is:
g++ -g Main.cpp -I/usr/local/include/imgui -I/usr/local/include/imtui -limtui-ncurses -limtui -lncurses -o Test

And the function I am trying to call is IMGUI_CHECKVERSION()

Edit: Fixed it, it was me being dumb and not including the original ImGui Files
Edit 2: Also figured out that I need to not link against OG imgui files and instead run the cmake file for Imgui-for-imtui

Moving outside popup menu title does not close menu

Repro:

  • Open https://imtui.ggerganov.com/
  • Open subsection "Popups & Modal windows"
  • Open subsection "Popups"
  • Click "File"
  • Move cursor down from "(dummy menu)" past "Save As.." to "Options"
  • Move cursor one entry down

Expected:

"Options" menu closes

Actual:

"Options" menu stays open

Unrelated, it would appear as though there is a small rendering issue with the menu itself (screenshot attached)
Screenshot from 2019-12-27 11-02-39

Missing ImGui Tables demo

Currently, Imtui seems to support Imgui v1.81 whose demo has a bunch of table related stuff, which Imtui seems to be missing.

ImGui Demo v1.81 (has lots of table related demo items):

image

ImTui (master) (ncurses_demo) (doesn't have majority of table related items):

image

Compiling error : ‘uint64_t’ does not name a type

In file included from .../imtui/examples/hnterm/hn-state.cpp:5:
.../imtui/examples/hnterm/hn-state.h:36:5: error: ‘uint64_t’ does not name a type
   36 |     uint64_t time = 0;
      |     ^~~~~~~~
.../imtui/examples/hnterm/hn-state.h:11:1: note: ‘uint64_t’ is defined in header ‘<cstdint>’; did you forget to ‘#include <cstdint>’?

Fixed by adding

#include <cstdint>

to examples/hnterm/hn-state.h

Horizontal scrolling for tables doesn't work.

Horizontal scrolling for tables doesn't work. It is rendered double-width, overlayed on the last line and is not clickable/scrollable with the mouse.

Senza titolo

Tested with the lasta ImTui commit both on Windows (MSVC vs2019) & Ubuntu WSL in the Windows Terminal.

Packaging imtui for Linux distributions

I would like to build a package for this.

  • It would be great if you could tag and create releases in GitHub.
  • if there would be a make install to install the library.
  • if there could be a single tarball which doesn't need git to build.
  • Would be nice to have a pkgconfig (pc) file too.

Imtui doesn't compile due to imgui headers not being found

Hello,
I'm trying to use Imtui in my Cmake project, but Imtui doesn't compile.
here's the error:

[kamil@czarnepudlo build]$ cmake .. && make -j8
-- Configuring done
-- Generating done
-- Build files have been written to: /archive/ARCHIVE/sources/ce/build
[ 46%] Built target imgui-for-imtui
[ 53%] Built target ce_lib
[ 69%] Built target imtui
[ 76%] Building CXX object CMakeFiles/ce_exe.dir/source/main.cpp.o
Scanning dependencies of target imtui-ncurses
[ 84%] Building CXX object thirdparty/imtui/src/CMakeFiles/imtui-ncurses.dir/imtui-impl-ncurses.cpp.o
In file included from /archive/ARCHIVE/sources/ce/source/main.cpp:3:
/archive/ARCHIVE/sources/ce/thirdparty/imtui/include/imtui/imtui.h:8:10: fatal error: 'imgui/imgui.h' file not found
#include "imgui/imgui.h"
         ^~~~~~~~~~~~~~~
1 error generated.
make[2]: *** [CMakeFiles/ce_exe.dir/build.make:82: CMakeFiles/ce_exe.dir/source/main.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:158: CMakeFiles/ce_exe.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 92%] Linking CXX static library libimtui-ncurses.a
[ 92%] Built target imtui-ncurses
make: *** [Makefile:171: all] Error 2

Also, yes, I did clone the repo with --recursive so the imgui submodule is present in the third-party directory

build error on linux

unable to build on linux following instructions in README

  • already installed ncurses
  • mkdir build
  • cd build
  • cmake ..

it throws the following error, unable to find third party lib headers DearImGUI

$ cmake ..                                                                                                                                                                                                                      [19:52:07]
-- The C compiler identification is GNU 13.2.1
-- The CXX compiler identification is GNU 13.2.1
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found Git: /usr/bin/git (found version "2.42.0")
-- Found Curses: /usr/lib/libcurses.so
-- Looking for nodelay in /usr/lib/libncurses.so
-- Looking for nodelay in /usr/lib/libncurses.so - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- Found CURL: /usr/lib/libcurl.so (found version "8.3.0")
-- Configuring done (1.4s)
CMake Error at third-party/CMakeLists.txt:15 (add_library):
  Cannot find source file:

    imgui/imgui/imgui.cpp

  Tried extensions .c .C .c++ .cc .cpp .cxx .cu .mpp .m .M .mm .ixx .cppm
  .ccm .cxxm .c++m .h .hh .h++ .hm .hpp .hxx .in .txx .f .F .for .f77 .f90
  .f95 .f03 .hip .ispc


CMake Error at third-party/CMakeLists.txt:15 (add_library):
  No SOURCES given to target: imgui-for-imtui

TUI not displayed properly

I tried to integrate imtui to an existing project which is already using imgui. You can find the project setup here: https://github.com/rxdu/imtoolkit/tree/imtui

But it seems the UI is not displayed properly. I think it might be the same issue as the one mentioned in #8 . A screenshot is given below:

image

What I have tried:

  1. Keep everything untouched in this imtui repo under master branch: works fine
  2. Keep everything untouched in this imtui repo under v1.79 branch: works fine
  3. In my imtoolkit repo, use [email protected] (official repo), [email protected]: not working
  4. In my imtoolkit repo, use imgui@9874077 (official repo master at about a month ago), imtui@master: not working

I'm not sure if it's caused by any compile flags in cmake or if you've made any modifications to the imgui library? Any suggestions on how to fix this? Thank you!

Experiencing slow framerate

[MSVC 15 2017 Win32], Windows 10 Command Prompt, using PDCurses
I had to fiddle a bit to make it work ( tweaking small things in the CMakeLists.txt to link PDCurses properly ).
Then, even in release build, the refresh is very slow in the imtui-example-ncurses0 demo executable. I experience approximately 10fps, even the Web Assembly demo is faster and more responsive.
It looks like it is spending a lot of time in ImTui_ImplNcurses_NewFrame > wgetch > sleep.
Disabling the std::this_thread::sleep_for did not help either.
I can provide more information if needed.

Mouse scrolling

Is it possible to get mouse scrolling to work? So that it correctly scrolls regions with vertical tabbar.

For eg, in this demo window, clicking on the scrollbar and dragging it works, but scrolling via mouse scroll button doesn't.

image

Mouse movement does not work under ncurses-6.2

terminal emulator : windows terminal preview 1.12.2931.0
ncurses : 6.2

Cannot receive mouse movement events

Mouse movement works under ncurses-5.x, but not reporting mouse movements after columns 94

Upstreaming plans?

Do you have plans to upstream your changes to Dear ImGui? I would like to be able to dynamically choose between a TUI and a GUI (ideally even a remote web GUI) in a single binary but that requires a single version of Dear ImGui that I can use and have different code paths to enable backend-specific configurations within my tool.

Cursor position desync after moving a window

After moving a window, the cursor selects buttons slightly higher then were the cursor is drawn. I'm talking about moving an ImTui window, not the whole browser window. Having the issue on Firefox 71.0 (64-bit).

It would be so nice

If we could say farewell to the 70's.
Why we are still fixated to the idea that everything is a tty and we need to use ANSI escape codes to hack around the fact the 70's is over and you don't have a line-printer in your living room?
Why nobody (literally, nobody) attempts to make any real changes, like you know, to create hi-res modern command-line (ow, you can't fallback then to runlevel1 to run our superduper (TM) program! You would actively exclude users!!!! NONONO).
This is all bullsit, to ride on the existing terminal, and you know what, the silly thing is even the terminal emulators doing things differently, so at the end of the day libs like this and the retarded ncurses will be full of hack and cases and still it will provide some features which won't be supported by all term emulators.
But noooooo, we can't do anything new, we have to sit in this swamp created by made-up scientists in the 70's, not because they were evil or something, but because they were employed by telecommunication.
But no, linux, unis, bsd, mac and everybody thinks nooo, U CANT TOUCH THIS!! You know what? I would like to beat everybody up who is responsible for the sorry state of the modern personal computing, and for the available operating systems. There was nice ideas, but NOOOO, we had to settle down with the worst possible option. unix, were we bolt and glue layers above layers and above layer.

Fck you for continuing this. But really. Fuck you! Your are ALSO the reason why we can't have nice things.

Now go and close this ticket without spending any minute to think about why the "Beat up a programmer, he will know why he got it" movement exist and why they beat up programmers.

So again: fuck you.

Issues when not compiling using CMake

My project doesn't use CMake, so I attempted to add ImTui to the project without using it. While it compiles, the result isn't exactly as expected

image

Im assuming it is something during compilation, some flag or something, since when I compile it using Cmake it works perfectly fine.

If you have any insight on why this might be happening it would be much appreciated! This happens on both macOS and Linux, with slightly different results (Linux doesn't show the missing font characters)

This is my makefile

Breaking changes (imgui 1.79)

When imgui moves to 1.79 ImFont::DisplayOffset will be deprecated in favor of ImFontConfig::GlyphOffset
ocornut/imgui@c206a19

We will need to fix this:

external/imtui/examples/imtui-demo.cpp:3346:61: error: no member named 'DisplayOffset' in 'ImFont'
                    ImGui::InputFloat("Font offset", &font->DisplayOffset.y, 1, 1, "%.0f");

I just removed the line as they did in the commit (currently testing with imtui with latest imgui)

cmake error linux

`-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found CURL: /usr/lib64/libcurl.so (found version "7.69.1")
-- Configuring done
CMake Error at third-party/CMakeLists.txt:15 (add_library):
Cannot find source file:

imgui/imgui/imgui.cpp

Tried extensions .c .C .c++ .cc .cpp .cxx .cu .m .M .mm .h .hh .h++ .hm
.hpp .hxx .in .txx

CMake Error at third-party/CMakeLists.txt:15 (add_library):
No SOURCES given to target: imgui-for-imtui

CMake Generate step failed. Build files cannot be regenerated correctly.`

Passing character info to renderer

Currently, imtui uses a modified ImFont::RenderText function where it inserts the ascii value of the character to be rendered in the alpha channel of the color (ImDrawVert.col). While this makes imtui possible, it requires a modification to imgui itself achieve, which makes long term maintenance an issue.

Here is a proposed way to pass the character values by using the coordinates in the font texture instead. Proof of concept code below.

    std::unordered_map<int, uint8_t> character_lookup; // <-- needs persistence: global, class var, function param, etc.
    auto io = ImGui::GetIO();

    // tell imgui we have lots of 1x1 custom character glyphs in the texture
    int ids[255]; //store the returned id's
    for (int i = 1;i<255;i++) {
      ids[i] = io.Fonts->AddCustomRectFontGlyph(font, i, 1,1,1);
    }

    // Build atlas [existing code block]
    unsigned char* tex_pixels = NULL;
    int tex_w, tex_h;
    ImGui::GetIO().Fonts->GetTexDataAsRGBA32(&tex_pixels, &tex_w, &tex_h);
  
    // store the texture coordinates in a hashmap
    for (int i = 1;i<255;i++) {
      //lookup the id we got, and get the texture coordinates (in integer pixel values)
      const ImFontAtlas::CustomRect* rect = io.Fonts->GetCustomRectByIndex(ids[i]);
      // store the texture index with the character value
      character_lookup[rect->X + rect->Y*rect->Width] = i;
    }

Then, in the render function, once it's determined this is a textured 1x1 glyph, read the position in the texture to get the character index:

    // get the texture scale (could be stored)
    ImVec2 font_scale = ImGuiIO().Fonts->TexUvScale;
    // uv coords are [0..1], remap to integer values that match the rect we got when storing
    int index = uv0.x/font_scale.x+uv0.y/font_scale.y;
    auto char_code = character_lookup[index];
    cell |= char_code;

I've tested this and it works without issue, with some error handling, etc. Posting here for input and ideas before making a PR.

I believe many of the other changes in the local fork of imgui can be resolved when the work on "style V2" commences. (See, for example, ocornut/imgui#2017)

Bit confused by emscripten example

Hi there,

Great project! I have a dumb question hope you could shed some light on my confusion..

In your example: example-emscripten0

#include "imtui/imtui-impl-emscripten.h"
#include "imtui/imtui.h"

#include "imtui-demo.h"

#include <emscripten.h>

ImTui::TScreen *g_screen = nullptr;

extern "C" {
EMSCRIPTEN_KEEPALIVE

void render_frame() {
  ImTui_ImplText_NewFrame();
  ImTui_ImplEmscripten_NewFrame();

  ImGui::NewFrame();

  ImGui::SetNextWindowPos(ImVec2(8, 28), ImGuiCond_Once);
  ImGui::SetNextWindowSize(ImVec2(50.0, 10.0), ImGuiCond_Once);
  ImGui::Begin("Hello, dog!");

  ImGui::End();

  // bool showDemoWindow = true;
  // ImTui::ShowDemoWindow(&showDemoWindow);

  ImGui::Render();

  ImTui_ImplText_RenderDrawData(ImGui::GetDrawData(), g_screen);
}
}

int main() {
  IMGUI_CHECKVERSION();
  ImGui::CreateContext();

  ImTui_ImplText_Init();
  g_screen = ImTui_ImplEmscripten_Init(true);

  return 0;
}

The example works but I'm not too sure how render_frame is being called.

I'm not too familiar with emscripten so perhaps I could be pointed to something that would explain something that's missing..

I'm assuming that there's something in not calling an infinite while loop like the ncurses example does but doing any slight modification to the above results in lots of problems for me..

I intend to pass into my render_frame some of my custom objects to render, not sure how I would do this...

Any help would be greatly appreciated! :-)

ncurses example is not working (cannot click on things)

I'm unable to click on anything in ncurses example. It just selects text (even title says that, it changes from <path_to_exe> to Select <path_to_exe>). Right-click or pressing some key resets select mode, but there is no way for me to make example application work unfortunately.

I'm compiling with MSYS2 64-bit with MinGW-w64 64-bit compiler on Windows 10. I had issue with compilation as mentioned in issue #1, maybe it is relevant to this problem in some way.

Navigation borders are huge and confusing

When keyboard navigation is enabled, the borders around the selected control are drawn two characters wide, with one character of space between them and the selected control. This is huge in general and in things like combo boxes is incredibly confusing.

This can be fixed by patching ImGui::RenderNavHighlight method to disable both of the if (flags & ... blocks. It would be nice if the back end had some mechanism for telling Dear ImGui not to render these borders.

Couldn't find ncurses.h, package found by CMake

ncurses package was found by CMake without issues. Problem is that it did not include proper directories along with it.

In my environment (MSYS2 64-bit. compiling with MinGW-w64 64-bit compiler on Windows 10), ncurses installed through pacman has its headers under ncurses subfolder and not in root of main include directory of MinGW. This is not properly handled (in my environment at least) and I was forced to modify include in src/imtu-impl-ncurses.cpp@9 to #include <ncurses/ncurses> for it to compile.

Don't know what is proper fix, just throwing this in as a possible solution if someone encounters similar issue.

Dear ImGui 1.82

Will there be a support for Dear ImGUI 1.82? Because when I tried to just replace libraries and nothing works.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.