Commit Graph

93 Commits

Author SHA1 Message Date
jwdeitch
52f24d4e67 fix compiling error on OSX
error: ld: library not found for -lglfw3
2017-08-17 00:58:08 -04:00
Rokas Kupstys
25e6ba2597 Fix examples to use nk_vec2 in nk_input_scroll() calls. 2017-03-30 13:46:39 +03:00
vurtun
be7ac9b903 Updated Makefile as of #256 2017-01-14 09:46:13 +01:00
su21
72491bafb1 remove useless variable 2016-11-01 16:59:08 +08:00
vurtun
bd3fd8300f Pulled panel memory managment into nuklear
I simplified a lot of API calls by pulling panel memory management
inside the library. All API calls which previously required a panel
as parameter are now handling their panel themself.
2016-10-29 23:28:47 +02:00
dankan1890
3967fb533c Improved and fixed example/Makefile. 2016-10-22 21:43:33 +02:00
vurtun
85d109e351 Fixed non-blocking popup closing behavior
This is a breaking change which fixes bad closing behavior in
non-blocking popups. If the maximum size of a non-blocking popup was
not reached and you clicked to close the popup under it could happen
that it wouldn't be closed. This is now fixed in combination with
more popup control by allowing to set both the maximum height as
well as popup width.
2016-09-15 18:20:07 +02:00
vurtun
9e6b4f67cc Changes to fix #233 and #238
For more informatio please look inside the issues and for the
actual changes overview please look inside `CHANGELOG.md`
2016-09-08 20:20:02 +02:00
vurtun
7279f0f0cc Updated examples to new vertex layout API 2016-09-04 10:02:28 +02:00
vurtun
550a2b03d3 Fixed some bug introduced by last commit and more
This commit fixed some bugs from the last commit as well as some general
changes and fixes of some old bugs. For overview of all changes please
look inside `CHANGELOG.md`.
2016-08-31 19:19:06 +02:00
vurtun
727b912390 Update canvas example with background color arg
`nk_canvas_begin` now takes a background color directly instead of
requiring the user of the API to clear the window background with
another draw call.
2016-08-26 19:48:04 +02:00
kim yongbin
285e43c787 make all examples 2016-08-24 00:34:13 +09:00
kim yongbin
b54bc88e47 add missing CLFW_PRESS check for GLFW_KEY_RIGHT_CONTROL 2016-08-23 23:00:40 +09:00
vurtun
2dab85fde1 Enhanced the canvas example a little bit
Removed some global varibles and made the canvas a little bit easier
to use and embed into code.
2016-08-15 10:35:42 +02:00
vurtun
4b910e0f31 Update example version numbers 2016-08-07 21:26:53 +02:00
vurtun
100480c6c7 Fixed swapping out fonts
I had a long standing bug inside nuklear which prevents you from
swapping out a font while the code is being build. This bug is now
fixed but the fix requires _ALL_ `nk_user_font` data structures
provided by `nk_style_set_font` to be persistent.
2016-08-04 14:18:29 +02:00
vurtun
69df3f5369 Fixed #194 example/extended.c compile error 2016-08-04 08:59:17 +02:00
vurtun
831a9c32da Update examples to version 1.03 2016-07-29 23:26:44 +02:00
vurtun
d57fce9b85 Added missing label text color 2016-06-12 15:48:47 +02:00
vurtun
2e7dd3dc04 Added GWEN style skinning example #155
This commit adds a GWEN UI style skinning example. It is
certainly not perfect right now (especially windows suck) but
it is probably useful for a general overview. One thing that is
pretty clear for me now is that I need a way to read in a style from
file or memory since manually setting up properties, colors
and images is quite a pain.
2016-06-12 15:28:38 +02:00
vurtun
ba1ff9c23c Added canvas example
Added another example to show how to use Nuklear to only draw stuff
to the screen instead of using it for UI (or both).
2016-05-27 13:27:29 +02:00
Alex
45bbe7d6bb Example: add OS X specific include and library paths to Makefile 2016-05-21 23:48:10 +08:00
vurtun
539dde6cde Fixed #138 piemenu and combo open at same time
Fixed piemenu behavior inside extended example.
2016-05-19 16:11:54 +02:00
vurtun
71ee9a3986 Fixed #132 piemenu clipping bug
Previously the piemenu had a clipping bug caused by different offset
between internal and external properties. I just set spacing and
padding to zero to let the piemenu take the whole popup.
2016-05-16 14:10:14 +02:00
vurtun
8a01de120a Restructured demos and examples
All platform and renderbackend independent examples are now optional
demos for all platforms in `demo/`. Moving some demos from `example/`
provides an easier way to test GUI concepts for users and simplifies
maintenance.
2016-04-28 17:01:19 +02:00
vurtun
bbe282a272 Hopefully fixed high DPI display mouse mapping #74 2016-04-27 13:08:31 +02:00
vurtun
62ff1861a4 Hopefully fixed retina display issues #111 #74
I personally do not have a retina display, but I added some changes
to all `GLFW` demos/examples. If there are still issues please
report back to me what is not working correct (please test out clipping
by playing around with scrollbars as well)
2016-04-25 14:07:04 +02:00
Andrey Gursky
590c27d40f example: fix typo 2016-04-23 22:01:01 +02:00
vurtun
ca4d5bad8c Fixed blurry font for examples
Oversampling for the default font is tweaked for the default font
with height 13. I set the wrong height for all examples which should
now be fixed.
2016-04-20 19:53:26 +02:00
vurtun
18b93fcc8a Fixed #90 cppcheck warning and errors
Thanks to @codemeow I fixed some bugs and warnings found with
cppcheck. NOTE: it seems like all static analyzer fail to
detect the assert macro or hate combining assert ans if checks.
2016-04-20 10:31:20 +02:00
Alexandre Erwin Ittner
72e9496768 Use standard C compiler by default
Always use the standard compiler as defined by the environment
variable CC. User can set it when a different compiler if required
(e.g. CC=clang make)
2016-04-19 21:44:46 -03:00
vurtun
6b5a4f16e8 Merge branch 'fdb-osx-support' 2016-04-19 16:47:09 +02:00
Frederik De Bleser
da9899c618 Make examples work on OS X
All examples use GLFW, so we update the Makefile, remove OpenGL include
headers (GLFW will include them automatically) and conditionally set a
different shader version.
2016-04-19 13:49:07 +02:00
Bruce Mitchener
da46d536f9 Fix some typos. 2016-04-19 15:23:33 +07:00
vurtun
d7a9f14c1c Fixed some small bugs and added calc example
Fixed window movement for windows without header and some small
wrong calculation inside the panel layout code. In addition I
added another example implementing a simple calculator.
2016-04-15 20:13:50 +02:00
vurtun
b2c87ed7c0 Release Version 1.0
This is the first release version of nuklear (previously: zahnrad).
As for those who no the old version will notice: a lot has changed.

Most obvious should be the two biggest changes. First the name change
because I got critique that the name is hard to comprehend and
remember (understandable for non-germans) and the second is the
transistion from four files (zahnrad.h, zahnrad.c, stb_truetype
and stb_rect_pack) to one single header library file nuklear.h.
I am not 100% convinced that using a single header library is the
right choice here but so far I haven't encountered any problems.

Noticable should be as well that nuklear now directly embeds three
stb libraries: stb_truetype, stb_rect_pack and stb_textedit. Like
in previous versions the first two are optional and the library
can be compiled without. stb_textedit on the other hand powers
the text edit implementation for single as well as multiline
text manipulation. The text edit implementation is still relative
new and untested so you can expect some bugs I have not found yet.

In the demo department a lot changed as well. All platform demos
now don't compile one big demo but instead contain a simple
demo and small abstraction layer over the platform. Main benefit is
better understandablity improved ease of use. The old demo
is now split up and transfered into the example folder while each part
is self contained and compileable. (All examples use glfw I don't now
if this is the best platform but it is at least the simplest.
I also removed the apple demo because I don't have an apple system
and cannot make sure the new version runs with the old version.

Finally a lot of small bugs have been fixed as well as bugs found by
clang analyzer and coverity.
2016-04-14 16:26:15 +02:00
vurtun
fdbcc52629 Merged examples and demos into one (first step)
While dividing previously spared me from a lot of work and problems
it is probably best to have everything working for every or as many
platforms as possible. Some platforms fail to provide good ways
to support everything (e.g.:X11 does not have pixmap clipping with
different width/height or alpha-blending) but all OpenGL demos
outside allegro (needs some additional work) should be able to run.
2016-02-11 23:29:02 +01:00
vurtun
c85ed0c50c Restructered context functions for better clarity 2016-02-02 22:30:22 +01:00
vurtun
19a49780f7 Added event based updates back into examples
After some thought I decided to turn all examples back into
event based updated UIs. While it is possible to run all
examples without vsync with good performance it is probably best to
keep the examples in a accessable format which makes it possible
to be just by as many people as possible.
2016-01-26 22:52:09 +01:00
vurtun
0970db1088 Removed event based updates for examples
Previously all examples used an event based update scheme since
they caused performance issues on Linux. Further testing revealed
that vsync + tripple buffering causes problems and just needs to be
turned off to smoothly run all examples.
2016-01-25 23:42:21 +01:00
vurtun
c98153b59a removed need to pass string id to combobox 2016-01-20 19:36:40 +01:00
vurtun
70598bc887 updated contextual in example/demo 2016-01-09 13:59:34 +01:00
vurtun
183013231b extended demo + fixed some bugs 2016-01-05 17:24:45 +01:00
vurtun
9a52c86548 removed clang -Weverything warnings 2016-01-05 12:54:23 +01:00
vurtun
8945d97eae updated demo and fixed some small bugs 2016-01-04 21:34:48 +01:00
vurtun
1be6475e5b fixed #35 2016-01-04 00:19:38 +01:00
vurtun
333d5f33e7 fixed typo #34 no3,4 2016-01-03 23:26:07 +01:00
vurtun
138f6b3af5 some cleaning up 2016-01-03 20:23:12 +01:00
vurtun
ffe8a98d62 fixed contextual 2016-01-03 13:36:25 +01:00
vurtun
080b59dcc2 removed sin & cos dependency 2016-01-03 01:47:01 +01:00