Commit Graph

280 Commits

Author SHA1 Message Date
Pietro Gagliardi ffe9a2db28 Got rid of the GtkScrollable code from GtkDrawingArea for uiArea. Woo! Now we just have to nuke all that from the Cocoa backend and we're good. 2015-12-17 14:48:58 -05:00
Pietro Gagliardi 4e256dfc95 Fixed some oversights in the GTK+ uiArea code. 2015-12-16 18:09:04 -05:00
Pietro Gagliardi 3f9862c472 OUCH. Fixed a MASSIVE bug in the GTK+ implementation of uiWindow: uiWindowSetChild() was DESTROYING the old child, not merely removing it! The other ports don't have this bug. 2015-12-12 15:30:56 -05:00
Pietro Gagliardi acf3b3564e Set up the new Unix build. Now to do the OS X build. 2015-12-11 18:37:15 -05:00
Pietro Gagliardi 70886e4ade Moved the old build files away. Yes that's right folks, we're redoing the build system *again*! Isn't that *fun*? 2015-12-10 18:49:50 -05:00
Pietro Gagliardi 2705f93305 Added uiMultilineEntry, wrote it on GTK+, and wrote the uiQueueMain() test. It works on Unix. 2015-12-06 01:18:32 -05:00
Pietro Gagliardi f77955aefb Added uiQueueMain() (basically g_idle_add()) and implemented it on all platforms except Haiku. A test to come. After this we can start rewriting the Go package ui at long last. 2015-12-04 23:42:03 -05:00
Pietro Gagliardi 8084041139 Removed uiAreaHandler.RedrawOnResize(); Direct2D requires us to always redraw on resize (see previous commit). Added windows/amd64 to the example makefiles and updated them to use libui.xxx instead of new.xxx. 2015-12-04 21:04:51 -05:00
Pietro Gagliardi 3943c2c65e Implemented the dialog changes on the GTK+ backend. 2015-11-28 11:02:58 -05:00
Pietro Gagliardi ff9dcc6d58 Wrote the Haiku allocator and fixed some leftovers in other allocators. 2015-11-17 12:51:51 -05:00
Pietro Gagliardi c40e80d5a5 Added C++ to the build and started writing the actual Haiku code. I think this isg oing to have to require a GCC 4 hybrid... 2015-11-17 11:49:23 -05:00
Pietro Gagliardi 5e29d07d20 Moved all the table stuff out of the way. I need to decide what I'm going to do with it. 2015-11-16 10:52:19 -05:00
Pietro Gagliardi 5d26b9b059 Finished the uiTable test and fixed errors. 2015-10-19 10:52:36 -04:00
Pietro Gagliardi 056db88de0 More uiTable work. I'm not too happy anymore... 2015-10-18 18:55:06 -04:00
Pietro Gagliardi 4577cb79a1 Started the GTK+ implementation of uiTable and added uiTableSubscriptions. This is a mess already :D 2015-10-18 13:59:38 -04:00
Pietro Gagliardi f19d3cd0c7 More makefile work. 2015-10-16 22:49:54 -04:00
Pietro Gagliardi 790edf0df8 Assembled a new make system. Not quite working the way I'd like yet, but definitely a start. 2015-10-16 20:55:09 -04:00
Pietro Gagliardi ab97e26efc Moved all the common stuff in a new folder common/. This is part of the makefile simplification. 2015-10-16 18:31:14 -04:00
Pietro Gagliardi 1cadb85bd0 Added line dashing and implemented it on GTK+. 2015-10-16 10:09:41 -04:00
Pietro Gagliardi 6849b01f73 Switched coordinates to floating-point drawing space and implemented such on GTK+. 2015-10-14 08:49:06 -04:00
Pietro Gagliardi 2cbbc6c69d Removed the DPI fields from uiAreaDrawParams. We no longer worry about DPI. 2015-10-13 19:44:16 -04:00
Pietro Gagliardi cc827919b8 Added uiDrawClip() and implemented it on GTK+. 2015-10-13 11:16:06 -04:00
Pietro Gagliardi c6cdabe20d Preparation for proper, extensible state tracking and clipping on Windows. 2015-10-12 21:11:42 -04:00
Pietro Gagliardi 818d954654 More transformation tests and work. 2015-10-12 09:08:50 -04:00
Pietro Gagliardi de3ccecd5b Implemented skewing. Will do the test now. 2015-10-12 07:58:07 -04:00
Pietro Gagliardi 46e3fee40d Added a center point to scaling transforms. Fixed rotations on GTK+. 2015-10-12 01:43:12 -04:00
Pietro Gagliardi e51fd6e494 Implemented negative arcs on GTK+. 2015-10-11 21:18:39 -04:00
Pietro Gagliardi b09cdb5137 Made 90° point toward y=+∞. 2015-10-11 20:24:06 -04:00
Pietro Gagliardi 0ae3ef918d Implemented the matrix stuff on Windows. Also fixed the signature of uiDrawMatrixSkew(). 2015-10-11 12:36:48 -04:00
Pietro Gagliardi 3d8f8f0756 Implemented a basic translation. 2015-10-11 11:42:07 -04:00
Pietro Gagliardi 87680a6470 Built the framework for matrices and transformations and implemented it on the GTK+ backend. Tests to come next. 2015-10-11 11:13:01 -04:00
Pietro Gagliardi 7fbabfd8ec Fixed the GTK+ drawing code to draw arc initial line segments in the correct place. 2015-10-10 08:44:12 -04:00
Pietro Gagliardi 3cbc3f3c67 Made arc angles counterclockwise on the GTK+ backend and fixed the sun in the Direct2D geometries howto. 2015-10-09 23:13:15 -04:00
Pietro Gagliardi 73d77ef38b Capped sweeps at 2π radians. 2015-10-09 22:00:41 -04:00
Pietro Gagliardi 2c7ed07747 Changed the arc functions to take a start angle and a sweep amount instead of a start angle and an end angle. This makes it easier to reason about sweeps > 2π radians. 2015-10-09 21:51:43 -04:00
Pietro Gagliardi 7075bea0f5 Added uiAreaQueueRedrawAll() and implemented on all platforms. NOW we can focus exclusively on the test suite. 2015-10-09 15:27:57 -04:00
Pietro Gagliardi 843ea0d46c Implemented uiComboboxSetSelected() on GTK+. 2015-10-09 13:54:34 -04:00
Pietro Gagliardi 5d19387811 Did scrolling for the uiArea test and uiArea itself on GTK+. 2015-10-09 10:09:55 -04:00
Pietro Gagliardi 752467b543 Fixed up the GTK+ uiArea a bit. 2015-10-09 03:43:29 -04:00
Pietro Gagliardi ef04c18856 Merged the GTK+ uiArea implementation with its backend. Now we just have to move the test program. 2015-10-08 18:24:09 -04:00
Pietro Gagliardi 06f17aa4de Implemented the new uiCombobox stuff on GTK+. 2015-10-08 14:55:18 -04:00
Pietro Gagliardi 54332b90fb Finally merged out the redo folder. 2015-09-02 13:48:06 -04:00
Pietro Gagliardi 46b865a298 Begin the GTK+ backend migration. 2015-08-27 12:29:19 -04:00
Pietro Gagliardi 8213eac2d7 Moved everything up a directory level. 2015-08-27 12:05:11 -04:00
Pietro Gagliardi d98ca5dfd4 Removed more files from the top level. 2015-08-27 11:59:59 -04:00
Pietro Gagliardi 7abf88d9ef Finished reimplemented GTK+ uiTab. 2015-07-01 01:02:34 -04:00
Pietro Gagliardi 381c7e9277 Implemented the new bin system on uiTab. 2015-06-30 22:36:12 -04:00
Pietro Gagliardi 8e89f60330 Reimplemented GTK+ uiLabel. 2015-06-30 22:10:52 -04:00
Pietro Gagliardi a79368e26b Reimplemented GTK+ uiEntry. 2015-06-30 11:26:54 -04:00
Pietro Gagliardi 8361b4d41a Removed the old GTK+ uiCheckbox. 2015-06-30 11:20:28 -04:00
Pietro Gagliardi c73b506709 Reimplemented GTK+ uiCheckbox. 2015-06-30 11:20:14 -04:00
Pietro Gagliardi cf4dd17bb4 Removed the old unix/button.c. 2015-06-30 10:54:08 -04:00
Pietro Gagliardi 96172d9b04 Finished the implementation of GTK+ uiButton and implemented a few fixes and added some TODOs. 2015-06-30 10:52:38 -04:00
Pietro Gagliardi c8a53277c3 Readded the tab 2015-06-29 22:49:12 -04:00
Pietro Gagliardi da520af372 More GTK+ control stubbing. 2015-06-27 19:46:11 -04:00
Pietro Gagliardi 5ae4afd0d5 More work. Guess I'm creating all the widgets now... 2015-06-26 21:52:42 -04:00
Pietro Gagliardi 10e8d3203f Started migrating the GTK+ container. 2015-06-15 23:03:07 -04:00
Pietro Gagliardi 58a4b5d2da More work. uiSizing on Unix done. 2015-06-15 22:36:49 -04:00
Pietro Gagliardi 61b791d9f1 Moved uipriv_unix.h back. 2015-06-14 00:58:10 -04:00
Pietro Gagliardi 930c4e6883 More migration. 2015-06-11 18:01:05 -04:00
Pietro Gagliardi 8d9e229183 Started the new GTK+ backend. Migrated files that don't need changing back. 2015-06-09 22:45:35 -04:00
Pietro Gagliardi f100989803 Fixed up wording on some errors in windows/menu.c and unix/menu.c. 2015-05-13 10:25:54 -04:00
Pietro Gagliardi a517beccae Added uiContainerUpdate() calls to each SetMargined(). 2015-05-11 12:42:13 -04:00
Pietro Gagliardi 2c9e63d8d2 Same as previous commits, but for uiContainer. We don't need to do these because everything that calls uiControlSetParent() (which should only ever be a uiContainer) should also be updating themselves afterward (or are about to be destroyed). 2015-05-11 12:20:41 -04:00
Pietro Gagliardi df376a5e0b Started to optimize container updating. Removed container updates from each new control set parent. 2015-05-11 12:16:28 -04:00
Pietro Gagliardi c6b4d80602 Decided what to do about menuless menubars and implemented it. 2015-05-11 00:15:40 -04:00
Pietro Gagliardi c0c6b4fed6 Made all variables that refer to a tab page be called 'page'. 2015-05-10 21:22:22 -04:00
Pietro Gagliardi 8f24dffa01 Migrated the GTK+ backend to the new uiBin system. 2015-05-10 14:05:59 -04:00
Pietro Gagliardi b08e8f36d4 Inhibited uiEntryOnChanged() with uiEntrySetText() on GTK+. 2015-05-09 21:05:51 -04:00
Pietro Gagliardi 5ef355f28f Implemented the ShouldQuit() stuff for the Quit menu item on the GTK+ backend. 2015-05-09 10:50:03 -04:00
Pietro Gagliardi d43c8b5584 Fixed some latent bugs in unix/menu.c. 2015-05-08 14:14:05 -04:00
Pietro Gagliardi 5cf19dcc17 Added the type names back to the allocators. Implemented on GTK+ only for now. 2015-05-08 10:24:03 -04:00
Pietro Gagliardi 057c6d0cfd Implemented menu uninit on GTK+. 2015-05-08 10:17:33 -04:00
Pietro Gagliardi dc7274c067 Fixed a bug in unix/alloc.c. 2015-05-07 23:35:43 -04:00
Pietro Gagliardi f544414299 Added allocation tracking to the GTK+ backend. 2015-05-07 23:10:19 -04:00
Pietro Gagliardi 27d6994bdc Implemented stub uiUninit()s. 2015-05-07 22:32:17 -04:00
Pietro Gagliardi e19f52f542 Made Unix uiTab scrollable. 2015-05-07 20:33:09 -04:00
Pietro Gagliardi 6c9a122a7d Changed the default uiWindowOnClosing() behavior. Decided to keep the int return. 2015-05-07 20:01:17 -04:00
Pietro Gagliardi 34f55321e0 Added a [libui] and a newline to the message printed by complain(). 2015-05-07 19:34:45 -04:00
Pietro Gagliardi 727b6871bc Made uiFree(NULL) illegal to spot bugs. 2015-05-07 17:45:55 -04:00
Pietro Gagliardi 2107595ce7 "Exported" uiSizing fields. 2015-05-07 14:33:46 -04:00
Pietro Gagliardi 9d45ca5ecd Implemented read-only uiEntries on GTK+. 2015-05-06 23:18:55 -04:00
Pietro Gagliardi 180a17a235 Implemented uiEntryOnChanged() on GTK+. 2015-05-06 20:37:42 -04:00
Pietro Gagliardi 7981c5e7da Implemented uiTabInsertPageBefore() on GTK+. 2015-05-06 14:32:07 -04:00
Pietro Gagliardi a15bb12ad1 Implemented proper bin destruction on the GTK+ backend. 2015-05-06 01:31:06 -04:00
Pietro Gagliardi ed9539de94 Fixed an error in the previous few commits. 2015-05-04 20:02:00 -04:00
Pietro Gagliardi cf44574bbb Redid the GTK+ allocator to be simpler to prepare for the OS X code. 2015-05-04 19:55:39 -04:00
Pietro Gagliardi 58954ed201 Fixed up realloc() to zero extra memory on GTK+. Thanks to Rena (irc.badnik.net) and hyphenated (irc.freenode.net/#go-nuts) for confirming my memset() and spotting errors. 2015-05-04 19:26:05 -04:00
Pietro Gagliardi 8b8be286ff Made private functions in the various bin source files static. 2015-05-04 17:42:20 -04:00
Pietro Gagliardi 00d27ef83b More long-term TODO moving. 2015-05-04 17:39:50 -04:00
Pietro Gagliardi e571a73247 Made an executive decision about the behavior of uiControlShow() on uiWindows. 2015-05-04 17:23:01 -04:00
Pietro Gagliardi b2e9b646a4 Got rid of typedefs in the various newcontrol files for consistency. 2015-05-04 15:51:23 -04:00
Pietro Gagliardi 33c34c1572 Made a comment in the previous commit more clear. 2015-05-04 00:17:23 -04:00
Pietro Gagliardi d57df09f0e Fixed a latent bug with uiTab on GTK+. 2015-05-04 00:16:31 -04:00
Pietro Gagliardi fd4c559e86 Removed the typename argument from uiAlloc() and uiRealloc(). 2015-05-03 19:52:24 -04:00
Pietro Gagliardi 325f16cfb3 Added some comments to the previous commit. 2015-05-03 18:15:12 -04:00
Pietro Gagliardi 84894f2fb0 Implemented the GTK+ preferred size vtable functions for uiContainer. 2015-05-03 18:05:52 -04:00
Pietro Gagliardi 2186192502 Changed c-> to uiControl(c)-> in the various newcontrol files for consistency. 2015-05-03 14:44:46 -04:00
Pietro Gagliardi ac8bc029ef More TODOs. 2015-05-03 10:28:25 -04:00
Pietro Gagliardi 454b3ecb03 Changed the various OS-side control creation functions to use Make like uiMakeContainer() does instead of New. 2015-05-02 20:51:00 -04:00
Pietro Gagliardi 57bc11d67c TODO consolidation. 2015-05-02 14:58:29 -04:00
Pietro Gagliardi 5d28ffd334 Removed a stale TODO. 2015-05-02 14:55:12 -04:00
Pietro Gagliardi a0b29d599e Removed an unnecessary TODO. 2015-05-01 17:10:36 -04:00
Pietro Gagliardi 5ad2bfd6f0 Cleaned up uipriv*.h. 2015-05-01 10:14:11 -04:00
Pietro Gagliardi 122b1b0d2c Some TODO consolidation. 2015-05-01 10:11:22 -04:00
Pietro Gagliardi 20d0c40ad4 Removed previous commit's TODO; more TODOs. 2015-04-30 22:56:09 -04:00
Pietro Gagliardi 0ee2a72446 Exported the GTK+ backend's strdupText() as uiUnixStrdupText(). 2015-04-30 22:55:06 -04:00
Pietro Gagliardi b3fec90537 Decided that uiLabels should be top-aligned; implemented on GTK+. Other backends don't need changing. 2015-04-30 22:44:08 -04:00
Pietro Gagliardi 64dd45343d TODO shuffling. 2015-04-30 19:29:19 -04:00
Pietro Gagliardi 2dbf42a717 Removed the base GTK+ menu item and switched to simple boolean flags, for parity and simplicity like on Windows. 2015-04-30 19:26:49 -04:00
Pietro Gagliardi 3673ac7d2e Fixed reliance on sizeof (gulong) <= sizeof (gpointer) in unix/menu.c. 2015-04-30 19:13:36 -04:00
Pietro Gagliardi 358ae23d34 More TODOs. 2015-04-30 18:34:54 -04:00
Pietro Gagliardi 185d9cf122 Made refcounting for new control on GTK+ and OS X consistent. 2015-04-30 17:57:54 -04:00
Pietro Gagliardi 40dee5a693 Added bin destruction OS parent checks. 2015-04-30 17:49:38 -04:00
Pietro Gagliardi 6400a6ea8c TODO consolidation. 2015-04-30 17:34:15 -04:00
Pietro Gagliardi 75b4d28569 Implemented menu destruction on Windows. 2015-04-30 17:05:41 -04:00
Pietro Gagliardi b52aa4cfcb Started Windows menu destruction code and fixed a bug in GTK+ menu destruction. 2015-04-30 16:44:06 -04:00
Pietro Gagliardi 180ca3d8d4 Implemented the new tab functions on the GTK+ backend. 2015-04-30 15:31:25 -04:00
Pietro Gagliardi 437b895b53 Some more TODO cleanup, including mistaken TODO removal. 2015-04-30 15:18:11 -04:00
Pietro Gagliardi c8695e4ca2 Decided to remove allocation logging. Leak checking can be done with dedicated tools. 2015-04-30 13:37:13 -04:00
Pietro Gagliardi 127f025eee Decided not to bother with destruction blocking for now. 2015-04-30 13:30:00 -04:00
Pietro Gagliardi 7a70c3f568 Added duplication guards to Quit, Preferences, and About items on GTK+. 2015-04-30 13:02:30 -04:00
Pietro Gagliardi 45a204744f Implemented menu deletion on window destruction on the GTK+ backend. 2015-04-30 12:36:50 -04:00
Pietro Gagliardi 9eede9d8ae Set up a framework for menu deletion on GTK+. 2015-04-30 12:05:18 -04:00
Pietro Gagliardi 4c1b281b79 More TODOs. 2015-04-30 10:14:40 -04:00
Pietro Gagliardi 40d24ae626 Switch GTK+ control implementations from calling g_strdup() directly to strdupText() for orthogonality. 2015-04-30 10:12:33 -04:00
Pietro Gagliardi 8f79f0596f Set hidden flag variables BEFORE updating parent containers. Otherwise, parents won't reposition children correctly on systems where updates happen immediately (like OS X). 2015-04-29 14:25:34 -04:00
Pietro Gagliardi 6c6bce3702 Moved everything back to the top level. 2015-04-29 11:02:38 -04:00
Pietro Gagliardi ff14f76bad Migrated the GTK+ basic controls back. It doesn't quite work... 2015-04-29 10:36:31 -04:00
Pietro Gagliardi 4c280ca42c Removed or moved a bunch of stale files from the old source. All that's left now is to re-add the main controls and recreate the test program. 2015-04-29 10:20:25 -04:00
Pietro Gagliardi 390899f803 Added the GTK+ implementation of uiTab, for the most part I think. 2015-04-29 00:57:51 -04:00
Pietro Gagliardi 699cd12a19 Migrated unix/newcontrol.c back. Fixed an oversight in unix/container.c. 2015-04-28 21:30:38 -04:00
Pietro Gagliardi 7c91616af1 More old code file removal. 2015-04-28 13:53:45 -04:00
Pietro Gagliardi bf401201f9 Removed a whole bunch of files from the old source tree. 2015-04-28 13:51:13 -04:00
Pietro Gagliardi 1b1cd2e11e Changed the GTK+ backend menu code to honor what was just changed. 2015-04-20 23:38:23 -04:00
Pietro Gagliardi b7e2905c72 More implementation of menus on GTK+. 2015-04-20 18:56:42 -04:00
Pietro Gagliardi 9f82838632 Started implementing menus in general and on the Unix backend. 2015-04-20 18:34:51 -04:00
Pietro Gagliardi 21a29a5468 More destruction rules following code. 2015-04-19 22:59:06 -04:00
Pietro Gagliardi 24469a6e7b Added code to check that a control is not destroyed while it has a parent. This isn't enough for uiStack, though... 2015-04-19 22:53:09 -04:00
Pietro Gagliardi 8179d66ae6 More error checking in unix/parent.c. 2015-04-19 09:42:06 -04:00
Pietro Gagliardi a5e4060b67 Started splitting out lifetime management code into its own place on the GTK+ backend. 2015-04-19 01:37:11 -04:00
Pietro Gagliardi 89d584cdcd Finished cleaning up the GTK+ lifetiming code. Yeah, this will definitely work. 2015-04-18 17:46:37 -04:00
Pietro Gagliardi 48c609b5c3 Cleaned up the lifetime code in unix/newcontrol.c a fair bit. 2015-04-18 17:36:12 -04:00
Pietro Gagliardi ae94993730 Settled GTK+ Tab TODOs. 2015-04-18 17:28:13 -04:00
Pietro Gagliardi d0c0188ef9 Switched out calls to g_error() for calls to complain(). 2015-04-18 17:23:36 -04:00
Pietro Gagliardi 1abd5ebb4c Added complain() on the GTK+ backend. 2015-04-18 17:20:05 -04:00
Pietro Gagliardi ccba4aef46 Made destroy functions on the Unix backend take a void * instead of storing the uiControl *. 2015-04-18 17:14:19 -04:00
Pietro Gagliardi 710e3fa69c Fixed Unix tab lifetimes. 2015-04-18 13:43:05 -04:00
Pietro Gagliardi 2434e8d004 More Unix control destruction fixups. Now to finally hook together the tab fixup. 2015-04-18 13:38:19 -04:00
Pietro Gagliardi 38b118f033 Migrated the various controls to the new GTK+ destruction method. Just a few more small changes to make... 2015-04-18 13:33:08 -04:00