Commit Graph

23 Commits

Author SHA1 Message Date
bolt 0883109476 Quickfix glfw shift-key handling
All of the glfw demo headers unset shift keypresses when the ctrl key is not
also down.
I can't think of a reason this would be desired and it appears no other demo
code does this.
Unless I'm mistaken, simply removing these lines leaves us with the desired
behaviour.
2024-07-11 12:33:37 +01:00
Rob Loach 7f5c642bb3
Standardize INCLUDE_OVERVIEW defines 2024-04-25 16:49:50 -04:00
Rob Loach 4cfea49522
Remove STYLE_ defines as we have the style dropdown 2024-04-25 16:37:07 -04:00
b-aaz fb474874db Added required includes to the platform headers .
Added missing include decelerations and in one case removed an unnecessary
one form the platform headers in the demo/ directory .
2024-01-20 16:16:45 +03:30
Richard Gill 54cd692d17 added comment on ifdefs to use styles in demos 2022-10-13 11:51:50 +02:00
Richard Gill fc5ce1c495 demos: set style with defines
To avoid having to modify the demo code,
conditionnally include a predefined style
2022-10-12 21:19:58 +02:00
Rob Loach ca49016428
Rename more null variables to tex_null 2022-07-30 17:45:12 -04:00
Rob Loach 54fd67bddd
Rename additional .null variables 2022-07-30 17:43:46 -04:00
Rob Loach ec4acc7cf4
Rename the null variable to tex_null 2022-07-30 17:38:10 -04:00
crazyBaboon f0dccaeeec
Integrate file browser with glfw opengl2 demo (#400) and restructure demo/ directory accordingly 2022-03-14 20:46:44 +01:00
Cameron Cawley 459ba9c48c Integrate the canvas example with the demos 2021-12-16 20:26:26 +00:00
Cameron Cawley 60c52adfaf
Enable and fix most GCC warnings (#377)
Co-authored-by: Rob Loach <robloach@gmail.com>
2021-12-16 20:44:00 +01:00
Cameron Cawley 9af0103cac Build all demos as C89 2021-12-14 20:14:34 +00:00
Alex Anderson a37a563315 Add select all shortcut to glfw4 demo 2021-10-10 12:15:21 +02:00
Wladislav Artsimovich 1e4eacca2e change NK_MEMSET to memset(), because NK_MEMSET is NK internal 2021-06-18 16:19:49 +02:00
Zane Ashby 9818f642da Fix memory leak in demo and example code.
Clear cmds nk_buffer after each frame to stop it growing over time.
2020-04-12 01:40:09 +12:00
crazyBaboon 4f6b838748 Remove duplicated #include <math.h> 2020-03-09 21:51:08 +00:00
Infinity_X 15e4dae107
Add type conversion for calloc 2019-07-10 19:32:36 +08:00
Robert Winkler 36a8d2a5ad Fix issue 548
The issue was introduced in the fix for 416 (commit 8559aeb).

The original problem was (backspace and arrows moving too fast) is not a
nuklear problem but a GLFW problem.  Because of the way nuklear handles
input (it must be between input_begin and end), the key callback method
GLFW offers is not an option.

So we have to use glfwGetKey() which returns the current state of a key
not whether it was just pressed or released, so nuklear acts like it
was pressed every single frame, hence the "too fast" problem.

The fix checks for state change and discards the event if there was
no change.  This kills key repeat behavior (for named keys) on
*all* platforms which makes deleting or arrowing inconvenient.

Since there's no way to fix the shortcomings of a callback vs event
based input API, my "fix" just makes the original fix conditional
on a macro NK_KEYSTATE_BASED_INPUT
2018-10-30 00:43:01 -07:00
Vincent Torri 1fdf7828af demos: fix typo (clipbard --> clipboard) 2018-09-15 06:52:10 +02:00
vurtun 1098b22423 Changed GLFW context version to OpenGL 4 2018-04-06 09:20:53 +02:00
vurtun 48a9d3176b Fixed ANSI C warnings 2018-01-28 11:59:06 +01:00
Kees Rijnen 205089ff62 Add opengl 4 demo that uses bindless textures and pesistent mapped vertex buffer 2018-01-22 06:00:39 -08:00