Commit Graph

326 Commits

Author SHA1 Message Date
Camilla Berglund
0eccf75f65 Replace GL booleans with public macros 2015-10-13 00:46:02 +02:00
Camilla Berglund
13fbb4748a Clean up cursor mode setting 2015-10-12 22:01:50 +02:00
Camilla Berglund
95a07f3340 Start 3.2 2015-10-12 21:59:49 +02:00
Camilla Berglund
6b8d490249 Make all client API functions dynamically loaded 2015-08-12 01:01:42 +02:00
Camilla Berglund
1f95fac699 Extension string type cleanup. 2015-07-28 14:12:16 +02:00
Camilla Berglund
cc4c232956 Renamed cursor window library struct member.
Since _glfwPlatformWindowFocused it has a more limited role.
2015-06-17 12:06:45 +02:00
Camilla Berglund
ff67e06844 Added prefixes to header guard macros. 2015-06-07 19:32:24 +02:00
Camilla Berglund
5f74c2afdf Cleanup. 2015-06-07 18:27:37 +02:00
Camilla Berglund
96b3f17d02 Re-used config structs for hints. 2015-06-07 18:14:07 +02:00
Camilla Berglund
5268914b3f Started 3.1.2. 2015-03-20 00:16:24 +01:00
Camilla Berglund
8f08661d9e Header option macro fixes and documentation work.
This adds compile-time checks and documentation warning about defining
header option macros during compilation of GLFW.

Fixes #445.
2015-03-17 16:39:09 +01:00
Camilla Berglund
ead8a1c333 Started 3.1.1. 2015-01-25 10:42:01 +01:00
Camilla Berglund
439417a22c Comment and string spell check pass. 2015-01-05 22:21:31 +01:00
Camilla Berglund
d459145d28 Made glfwGetCursorPos query system directly.
Fixes #103.
Fixes #153.
Fixes #193.
Fixes #355.
Fixes #381.
2015-01-04 16:54:19 +01:00
Camilla Berglund
641761ddb0 Changed state attribs to direct access.
Changed the window states (focused, iconified and visible) to query the
system directly.

THIS IS A BREAKING CHANGE, although a fairly obscure one.  It affects
applications that both care about telling actual key events from
synthetic ones, and are implemented in a non-self-synchronizing way, and
that poll the GLFW_FOCUSED window attribute instead of using the window
focus callback.

If you maintain one of these, please feel free to drop me an email and
I'll help any way I can to transition your application to 3.1.

Fixes #189.
Fixes #204.
2015-01-04 16:53:32 +01:00
Camilla Berglund
2a1375e97c Added glfwCreateStandardCursor.
This function allows the creation of cursor objects using one of several
standard cursor shapes from the current system cursor theme.
2014-12-15 21:58:44 +01:00
BrandonSchaefer
cfb7d2f036 Start with the skeleton code for Mir support. 2014-11-10 02:00:14 +01:00
Camilla Berglund
e9c7314d50 Added GLFW_FOCUSED window hint.
Fixes #101.
2014-09-10 11:50:50 +02:00
Camilla Berglund
f8d80a936f Internal header cleanup. 2014-09-02 19:47:29 +02:00
Camilla Berglund
44c899ce70 Added support for GL_KHR_context_flush_control. 2014-08-21 19:29:04 +02:00
Camilla Berglund
96b12ee504 Added character with modifiers callback.
The undefined behaviour changed with #40 has been reverted, making the
character-only callback again behave like a system text field.  This
behavior has now been documentated.

Fixes #203.
Fixes #305.
2014-06-24 10:50:05 +02:00
Camilla Berglund
e8e05d462c Documentation work.
Fixes #276.
2014-06-19 11:38:22 +02:00
Camilla Berglund
7cb217ed4a Fixed plural forms on key/button arrays. 2014-06-18 16:39:41 +02:00
Camilla Berglund
3ce7bfef07 Added GLFW_FLOATING.
Fixes #23.
2014-06-18 16:39:39 +02:00
Camilla Berglund
c9808586b3 Added GLFW_DOUBLEBUFFER. 2014-06-18 16:36:53 +02:00
Camilla Berglund
281013002d Added GLFW_DONT_CARE.
This changes the behavior of framebuffer hints set to zero.  Before,
zero meant that any value was acceptable.  This changes zero to be an
explicit preference and adds GLFW_DONT_CARE to mean that any value is
equally acceptable.

Fixes #70.
2014-06-18 16:36:22 +02:00
Camilla Berglund
25e7ff1196 Added GLFW_AUTO_ICONIFY.
By default, full screen windows that lose focus will be iconified and
the video mode will be restored.  This makes it impossible to create
applications spanning multiple monitors.  The GLFW_AUTO_ICONIFY window
hint will allow users to disable this behavior.

Fixes #143.
2014-06-18 16:33:58 +02:00
Camilla Berglund
56f0bb8613 Comment fix. 2014-05-21 21:30:24 +02:00
Camilla Berglund
1fed6f8abd Fixed name of global TLS state macro. 2014-04-08 17:47:38 +02:00
Camilla Berglund
1127c0e6e5 Renamed Wayland files to match prefix. 2014-04-08 17:47:38 +02:00
Camilla Berglund
12b28c4bb9 Fixed name of global context state macro. 2014-04-08 17:47:38 +02:00
Camilla Berglund
7c925353a5 Renamed context module headers. 2014-04-08 17:47:38 +02:00
Camilla Berglund
17d9051b82 Separated time state from window system state. 2014-04-08 17:47:38 +02:00
Camilla Berglund
660034332d Separated joystick state from window system state.
This is partially in preparation for pending support for additional
joystick APIs like XInput, DirectInput and IOHID.
2014-04-08 16:07:21 +02:00
Jonas Ådahl
8e99996321 Introduce experimental Wayland backend
This patch introduces a new backend that enables GLFW applications to
run on Wayland. For now, only output is supported (windowed and
fullscreen). Pointer cursor management, input devices, clipboard etc are
not supported yet.

There are some concepts that can not be supported, more specifically
glfwSetWindowPos, glfwGetWindowPos and glfwSetCursorPos, as they are not
supported by Wayland.

This patch also changes the time and joystick implementations used by the
X11 backend to be shared between the Wayland backend and the X11 backend.
2014-04-08 16:07:20 +02:00
Camilla Berglund
b54c76d6a3 Removed typedef of removed struct. 2014-04-02 13:30:22 +02:00
Camilla Berglund
78efc18079 Split out TLS code into separate modules.
This allows the TLS code to be re-used by partial ports like EGL.
2014-03-30 15:24:09 +02:00
Camilla Berglund
eb3f75e03e Added glfwGetWindowFrameSize. 2014-03-30 10:57:32 +02:00
Camilla Berglund
8fa9cc0de3 Added GLFWimage struct. 2014-03-20 11:30:27 +01:00
Camilla Berglund
608de57358 Cleanup. 2014-03-20 11:30:27 +01:00
urraka
40c04a7565 Added support for custom system cursors.
This adds 3 functions to the GLFW API: glfwCreateCursor,
glfwDestroyCursor and glfwSetCursor.
2014-03-20 11:30:27 +01:00
Camilla Berglund
1ccc23268c Added glfwPostEmptyEvent. 2014-03-09 17:55:55 +01:00
Camilla Berglund
6d8e78cc95 Further separation of window and context.
The context related parts of _GLFWwndconfig have been moved to
_GLFWctxconfig and given better names.  Window hint and attribute
members have been renamed to match.
2014-03-06 20:07:58 +01:00
Camilla Berglund
ae8393c06e Fixed refresh of debug context attribute. 2014-03-06 15:29:45 +01:00
Camilla Berglund
e2d6f2761c Fixed constness of function parameters. 2014-03-06 14:37:13 +01:00
Camilla Berglund
611006af18 Updated API version in comment headers. 2014-01-22 01:32:00 +01:00
Camilla Berglund
8f349e84ae Cleaned up drop callback design. 2014-01-21 18:23:25 +01:00
arturo
89d0723ba3 Initial drag and drop support. 2014-01-21 15:25:49 +01:00
Camilla Berglund
0548c713e8 Renamed monitor helper functions for clarity. 2014-01-21 15:23:11 +01:00
Camilla Berglund
e0a26aa62f Cursor mode cleanup. 2014-01-15 14:23:34 +01:00
Camilla Berglund
7e806a8567 Started 3.1. 2014-01-01 15:29:57 +01:00
Camilla Berglund
06289110e7 Documented utility functions. 2013-11-24 23:31:26 +01:00
Camilla Berglund
0ccbddf767 Moved version number macro to internal.h.
This lets alternative build environments avoid having to manually keep
track of which version of GLFW is being built.
2013-11-20 13:58:57 +01:00
Camilla Berglund
23021422f3 Added explicit configuration header macro. 2013-11-20 12:06:07 +01:00
Camilla Berglund
2c920fbb8b Clarified character callback parameter. 2013-10-10 19:41:56 +02:00
Andrew Corrigan
34f1c298b6 config.h.in --> glfw_config.h.in 2013-10-04 09:41:08 -04:00
Camilla Berglund
63a191eb8d Added clearing of callbacks on terminate. 2013-07-30 17:06:06 +02:00
Camilla Berglund
3cfc400cf9 Simplified source file comment headers. 2013-07-30 14:46:52 +02:00
Camilla Berglund
f7282e86c0 Added pointer swap macro for callback setters. 2013-07-30 14:44:56 +02:00
Camilla Berglund
d7512f529c Clarified names of gamma array helper functions. 2013-07-04 14:52:58 +02:00
Camilla Berglund
11615fcaf2 Added scancode to key callback. 2013-06-05 23:46:09 +02:00
Camilla Berglund
180a4ee640 Fixed constness of joystick data. 2013-06-04 18:20:38 +02:00
Camilla Berglund
3498163da1 Separated window and framebuffer sizes. 2013-06-04 01:51:54 +02:00
Camilla Berglund
2cd34386bc Added back refresh rate window hint. 2013-05-30 20:42:59 +02:00
Camilla Berglund
ad1f6f0341 Renamed glfwGetWindowParam to glfwGetWindowAttrib.
Parameters are something specified at creation time and are often
immutable, while many of the values returned by glfwGetWindowParam
reflected current state not controlled by any parameter or hint.
2013-05-27 15:30:32 +02:00
Camilla Berglund
15ed715f4e Moved public headers to the GLFW directory. 2013-05-22 22:46:34 +02:00
Camilla Berglund
ce1e84def6 Made glfwGetVideoMode consistent with getters. 2013-05-22 22:16:43 +02:00
Camilla Berglund
5d308db654 New gamma ramp API. 2013-05-22 21:56:14 +02:00
Camilla Berglund
2d1b835711 Added a conservative set of key modifiers. 2013-05-22 21:56:14 +02:00
Camilla Berglund
7f2eb7b15b New joystick API. 2013-05-22 21:56:14 +02:00
Camilla Berglund
d82f068f7e Reintroduced manual framebuffer config selection.
The default behavior of WGL, EGL and GLX is to choose a config that has
/at least/ the specified number of bits, whereas the GLFW 2 behavior was
to choose the closest match with very few hard constraints.  Moving the
responsibility of finding the supported minimum values to the client was
problematic, as there's no way to enumerate supported configurations,
forcing the client to perform multiple (and slow) window/context
creation attempts.  Not even the currently set defaults (24-bit color
and depth, 8-bit stencil) is universally supported, as bug reports show.
2013-05-13 15:58:36 +02:00
Camilla Berglund
0046b210e2 Merged hints into library struct. 2013-04-24 23:47:08 +02:00
Camilla Berglund
7405bc48cd Added proper monitor comparison. 2013-04-22 14:44:45 +02:00
Camilla Berglund
57751a5494 Added initial NSScreen integration.
This (tentatively) fixes the bug of full screen windows on OS X always
opening on the primary monitor.
2013-04-17 23:11:04 +02:00
Camilla Berglund
f06a700307 Renamed support directory to deps. 2013-04-17 15:42:21 +02:00
Camilla Berglund
008376d450 Restore cursor position on capture mode exit. 2013-04-16 20:46:58 +02:00
Camilla Berglund
49db3b2a9e Formatting. 2013-04-08 15:24:24 +02:00
NathanSweet
8e2e7b37a1 Undecorated window support on win/mac/linux. 2013-04-08 15:24:24 +02:00
Camilla Berglund
129e94da2e Changed cursor pos to double. 2013-04-04 16:29:40 +02:00
Camilla Berglund
71d2b574f8 Converted docs to hybrid Markdown. 2013-03-12 15:33:05 +01:00
Camilla Berglund
d0e4c874c3 Moved sticky state. 2013-03-01 15:18:53 +01:00
Camilla Berglund
182e0afe25 Made character unsigned. 2013-02-25 17:02:28 +01:00
Camilla Berglund
7b3783abe2 Made glfwGetMonitorPos immediate. 2013-02-20 18:15:03 +01:00
Camilla Berglund
a591cdeba6 Removed platform-specific resources from monitor. 2013-02-20 18:15:03 +01:00
Camilla Berglund
719b60dd2b Added macros for library initialization check. 2013-02-20 18:15:03 +01:00
Camilla Berglund
1961cecb7c Made glfwGetPrimaryMonitor always return a handle.
Replaced the primary flag with the convention of putting the primary
monitor first in the returned array.
2013-02-17 19:11:16 +01:00
Camilla Berglund
253e0d6b23 Added GLFW_REPEAT. 2013-02-15 13:21:11 +01:00
Camilla Berglund
6f8084f061 Documentation work.
Enabled Doxygen tree view, added CMake options for native and internal
modules, improved internal and native documentation.
2013-02-14 17:26:27 +01:00
Camilla Berglund
92a71e07d3 Made gamma ramp functions per-monitor. 2013-02-12 14:03:51 +01:00
Camilla Berglund
7c1932381b Reintroduced glfwGetWindowPos, glfwSetWindowPos. 2013-02-11 19:43:08 +01:00
Camilla Berglund
a910f53be2 Made glfwGetGammaRamp act directly. 2013-02-04 12:33:10 +01:00
Camilla Berglund
2cea6e37cf Removed glfwGetScrollOffset.
Scroll events do not represent an absolute state, but rather an interpretation
of a relative change in state, like character input.  So, like character input,
there is no sane 'current state' to return.  The here removed solution, that of
accumulating an offset since the last call to event processing, is at best
mildly confusing.  If a user wishes to implement this solution, it is better for
it to be explicit in client code than implicit in GLFW calls.
2013-02-04 12:33:09 +01:00
Camilla Berglund
c17a7dd464 Made glfwGetWindowSize immediate.
Conflicts:
	src/internal.h
2013-02-04 12:33:09 +01:00
Camilla Berglund
38aef53b0c Shortened window struct member. 2013-01-25 00:42:45 +01:00
Camilla Berglund
52a79c6f3b Added error for no selected client library. 2013-01-25 00:41:02 +01:00
Camilla Berglund
355af57b91 Renamed internal macro to match conventions. 2013-01-17 18:59:35 +01:00
Camilla Berglund
f479b1920f Formatting of internal.h. 2013-01-17 18:59:35 +01:00
Camilla Berglund
e51e049ad5 Added error for no selected client library. 2013-01-16 06:38:17 +01:00
Camilla Berglund
8d60214fac Put window callbacks in a substruct. 2013-01-15 21:34:26 +01:00
Camilla Berglund
a8ea120cae Removed internal fbconfig enum and selection. 2013-01-15 20:00:27 +01:00