|
|
@@ -151,7 +151,7 @@ package body ui is |
|
|
|
|
|
|
|
procedure draw_structure (data : in structure) is |
|
|
|
offset : constant integer := core.icon; |
|
|
|
new_width : constant integer := (if data.resize then 300 else data.width); |
|
|
|
new_width : constant integer := (if data.resize then 320 else data.width); |
|
|
|
new_height : constant integer := (if data.resize then data.gui_n * core.icon + 2 * offset else data.height); |
|
|
|
new_x : constant integer := (if data.center then (core.window_width - new_width) / 2 else data.x); |
|
|
|
new_y : constant integer := (if data.center then (core.window_height - new_height) / 2 else data.y); |
|
|
@@ -166,8 +166,8 @@ package body ui is |
|
|
|
case data.gui_list (x).kind is |
|
|
|
when gui_button => |
|
|
|
draw_icon (data.gui_list (x).image, "", at_x, at_y); |
|
|
|
draw_frame ("", at_x + core.icon, at_y, new_width - 2 * offset - core.icon, core.icon); |
|
|
|
write (data.gui_list (x).text, at_x + core.icon, at_y); |
|
|
|
draw_frame ("", at_x + core.icon + 2, at_y, new_width - 2 * offset - core.icon - 2, core.icon); |
|
|
|
write (data.gui_list (x).text, at_x + core.icon + 6, at_y + 2); |
|
|
|
at_y := at_y + core.icon; |
|
|
|
when others => null; |
|
|
|
end case; |
|
|
@@ -331,7 +331,7 @@ package body ui is |
|
|
|
-- |
|
|
|
draw_horizontally (title_bar_middle, x + sprite (active, title_bar_left).width, y - sprite (active, title_bar_middle).height, middle_width); |
|
|
|
-- |
|
|
|
core.write (title, x + sprite (active, title_bar_left).width / 2 + 16, y - sprite (active, title_bar_middle).height / 2 - 8, font (active)); |
|
|
|
core.write (title, x + sprite (active, title_bar_left).width / 2 + 20, y - sprite (active, title_bar_middle).height / 2 - 6, font (active)); |
|
|
|
-- |
|
|
|
select_text_box (title, x, y - sprite (active, title_bar_middle).height, width, sprite (active, title_bar_middle).height); |
|
|
|
end draw_title_bar; |
|
|
|