Commit graph

43 commits

Author SHA1 Message Date
Emil Ernerfeldt
b73fbb33d8 Improve size negotiation code.
Better enfocred minimum sizes.
You can now have windows that expand to fit their content.
2020-05-01 02:08:01 +02:00
Emil Ernerfeldt
7cd8ac2bbf Rename Widget::add_to to Widget::ui 2020-04-29 22:01:39 +02:00
Emil Ernerfeldt
bf59455097 Add a bunch of TODOs 2020-04-29 21:58:41 +02:00
Emil Ernerfeldt
14db237b1d Basic text input support 2020-04-29 21:25:49 +02:00
Emil Ernerfeldt
cce048509f Refactor: make Rect members min/max public 2020-04-25 15:45:38 +02:00
Emil Ernerfeldt
4cc6ca7236 Use ..= range arguments to remap functions 2020-04-25 11:11:44 +02:00
Emil Ernerfeldt
663fbda90c Use min..=max syntax for slider ranges 2020-04-25 11:01:57 +02:00
Emil Ernerfeldt
02f3b6dddf std::f32::INFINITY -> f32::INFINITY 2020-04-25 10:52:20 +02:00
Emil Ernerfeldt
a66f4efaac Minor code cleanup and clippy fixes 2020-04-24 18:47:14 +02:00
Emil Ernerfeldt
b39555bb23 Add support for hyperlinks 2020-04-23 19:15:17 +02:00
Emil Ernerfeldt
b4ea51f0f9 Sliders: use title as id if available with scroll position as fallback
This fixes the sliders in the style window
2020-04-23 09:27:08 +02:00
Emil Ernerfeldt
fd8180cea4 Fix left alignment of widgets and tweak style slightly 2020-04-23 00:23:29 +02:00
Emil Ernerfeldt
104f2191a0 Improve Widget code, and make sure it paints within the given bounds 2020-04-22 19:39:51 +02:00
Emil Ernerfeldt
700c93b8e3 Add Rect left/right/top/bottom accessors 2020-04-22 19:38:38 +02:00
Emil Ernerfeldt
d941c5830d Unify style for buttons and collapsing headers 2020-04-22 19:03:38 +02:00
Emil Ernerfeldt
e9bdadb1da Some visual tweaks 2020-04-21 16:50:56 +02:00
Emil Ernerfeldt
864eae2081 Separate clip_rect and desired_rect in Region 2020-04-21 07:42:33 +02:00
Emil Ernerfeldt
472e0b9afe Refactor Region: remember region rectangle
This will be used as a clip rectangle for generated paint commands.
2020-04-20 00:48:54 +02:00
Emil Ernerfeldt
7f85b2623b Draw separator between window title and its contents 2020-04-19 23:51:38 +02:00
Emil Ernerfeldt
388132ba93 Implement window resizing 2020-04-19 23:44:24 +02:00
Emil Ernerfeldt
6eae91e028 Distinguish ids that need to be unique and warn about name clashes 2020-04-19 11:13:24 +02:00
Emil Ernerfeldt
1afda00fc4 Make it easier to create an Outline 2020-04-19 11:11:41 +02:00
Emil Ernerfeldt
2170081221 Use new type Pos2 for positions (points) instead of Vec2 2020-04-19 01:05:49 +02:00
Emil Ernerfeldt
624e709a8f Make Id a proper newtype 2020-04-18 09:32:39 +02:00
Emil Ernerfeldt
de76cb6190 Move Memory and Region to own files 2020-04-17 15:29:48 +02:00
Emil Ernerfeldt
0265b3d43a Refactor: define rect by min/max 2020-04-15 17:41:35 +02:00
Emil Ernerfeldt
d999962602 Refactor example code 2020-04-12 12:07:51 +02:00
Emil Ernerfeldt
be8eb02b3f Some minor fixes and additions 2019-11-02 09:50:49 +01:00
Emil Ernerfeldt
1d6bc3baba Minor API improvements 2019-04-25 18:07:36 +02:00
Emil Ernerfeldt
192b59ebb0 Refactor: remove GuiCmd 2019-03-11 15:59:49 +01:00
Emil Ernerfeldt
87288634e9 Refactor: Merge LayoutOptions and Style 2019-03-11 15:39:54 +01:00
Emil Ernerfeldt
e398668f96 Add support for usize sliders 2019-03-11 13:31:55 +01:00
Emil Ernerfeldt
79e38e39fe Fix: allow sliders without text 2019-03-10 21:00:44 +01:00
Emil Ernerfeldt
2583fd2c52 integer sliders 2019-02-10 16:10:08 +01:00
Emil Ernerfeldt
f0c879b2f4 Code cleanup: allow None mouse_pos + clippy fixes 2019-02-10 15:30:48 +01:00
Emil Ernerfeldt
ef4f0908f2 make label into a macro 2019-01-21 01:48:32 -06:00
Emil Ernerfeldt
cd8ca47e76 Small tweaks 2019-01-19 10:09:00 -06:00
Emil Ernerfeldt
7f83876005 Enable colored text (and other misc fixes) 2019-01-16 09:28:43 -06:00
Emil Ernerfeldt
2c0ca77e09 Add support for alignment (min, center, max) in horizontal and vertical layouts 2019-01-15 04:50:30 -06:00
Emil Ernerfeldt
3f84836c20 Add rect field to InteractInfo struct 2019-01-15 04:48:05 -06:00
Emil Ernerfeldt
6e8cc8439b Add separator widget 2019-01-13 19:15:11 +01:00
Emil Ernerfeldt
ca9333ec3e Support multiple fonts 2019-01-13 00:55:56 +01:00
Emil Ernerfeldt
8963a99a09 Rename to Emigui 2019-01-12 23:07:30 +01:00
Renamed from emgui/src/widgets.rs (Browse further)