Commit Graph

99 Commits (3e15dfc4cb94b58c4a2edfe987f3f91c61a68f1e)

Author SHA1 Message Date
Björn Lindqvist 62542c52a9 ui: try and ensure that the ui thread finishes #1905 2018-01-29 07:55:36 +01:00
Björn Lindqvist dd36f6ad57 ui: the with-ui-running combinator can be removed
It was only used within the (with-ui) words which in turn were only
called by with-ui.
2018-01-29 07:18:39 +01:00
John Benediktsson cccdc09a71 ui: rename ui-windows to worlds. 2018-01-22 13:17:23 -08:00
Alexander Iljin e07ba18839 ui: add find-windows to find multiple worlds matching a predicate 2018-01-22 07:58:17 -08:00
Björn Lindqvist f93da595f5 ui: undoing 9e9b70005b
The ui-thread variable absolutely is needed to ensure that only one UI
thread is running at the same time. If more than one UI thread runs,
they will be competing for events which causes all sorts of problems.
2018-01-18 17:30:51 +01:00
Björn Lindqvist 9f1935c7f1 ui.*: lets rename ui-running to with-ui-running
Because it is really annoying with global variables having the same name
as words.
2018-01-18 16:48:35 +01:00
Björn Lindqvist 9e9b70005b ui: the ui-thread variable isn't needed 2017-06-27 23:47:35 +02:00
Björn Lindqvist fe41e99437 ui: better handling of cascading errors
The second update-ui is wrapped in a recover so that if it fails
again, the UI system is stopped. That should fix the cascade problem
in #1827.
2017-06-27 23:47:35 +02:00
Alexander Iljin 646f14f249 ui-docs: mark an optional output parameter with the "/f" suffix 2017-05-26 14:39:33 +03:00
John Benediktsson 3edf8f594a ui: ceiling world dimensions when opening. 2016-05-06 20:57:03 -07:00
John Benediktsson 8a3dd3709e ui: adding a WINDOW: that is like MAIN-WINDOW: but without making the word a main word. 2016-04-21 10:13:57 -07:00
Björn Lindqvist 763b892a1d ui.*: move some of the gl initing to set-up-window, should fix #1510
it's also more efficent to run the check-extensions "1.0"
require-gl-version code only once when the window is created, rather
than once for each draw
2015-12-01 04:49:36 +01:00
Björn Lindqvist 7bc1009973 ui.*: make active? an integer 0-100
A UI backend can delay setting active? to 100 until the windows actually
is visible. That way, some redundant redraws that happen when the window
isn't visible is supressed. It makes the Windows and GTK UI startup a
little faster.
2015-10-27 19:00:28 +01:00
Björn Lindqvist 9af7be2ef9 ui: the layout-queue is more efficient as a vector than a dlist
Improves memory usage in the #1488 example from about 20,4% to 17,4% on
my machine.
2015-10-15 18:34:49 +02:00
John Benediktsson e477f6996f Fix comments to be ! not #!. 2015-09-08 16:15:10 -07:00
Doug Coleman 330c7ba156 factor: Removing SLOT: nth/at/global in favor of using change: at for tuple slots named ``at`` and change-at for hashtables.
Redo many FROM: and QUALIFIED: and using lists.
2015-08-12 08:49:02 -05:00
Doug Coleman 958d5e61b2 ui: rename windows to ui-windows 2015-06-10 15:36:35 -07:00
John Benediktsson b366a06c41 use reject instead of [ ... not ] filter. 2015-05-12 18:50:34 -07:00
John Benediktsson c75fc48f23 switch some vocabs to 4 spaces. 2013-07-24 14:52:09 -07:00
Jon Harper b023ebf7a5 Add resize-window and relayout-window 2012-11-26 14:39:54 -08:00
John Benediktsson f1c62deb03 ui: use "windows get-global". 2012-09-21 15:39:49 -07:00
John Benediktsson 17edc5e63a ui: short-circuit layout-queued if deque is empty. 2012-07-31 20:26:51 -07:00
John Benediktsson 8c1165cac1 cleanup some lint warnings. 2012-04-18 17:46:01 -07:00
John Benediktsson 80e1c8e3f2 Eliminate duplicate syntax for stack effects "(" no longer drops and is identical to the old "((", which is now removed. 2011-10-18 13:19:39 -07:00
Doug Coleman 76580da5d5 Refactor the lexer/parser to expose friendlier words for scanning tokens. The preferred top-level words now throw an exception on EOF.
CREATE -> scan-new
CREATE-CLASS -> scan-new-class
CREATE-WORD -> scan-new-word
CREATE-GENERIC -> scan-new-generic
scan -> (scan-token)
scan-token now throws on eof
(scan-word) returns word/number/f
scan-word now throws on eof
scan-word-name expects a non-number
Fixes #183.
Fixes #209.
2011-09-29 11:28:28 -07:00
John Benediktsson 3c1356bf69 Adding stack effects. 2011-09-23 17:46:40 -07:00
Joe Groff 2bd6de9a02 slots: pre-create the "at", "nth", and "global" slots to make deterministic the currently nondeterministic ambiguity between accessors:change-* and assocs:change-at, sequences:change-nth, and namespaces:change-global 2011-09-19 10:03:43 -07:00
Slava Pestov 35e5c572ce ui: cleanup 2010-07-17 16:09:25 -04:00
Slava Pestov 88ca7abd54 ui.gadgets.worlds: dispose of the handle after ungrabbing input 2010-07-17 16:08:36 -04:00
Slava Pestov bb4dae64f3 cocoa.subclassing: new METHOD: syntax cleans up class definitions 2010-07-06 17:59:35 -04:00
Doug Coleman 6a501d4aa3 Add a promise to world objects that gets fulfilled when the world is ungrafted 2010-06-16 16:23:30 -05:00
Joe Groff c8bb9b3381 ui: document non-polymorphic effect of with-ui, and that it doesn't return 2010-06-08 13:54:10 -07:00
Slava Pestov 212d308de1 ui: ditch window restore behavior since it was broken 2010-05-24 16:50:09 -04:00
Slava Pestov 627295f094 Language change: tuple slot setter words with stack effect ( value object -- ) are now named FOO<< instead of (>>FOO) 2010-05-06 17:21:02 -04:00
Daniel Ehrenberg da57436180 Finishing eliminating prune as a synonym of members 2010-02-27 14:52:24 -05:00
Joe Groff f6183703b2 ui: add a "system-alert" hook that can raise a system modal dialog without involving any potentially stripped gadget, io, or debugger code 2010-02-23 19:28:57 -08:00
Joe Groff 6bbfa0b6d8 GAME: syntax for defining game entry point with game-loop attributes 2010-01-16 12:18:50 -08:00
Joe Groff 5c52732c0a document MAIN-WINDOW: 2010-01-15 17:06:50 -08:00
Joe Groff 4beb8192c9 pry off some ui app boilerplate with a MAIN-WINDOW: syntax 2010-01-15 16:55:43 -08:00
Doug Coleman cc194416f9 Merge branch 'master' into startup
Conflicts:
	core/bootstrap/primitives.factor
	vm/run.hpp
2009-11-15 02:52:50 -06:00
Slava Pestov 951e3e9c83 delete-nth -> remove-nth! 2009-10-27 23:41:57 -05:00
Doug Coleman 6b6e56a179 change add-init-hook to add-startup-hook, new add-shutdown-hook word 2009-10-19 22:17:02 -04:00
Doug Coleman 3f3d57032b Delete empty unit tests files, remove 1- and 1+, reorder IN: lines in a lot of places, minor refactoring 2009-08-13 19:21:44 -05:00
Joe Groff 3a6a588532 destroy window-resources in reverse order 2009-07-04 19:13:53 -05:00
Joe Groff 97adae24f0 pardon my dust 2009-07-01 17:57:21 -05:00
Joe Groff 77104b7256 put a slot on worlds for window-resources which get disposed when window is closed 2009-07-01 13:54:42 -05:00
Joe Groff 76b1f9ce03 some new UI words: handles-gesture? checks whether a gesture will be handled. topmost-window returns the topmost world object 2009-06-22 19:01:50 -05:00
Joe Groff 54ad8f9dd9 stupid mutable state 2009-06-18 22:01:31 -05:00
Joe Groff 0169934f6d null-world class for interactive OpenGL use 2009-06-03 11:03:34 -05:00
Slava Pestov fb6df472a2 Cleaning up USING: lists for new strict semantics 2009-05-14 16:54:16 -05:00