I am looking for gui library for c++ with customization - not native looking. I want create application with my custom graphics, that will be looks same on all OS. Able to resize it, and use svg graphics for display gui.
1. The main question is, it is possible create custom looking application, like Blender3D, Steam, Krita (graphic), Reaper (audio) with wxWidgets?
2. If 1. is yes, how hard it will be (I am learning c++, and I think, I am on level when I want use some gui)? Or is it better use other library? (I know Qt but I want avoid it)
3. It is possible connect to wxWidgets some library? Skia, AGG or SDL.
PS. sorry for my english.
Custom GUI with wxWidgets and other questions
Re: Custom GUI with wxWidgets and other questions
See my answer to a similar question here: viewtopic.php?p=174376#p174376
Depends on what you mean with "connect to". It is possible to use any almost other library together with wxWidgets.It is possible connect to wxWidgets some library? Skia, AGG or SDL.
Use the source, Luke!
Re: Custom GUI with wxWidgets and other questions
Thanks, I was read this answer when I searched for custom gui with wxWidgets. How hard it will be, for beginner, create completly custom gui (listboxes, choice controls, like something in topic with your answer and more) ? It will be ok, when I am still learning C++ ?
Btw. I am not interest in to game creation. But more for audio applications or maybe graphics program.
I mean, create some widgets with own graphics rendered with Skia, AGG, or make window where will be graphics manipulations. And SDL for own keyboard input and sound.doublemax wrote:Depends on what you mean with "connect to". It is possible to use any almost other library together with wxWidgets.It is possible connect to wxWidgets some library? Skia, AGG or SDL.
Btw. I am not interest in to game creation. But more for audio applications or maybe graphics program.
Re: Custom GUI with wxWidgets and other questions
Hard to tell, it won't be easy when you're new to both C++ and wxWidgets. However, once you understood how to create custom controls in general, the principle is always the same: You have a blank canvas and everything that shall appear there, must be drawn by you with wxDC methods: http://docs.wxwidgets.org/trunk/classwx_d_c.htmlHow hard it will be, for beginner, create completely custom gui (listboxes, choice controls, like something in topic with your answer and more) ? It will be ok, when I am still learning C++ ?
Then you will have to react on mouse (and maybe keyboard) events to modify the control.
The real work is the logic of each control. E.g. if you wanted to write a text control from scratch, you'd not only have to draw the content - which would be easy - but you also have to deal with cursor movement, text selection and stuff like that.
I don't know Skia, but with AGG for example you could render into a RGBA buffer, convert that to a wxBitmap and display it. Regarding SDL, there was a SDL control for wxWidgets once, but i can't remember its exact name. When you google a bit, you may find it. OTOH handling mouse and keyboard events in SDL is a little difficult, because it will be fighting with wxWidgets for the events. But i don't know enough about SDL to say more about it.create some widgets with own graphics rendered with Skia, AGG, or make window where will be graphics manipulations. And SDL for own keyboard input and sound.
Use the source, Luke!
Re: Custom GUI with wxWidgets and other questions
Thanks for answer (better late as never ). I hope I can open this old topic to continue ask few questions.
I start learning wxWidgets due problems with library I learned.
I start learning wxWidgets due problems with library I learned.
It is possible create text control with custom graphic but logic will be inherited from text control? Same for checkBox, ListBox etc.. it is possible change graphics but logic will be same (inherited from base checkBox, ... class)?The real work is the logic of each control. E.g. if you wanted to write a text control from scratch, you'd not only have to draw the content - which would be easy - but you also have to deal with cursor movement, text selection and stuff like that.
Re: Custom GUI with wxWidgets and other questions
No. That's exactly the problem i described in my post. While contols like buttons, checkboxes, radio buttons etc. are easy to implement, some other controls are harder. A text controls might even be one of the hardest, for a listbox you could use use wxVListBox as a base which would handle most of the logic for you.It is possible create text control with custom graphic but logic will be inherited from text control? Same for checkBox, ListBox etc.. it is possible change graphics but logic will be same (inherited from base checkBox, ... class)?
The sources for the "Universal" port can always be a start for your own implementations. They are in <wxdir>/src/univ/
The source for the textctrl is by far the lagest at 146k. That shows how much logic it requires.
(In case you don't know, the wxUniversal port doesn't use any native controls, it draws everything itself. But it's not widely used these days.)
Use the source, Luke!
Re: Custom GUI with wxWidgets and other questions
If I understand, the Universal mod is only wxWidgets with own widget display, something like this tutorial from http://zetcode.com/gui/wxwidgets/customwidgets/ ?
It is good start point Writing a Generic Widget from http://docs.wxwidgets.org/3.1/overview_ ... dgets.html to create own widgets ?
It is good start point Writing a Generic Widget from http://docs.wxwidgets.org/3.1/overview_ ... dgets.html to create own widgets ?
Re: Custom GUI with wxWidgets and other questions
https://wiki.wxwidgets.org/Painting_your_custom_control
This also contains the mouse handling and may be a better start.
This also contains the mouse handling and may be a better start.
Use the source, Luke!