Is raygui not production ready yet?

Hi,

I see that there's also a gui library for rendering some widgets, but so far haven't found any documentation other than the github page and some examples in the examples folder. Is this because raygui is not ready yet? Or it's quite usabe but lacks proper documentation?

I've just played with it a little but, but for the scrollpanel_text_multiline example works halfway (key repeat is not working, and cursor is being render at wrong positions) so it gave me the impression that it might be a work in progress...

I'm asking this because I was planning on using raygui on a video games prorgamming course but if it's not ready.. I'll probably just stick with raylib.

Comments

  • edited August 18
    Btw, I'm struggling to make a "portable" usb with both raylib and raygui .. for raylib it's working fine.

    For the raylib_compile_ex I just change the SET RAYLIB_DIR=C:\raylib to whatever place the usb is pointing to.. and compiling examples from work just fine..

    I can also have "workplace" directory with subdirectories for each little project and raylib works nice. But raygui refuses to compile.. I've added -I../../raygui/src but it throws a lot of errors this is just one of them:

    In file included from gui_demo.cpp:14:0:
    ../../raygui/src/raygui.h:774:1: error: narrowing conversion of '4126537215' from 'unsigned int' to 'int' inside { } [-Wnarrowing]
    };

    The folder structure is:

    mingw
    npp
    raygui
    raylib
    workspace

    And inside workspace I want to have
    sample1
    sample2
    etc..

    I'm literally copy pasting the windows.c example to gui_demo.cpp

    UPDATE: Ok... I understand now that when calling the file by .cpp the compiler used is g++ and the warnings are due to differences between the c99 standard and what C++ considers to be the "right" way..

    So that leaves me with manually editing raygui.h and "port" it to to something C++ friendly? :neutral:

    UPDATE2: So... I took care of the two problems that break compilation.. I can do a Pull request if it makes sense for the changes to be made..

    One is due to the fact that global variable guiState referes to enum GuiControl state but it is defined as an int.

    So changing

    static int guiState = NORMAL;

    for

    static GuiControlState guiState = NORMAL;

    Takes care of that..

    And the static int style[NUM_PROPERTIES] has to be change to an unsigned int

    There are a lot of warnings still, but at least is compiling.
  • Hi rixarn! raygui is production ready, actually I've used it to create several published tools and aslo working in a bunch of private tools:

    https://raysan5.itch.io/rfxgen
    https://raysan5.itch.io/rguistyler
    https://raysan5.itch.io/rguilayout

    GuiTextBoxMultiline() and GuiScrollBox() are still under development.

    About C++ usage, haven't tried it, you can send a PR with the corrections. Thanks! :)
  • Hi!

    Nice stuff! I decided to go for both (raylib and raygui) an managed to have a portable USB stick for Window.

    I'm struggling on the OSX version though.. raylib is working fine as usual.. raygui is the one that's complicating me a little bit..wonder if you could give me some hints on what's wrong?

    I have a folder structure like this (at a root raylib folder):

    include/raygui.h
    include/raylib.h
    libs/libraylib.a
    workspace/gui_hello_world/hello_world.c
    workspace/gui_hello_world/build.sh

    Contents of build.sh as follow:

    FILENAME="hello_world.c"
    EXECUTABLE="app"

    clang \
    -framework CoreVideo \
    -framework IOKit \
    -framework Cocoa \
    -framework GLUT \
    -framework OpenGL \
    ../../libs/libraylib.a \
    -I../../include \
    $FILENAME -o $EXECUTABLE

    When running ... I got duplicate symbol errors all over the place:

    duplicate symbol _MatrixIdentity in:
    ../../libs/libraylib.a(core.c.o)
    ../../libs/libraylib.a(core.o)
    duplicate symbol _QuaternionIdentity in:
    ../../libs/libraylib.a(core.c.o)
    ../../libs/libraylib.a(core.o)
    duplicate symbol _rlLoadIdentity in:
    ../../libs/libraylib.a(rlgl.c.o)
    ../../libs/libraylib.a(core.o)

    hello_world.c include section has this:

    #include "raylib.h"

    #define RAYGUI_IMPLEMENTATION
    #include "raygui.h"

    Sorry that I didn't tag the code sections, but I cant figure out how to split between different code blocks.. using pre/code will just wrap everything there...
Sign In or Register to comment.