GrafX2 2.9.3227
The ultimate 256-color painting program
windows.h File Reference

Graphical interface management functions (windows, menu, cursor) More...

#include "struct.h"
+ Include dependency graph for windows.h:
+ This graph shows which files directly or indirectly include this file:

Data Structures

struct  T_MultipleChoice
 
struct  T_Toolbar_button
 Definition of a toolbar button. More...
 
struct  T_Menu_Bar
 

Macros

#define ToWinX(x)   (((x)*Menu_factor_X)+Window_pos_X)
 
#define ToWinY(y)   (((y)*Menu_factor_Y)+Window_pos_Y)
 
#define ToWinL(l)   ((l)*Menu_factor_X)
 
#define ToWinH(h)   ((h)*Menu_factor_Y)
 
#define Update_window_area(x, y, w, h)   Update_rect(Window_pos_X+(x)*Menu_factor_X,Window_pos_Y+(y)*Menu_factor_Y,(w)*Menu_factor_X,(h)*Menu_factor_Y);
 

Enumerations

enum  {
  MENUBAR_STATUS = 0 , MENUBAR_ANIMATION , MENUBAR_LAYERS , MENUBAR_TOOLS ,
  MENUBAR_COUNT
}
 

Functions

void Display_cursor (void)
 
void Hide_cursor (void)
 Boolean: Need to hide/unhide cursor during this step. More...
 
void Remap_screen_after_menu_colors_change (void)
 
void Compute_optimal_menu_colors (const T_Components *palette)
 
void Position_screen_according_to_zoom (void)
 
void Compute_separator_data (void)
 
void Compute_magnifier_data (void)
 
void Clip_magnifier_offsets (short *x_offset, short *y_offset)
 
void Compute_limits (void)
 
void Compute_paintbrush_coordinates (void)
 
void Pixel_in_menu (word bar, word x, word y, byte color)
 
void Pixel_in_menu_and_skin (word bar, word x, word y, byte color)
 
void Pixel_in_window (word x, word y, byte color)
 
void Set_fore_color (byte color)
 
void Set_back_color (byte color)
 
void Frame_menu_color (byte id)
 Redraw the cell in the menu palette for Fore_color. More...
 
void Display_menu_palette (void)
 
void Display_menu (void)
 Display the whole menu. More...
 
void Display_layerbar (void)
 Display / update the layer menubar. More...
 
void Reposition_palette (void)
 
void Change_palette_cells (void)
 
int Pick_color_in_palette (void)
 
word Palette_cells_X (void)
 
word Palette_cells_Y (void)
 
void Print_general (short x, short y, const char *str, byte text_color, byte background_color)
 
void Print_general_unicode (short x, short y, const word *str, byte text_color, byte background_color)
 
void Print_in_window_underscore (short x, short y, const char *str, byte text_color, byte background_color, byte undersc_letter)
 Draws a string in a window with underscore undersc_letter is 0 for no underscore, 1-indexed array index otherwise. More...
 
void Print_in_window (short x, short y, const char *str, byte text_color, byte background_color)
 Draws a string in a window. More...
 
void Print_in_window_unicode (short x, short y, const word *str, byte text_color, byte background_color)
 Draws a string in a window. More...
 
void Print_in_window_limited (short x, short y, const char *str, byte size, byte text_color, byte background_color)
 Draws a char in a window, checking for bounds. More...
 
void Print_in_window_limited_unicode (short x, short y, const word *str, byte size, byte text_color, byte background_color)
 Draws a char in a window, checking for bounds. More...
 
void Print_char_in_window (short x_pos, short y_pos, unsigned int c, byte text_color, byte background_color)
 Draws a char in a window. More...
 
void Print_in_menu (const char *str, short position)
 
void Print_coordinates (void)
 Draws the mouse coordinates on the menu Only update the digits and doesn't refresh the "X: Y:" labels. More...
 
void Print_filename (void)
 
void Print_counter (short x, short y, const char *str, byte text_color, byte background_color)
 
byte Confirmation_box (const char *message)
 Window asking for confirmation before an action is performed. More...
 
void Warning_message (const char *message)
 Window that shows a warning message and wait for a click on the OK button. More...
 
void Warning_with_format (const char *message,...)
 Window that shows a warning message and waits for a click on the OK button. More...
 
void Verbose_message (const char *caption, const char *message)
 Window that shows a big message (up to 35x13), and waits for a click on OK. More...
 
int Requester_window (const char *message, int initial_value)
 Window that allows you to enter a single value. More...
 
int Dialog_multiple_choice (const char *title, const T_MultipleChoice *choices, int initial_choice)
 Ask the user to choose between multiple choices. More...
 
void Display_image_limits (void)
 
void Display_all_screen (void)
 
void Window_rectangle (word x_pos, word y_pos, word width, word height, byte color)
 
void Window_display_frame_generic (word x_pos, word y_pos, word width, word height, byte color_tl, byte color_br, byte color_s, byte color_tlc, byte color_brc)
 
void Window_display_frame_mono (word x_pos, word y_pos, word width, word height, byte color)
 
void Window_display_frame_in (word x_pos, word y_pos, word width, word height)
 
void Window_display_frame_out (word x_pos, word y_pos, word width, word height)
 
void Window_display_frame (word x_pos, word y_pos, word width, word height)
 
void Display_sprite_in_menu (int btn_number, char sprite_number)
 
void Display_paintbrush_in_menu (void)
 
void Display_paintbrush_in_window (word x, word y, int number)
 
void Draw_thingumajig (word x, word y, byte color, short direction)
 
void Display_grad_block_in_window (word x_pos, word y_pos, word width, word height, word block_start, word block_end)
 
void Window_display_icon_sprite (word x_pos, word y_pos, byte type)
 
byte Best_color (byte red, byte green, byte blue)
 
byte Best_color_nonexcluded (byte red, byte green, byte blue)
 
byte Best_color_range (byte red, byte green, byte blue, byte max)
 
byte Best_color_perceptual (byte r, byte g, byte b)
 
byte Best_color_perceptual_except (byte r, byte g, byte b, byte except)
 
void Horizontal_XOR_line_zoom (short x_pos, short y_pos, short width)
 
void Vertical_XOR_line_zoom (short x_pos, short y_pos, short height)
 
void Change_magnifier_factor (byte factor_index, byte point_at_mouse)
 Changes magnifier factor and updates everything needed. More...
 
void Copy_view_to_spare (void)
 Copy viewport settings and offsets from the Main to the Spare. More...
 

Variables

word Layer_button_width
 Width of one layer button, in pixels before scaling. More...
 
T_Toolbar_button Buttons_Pool [NB_BUTTONS]
 
T_Menu_Bar Menu_bars [MENUBAR_COUNT]
 

Detailed Description

Graphical interface management functions (windows, menu, cursor)

Macro Definition Documentation

◆ ToWinX

#define ToWinX (   x)    (((x)*Menu_factor_X)+Window_pos_X)

◆ ToWinY

#define ToWinY (   y)    (((y)*Menu_factor_Y)+Window_pos_Y)

◆ ToWinL

#define ToWinL (   l)    ((l)*Menu_factor_X)

◆ ToWinH

#define ToWinH (   h)    ((h)*Menu_factor_Y)

◆ Update_window_area

#define Update_window_area (   x,
  y,
  w,
 
)    Update_rect(Window_pos_X+(x)*Menu_factor_X,Window_pos_Y+(y)*Menu_factor_Y,(w)*Menu_factor_X,(h)*Menu_factor_Y);

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
MENUBAR_STATUS 
MENUBAR_ANIMATION 
MENUBAR_LAYERS 
MENUBAR_TOOLS 
MENUBAR_COUNT 

Function Documentation

◆ Display_cursor()

void Display_cursor ( void  )

References Brush_height, Brush_rotation_center_is_defined, Brush_rotation_center_X, Brush_rotation_center_Y, Brush_width, Config, T_Config::Cursor, Cursor_background, Cursor_hidden, T_Gui_skin::Cursor_offset_X, T_Gui_skin::Cursor_offset_Y, Cursor_shape, CURSOR_SHAPE_ARROW, CURSOR_SHAPE_BUCKET, CURSOR_SHAPE_COLORPICKER, CURSOR_SHAPE_HORIZONTAL, CURSOR_SHAPE_HOURGLASS, CURSOR_SHAPE_MULTIDIRECTIONAL, CURSOR_SHAPE_TARGET, CURSOR_SHAPE_THIN_COLORPICKER, CURSOR_SHAPE_THIN_TARGET, CURSOR_SHAPE_XOR_RECTANGLE, CURSOR_SHAPE_XOR_TARGET, T_Gui_skin::Cursor_sprite, CURSOR_SPRITE_HEIGHT, CURSOR_SPRITE_WIDTH, Display_paintbrush(), Draw_line_preview_xor(), Fore_color, Gfx, Horizontal_XOR_line, Horizontal_XOR_line_zoom(), Limit_bottom, Limit_left, Limit_left_zoom, Limit_right, Limit_top, Limit_top_zoom, Limit_visible_bottom_zoom, Limit_visible_right_zoom, T_Document::magnifier_height, T_Document::magnifier_mode, T_Document::magnifier_width, Main, Max(), MC_Trans, Menu_Y, Mouse_X, Mouse_Y, T_Document::offset_X, T_Document::offset_Y, Paintbrush_hidden, Paintbrush_X, Paintbrush_Y, Pixel, Pixel_figure_preview_xor(), Read_pixel, Screen_height, Screen_width, T_Document::separator_position, Transform_point(), Update_rect(), Vertical_XOR_line, Vertical_XOR_line_zoom(), Windows_open, and T_Document::X_zoom.

Referenced by Airbrush(), Airbrush_12_2(), Bigger_paintbrush(), Brush_12_0(), Button_Adjust(), Button_Airbrush(), Button_Airbrush_menu(), Button_Anim_continuous_next(), Button_Anim_continuous_prev(), Button_Anim_first_frame(), Button_Anim_last_frame(), Button_Anim_next_frame(), Button_Anim_prev_frame(), Button_Anim_time(), Button_Autosave(), Button_Brush(), Button_Brush_container(), Button_Brush_FX(), Button_Brush_monochrome(), Button_circle_ellipse(), Button_Circle_switch_mode(), Button_Clear(), Button_Clear_with_backcolor(), Button_Colorize_menu(), Button_Colorpicker(), Button_Constraint_menu(), Button_Copy_page(), Button_Curves(), Button_Curves_switch_mode(), Button_Draw(), Button_Draw_switch_mode(), Button_Effects(), Button_Empty_rectangle(), Button_Fill(), Button_Filled_polyform(), Button_Filled_rectangle(), Button_Grad_rectangle(), Button_Gradients(), Button_Grid_menu(), Button_Hide_menu(), Button_Invert_foreback(), Button_Kill(), Button_Lasso(), Button_Layer_add(), Button_Layer_down(), Button_Layer_duplicate(), Button_Layer_get_transparent(), Button_Layer_menu(), Button_Layer_merge(), Button_Layer_remove(), Button_Layer_set_transparent(), Button_Layer_up(), Button_Lines(), Button_Lines_switch_mode(), Button_Load_or_Save(), Button_Magnify(), Button_Magnify_menu(), Button_Message_initial(), Button_Page(), Button_Paintbrush_menu(), Button_Pal_left(), Button_Pal_left_fast(), Button_Pal_right(), Button_Pal_right_fast(), Button_Palette(), Button_Polyfill(), Button_Polyform(), Button_polygon(), Button_Quick_shade_menu(), Button_Quit(), Button_Quit_local_function(), Button_Redo(), Button_Reload(), Button_Replace(), Button_Resolution(), Button_Restore_brush(), Button_Safety_resolution(), Button_Secondary_palette(), Button_Select_backcolor(), Button_Select_forecolor(), Button_Settings(), Button_Show_grid(), Button_Sieve_menu(), Button_Skins(), Button_Smooth_menu(), Button_Snap_mode(), Button_Stats(), Button_Text(), Button_Tilemap_menu(), Button_Tiling_menu(), Button_Toggle_all_toolbars(), Button_Toggle_toolbar(), Button_Transform_menu(), Button_Undo(), Centered_lines_0_7(), Centered_lines_12_7(), Circle_12_5(), Colorpicker_1_1(), Colorpicker_2_1(), Confirmation_box(), Curve_34_points_1_5(), Curve_34_points_2_5(), Curve_3_points_0_5(), Curve_4_points_1_9(), Curve_4_points_2_9(), Curve_drag(), Curve_finalize(), Dialog_multiple_choice(), Distort_brush_1_0(), Distort_brush_1_9(), Draw_all_palette_sliders(), Dropdown_activate(), Ellipse_12_5(), Fill_1_0(), Fill_2_0(), Fill_general(), Filled_contour_0_8(), Filled_polyform_0_8(), Filled_polyform_12_8(), Freehand_mode1_1_2(), Freehand_mode1_2_2(), Freehand_mode2_1_2(), Freehand_mode2_2_2(), Get_color_behind_window(), Get_colors_from_brush(), Get_input(), Grad_circle_12_6(), Grad_circle_12_8(), Grad_ellipse_12_6(), Grad_ellipse_12_8(), Grad_rectangle_0_9(), Grad_rectangle_12_0(), Init_program(), K_line_12_6(), K_line_12_7(), Layer_activate(), Layer_preview_off(), Line_12_5(), Load_image(), Load_picture(), Load_SCR(), Magnifier_12_0(), Main_handler(), Menu_shade(), Menu_tag_colors(), Message_out_of_memory(), Move_separator(), Move_window(), Pan_view_0_0(), Pan_view_0_2(), Polybrush_12_8(), Polyfill_12_8(), Polyfill_12_9(), Polyform_0_8(), Polyform_12_8(), Polygon_12_9(), Quicksearch_list(), Readline_ex_unicode(), Rectangle_12_0(), Redefine_control(), Reduce_palette(), Replace_1_0(), Replace_2_0(), Requester_window(), Resize_image(), Return_to_draw_mode(), Rightclick_colorpick(), Rightclick_colorpick_0_1(), Rotate_brush_0_5(), Rotate_brush_1_5(), Save_C64_window(), Save_image(), Save_MOTO_window(), Save_picture(), Scroll_fileselector(), Scroll_help(), Scroll_list_of_modes(), Scroll_magnifier(), Scroll_screen(), Select_button(), Set_nice_menu_colors(), Shade_settings_menu(), Smaller_paintbrush(), Special_next_backcolor(), Special_next_forecolor(), Special_next_user_backcolor(), Special_next_user_forecolor(), Special_previous_backcolor(), Special_previous_forecolor(), Special_previous_user_backcolor(), Special_previous_user_forecolor(), Stretch_brush_0_7(), Stretch_brush_12_0(), Stretch_brush_1_7(), Tilemap_update(), Update_color_count(), Verbose_message(), Wait_click_in_palette(), Wait_click_in_shade_table(), Warning_message(), Window_clicked_button(), Window_dropdown_on_click(), Window_get_button_shortcut(), Window_get_clicked_button(), Window_help(), Window_Histogram(), Window_normal_button_onclick(), Window_set_shortcut(), Zoom(), and Zoom_set().

◆ Hide_cursor()

void Hide_cursor ( void  )

Boolean: Need to hide/unhide cursor during this step.

References Brush_height, Brush_rotation_center_is_defined, Brush_rotation_center_X, Brush_rotation_center_Y, Brush_width, Config, T_Config::Cursor, Cursor_background, Cursor_hidden, T_Gui_skin::Cursor_offset_X, T_Gui_skin::Cursor_offset_Y, Cursor_shape, CURSOR_SHAPE_ARROW, CURSOR_SHAPE_BUCKET, CURSOR_SHAPE_COLORPICKER, CURSOR_SHAPE_HORIZONTAL, CURSOR_SHAPE_HOURGLASS, CURSOR_SHAPE_MULTIDIRECTIONAL, CURSOR_SHAPE_TARGET, CURSOR_SHAPE_THIN_COLORPICKER, CURSOR_SHAPE_THIN_TARGET, CURSOR_SHAPE_XOR_RECTANGLE, CURSOR_SHAPE_XOR_TARGET, CURSOR_SPRITE_HEIGHT, CURSOR_SPRITE_WIDTH, Draw_line_preview_xor(), Gfx, Hide_paintbrush(), Horizontal_XOR_line, Horizontal_XOR_line_zoom(), Limit_bottom, Limit_left, Limit_left_zoom, Limit_right, Limit_top, Limit_top_zoom, Limit_visible_bottom_zoom, Limit_visible_right_zoom, T_Document::magnifier_height, T_Document::magnifier_mode, T_Document::magnifier_width, Main, Max(), Menu_Y, Mouse_X, Mouse_Y, T_Document::offset_X, T_Document::offset_Y, Paintbrush_hidden, Paintbrush_X, Paintbrush_Y, Pixel, Pixel_figure_preview_xor(), Screen_height, Screen_width, T_Document::separator_position, Transform_point(), Update_rect(), Vertical_XOR_line, Vertical_XOR_line_zoom(), Windows_open, and T_Document::X_zoom.

Referenced by Airbrush(), Airbrush_12_2(), Bigger_paintbrush(), Brush_0_5(), Button_Adjust(), Button_Airbrush(), Button_Airbrush_menu(), Button_Anim_continuous_next(), Button_Anim_continuous_prev(), Button_Anim_first_frame(), Button_Anim_last_frame(), Button_Anim_next_frame(), Button_Anim_prev_frame(), Button_Anim_time(), Button_Autosave(), Button_Brush(), Button_Brush_container(), Button_Brush_FX(), Button_Brush_monochrome(), Button_circle_ellipse(), Button_Circle_switch_mode(), Button_Clear(), Button_Clear_with_backcolor(), Button_Colorize_menu(), Button_Colorpicker(), Button_Constraint_menu(), Button_Copy_page(), Button_Curves(), Button_Curves_switch_mode(), Button_Draw(), Button_Draw_switch_mode(), Button_Effects(), Button_Empty_rectangle(), Button_Fill(), Button_Filled_polyform(), Button_Filled_rectangle(), Button_Grad_rectangle(), Button_Gradients(), Button_Grid_menu(), Button_Hide_menu(), Button_Invert_foreback(), Button_Kill(), Button_Lasso(), Button_Layer_add(), Button_Layer_down(), Button_Layer_duplicate(), Button_Layer_get_transparent(), Button_Layer_menu(), Button_Layer_merge(), Button_Layer_remove(), Button_Layer_set_transparent(), Button_Layer_up(), Button_Lines(), Button_Lines_switch_mode(), Button_Load_or_Save(), Button_Magnify(), Button_Magnify_menu(), Button_Page(), Button_Paintbrush_menu(), Button_Pal_left(), Button_Pal_left_fast(), Button_Pal_right(), Button_Pal_right_fast(), Button_Palette(), Button_Polyfill(), Button_Polyform(), Button_polygon(), Button_Quick_shade_menu(), Button_Quit(), Button_Quit_local_function(), Button_Redo(), Button_Reload(), Button_Replace(), Button_Resolution(), Button_Restore_brush(), Button_Safety_resolution(), Button_Secondary_palette(), Button_Select_backcolor(), Button_Select_forecolor(), Button_Settings(), Button_Show_grid(), Button_Sieve_menu(), Button_Skins(), Button_Smooth_menu(), Button_Snap_mode(), Button_Text(), Button_Tilemap_menu(), Button_Toggle_all_toolbars(), Button_Toggle_toolbar(), Button_Transform_menu(), Button_Undo(), Centered_lines_0_7(), Centered_lines_12_7(), Circle_12_5(), Close_popup(), Close_window(), Colorpicker_1_1(), Colorpicker_2_1(), Curve_34_points_1_5(), Curve_34_points_2_5(), Curve_3_points_0_5(), Curve_4_points_1_9(), Curve_4_points_2_9(), Curve_drag(), Curve_finalize(), Dialog_multiple_choice(), Distort_brush_1_0(), Distort_brush_1_9(), Draw_all_palette_sliders(), Dropdown_activate(), Ellipse_12_5(), Empty_rectangle_0_5(), Fill_1_0(), Fill_2_0(), Fill_general(), Filled_contour_0_8(), Filled_polyform_0_8(), Filled_polyform_12_8(), Filled_rectangle_0_5(), Freehand_mode1_1_2(), Freehand_mode1_2_2(), Freehand_mode2_1_2(), Freehand_mode2_2_2(), Get_color_behind_window(), Get_colors_from_brush(), Grad_circle_12_6(), Grad_circle_12_8(), Grad_ellipse_12_6(), Grad_ellipse_12_8(), Grad_rectangle_0_5(), Grad_rectangle_0_9(), Handle_mouse_btn_change(), Init_program(), Init_virtual_keyboard(), K_line_12_6(), K_line_12_7(), Layer_activate(), Line_12_5(), Load_image(), Load_picture(), Main_handler(), Menu_shade(), Menu_tag_colors(), Move_cursor_with_constraints(), Move_separator(), Move_window(), Open_window(), Pan_view_0_0(), Pan_view_0_2(), Polybrush_12_8(), Polyfill_12_8(), Polyfill_12_9(), Polyform_0_8(), Polyform_12_8(), Polygon_12_9(), Quicksearch_list(), Readline_ex_unicode(), Redefine_control(), Reduce_palette(), Replace_1_0(), Replace_2_0(), Resize_image(), Return_to_draw_mode(), Rightclick_colorpick(), Rightclick_colorpick_0_1(), Rotate_brush_0_5(), Save_MOTO_window(), Save_picture(), Scroll_help(), Scroll_list_of_modes(), Scroll_magnifier(), Scroll_screen(), Select_button(), Set_nice_menu_colors(), Smaller_paintbrush(), Special_next_backcolor(), Special_next_forecolor(), Special_next_user_backcolor(), Special_next_user_forecolor(), Special_previous_backcolor(), Special_previous_forecolor(), Special_previous_user_backcolor(), Special_previous_user_forecolor(), Stretch_brush_1_7(), Tilemap_update(), Update_color_count(), Wait_click_in_palette(), Wait_click_in_shade_table(), Window_clicked_button(), Window_dropdown_on_click(), Window_get_button_shortcut(), Window_get_clicked_button(), Window_help(), Window_Histogram(), Window_normal_button_onclick(), Window_set_shortcut(), Zoom(), and Zoom_set().

◆ Remap_screen_after_menu_colors_change()

◆ Compute_optimal_menu_colors()

◆ Position_screen_according_to_zoom()

◆ Compute_separator_data()

◆ Compute_magnifier_data()

◆ Clip_magnifier_offsets()

◆ Compute_limits()

◆ Compute_paintbrush_coordinates()

◆ Pixel_in_menu()

void Pixel_in_menu ( word  bar,
word  x,
word  y,
byte  color 
)

◆ Pixel_in_menu_and_skin()

void Pixel_in_menu_and_skin ( word  bar,
word  x,
word  y,
byte  color 
)

◆ Pixel_in_window()

◆ Set_fore_color()

◆ Set_back_color()

◆ Frame_menu_color()

◆ Display_menu_palette()

◆ Display_menu()

◆ Display_layerbar()

◆ Reposition_palette()

◆ Change_palette_cells()

◆ Pick_color_in_palette()

◆ Palette_cells_X()

word Palette_cells_X ( void  )

◆ Palette_cells_Y()

word Palette_cells_Y ( void  )

◆ Print_general()

◆ Print_general_unicode()

void Print_general_unicode ( short  x,
short  y,
const word str,
byte  text_color,
byte  background_color 
)

◆ Print_in_window_underscore()

void Print_in_window_underscore ( short  x,
short  y,
const char *  str,
byte  text_color,
byte  background_color,
byte  undersc_letter 
)

Draws a string in a window with underscore undersc_letter is 0 for no underscore, 1-indexed array index otherwise.

References Print_char_in_window(), Update_window_area, and Window_rectangle().

Referenced by Button_Airbrush_menu(), Button_Constraint_menu(), Button_Effects(), Button_Resolution(), Button_Text(), Button_Transform_menu(), and Print_in_window().

◆ Print_in_window()

void Print_in_window ( short  x,
short  y,
const char *  str,
byte  text_color,
byte  background_color 
)

Draws a string in a window.

References Print_in_window_underscore().

Referenced by Button_Airbrush_menu(), Button_Anim_time(), Button_Brush_FX(), Button_Colorize_display_selection(), Button_Colorize_menu(), Button_Constraint_menu(), Button_Effects(), Button_Gradients(), Button_Grid_menu(), Button_Layer_menu(), Button_Load_or_Save(), Button_Message_initial(), Button_Palette(), Button_Quick_shade_menu(), Button_Resolution(), Button_Secondary_palette(), Button_Sieve_menu(), Button_Skins(), Button_Stats(), Button_Text(), Button_Tilemap_menu(), Button_Tiling_menu(), Button_Transform_menu(), Confirmation_box(), Dialog_multiple_choice(), Display_bookmark(), Display_effect_state(), Display_feedback_state(), Display_file_list(), Display_modes_list(), Display_selected_cell_color(), Display_selected_color(), Display_shade_mode(), Draw_one_font_name(), Draw_one_skin_name(), Draw_transparent_background(), Draw_transparent_color(), Dropdown_activate(), Load_image(), Load_SCR(), Menu_shade(), Message_out_of_memory(), Pre_load(), Print_color_cycling_details(), Print_current_directory(), Print_in_window_limited(), Print_RGB_or_HSL(), Readline_ex_unicode(), Redefine_control(), Reduce_palette(), Refresh_airbrush_settings(), Requester_window(), Save_C64_window(), Save_image(), Save_MOTO_window(), Settings_display_config(), Tilemap_update(), Update_color_count(), Verbose_message(), Warning_message(), Window_draw_normal_bouton(), Window_draw_scroller_button(), Window_Histogram(), Window_set_dropdown_button(), and Window_set_shortcut().

◆ Print_in_window_unicode()

void Print_in_window_unicode ( short  x,
short  y,
const word str,
byte  text_color,
byte  background_color 
)

◆ Print_in_window_limited()

void Print_in_window_limited ( short  x,
short  y,
const char *  str,
byte  size,
byte  text_color,
byte  background_color 
)

◆ Print_in_window_limited_unicode()

void Print_in_window_limited_unicode ( short  x,
short  y,
const word str,
byte  size,
byte  text_color,
byte  background_color 
)

Draws a char in a window, checking for bounds.

References ELLIPSIS_CHARACTER, Print_in_window_unicode(), Unicode_strdup(), and Unicode_strlen().

Referenced by Display_bookmark().

◆ Print_char_in_window()

void Print_char_in_window ( short  x_pos,
short  y_pos,
unsigned int  c,
byte  text_color,
byte  background_color 
)

◆ Print_in_menu()

void Print_in_menu ( const char *  str,
short  position 
)

◆ Print_coordinates()

void Print_coordinates ( void  )

Draws the mouse coordinates on the menu Only update the digits and doesn't refresh the "X: Y:" labels.

This function needs to be fast as it is called each time the mouse moves.

References T_Document::backups, Colorpicker_color, Colorpicker_X, Colorpicker_Y, Current_operation, Cursor_in_menu, T_Page::Image, T_Document::image_height, T_Page::Image_mode, IMAGE_MODE_MODE5, IMAGE_MODE_RASTER, T_Document::image_width, Main, MC_Dark, Menu_factor_X, Menu_is_visible, Menu_status_Y, Num2str, OPERATION_COLORPICK, OPERATION_REPLACE, OPERATION_RMB_COLORPICK, T_List_of_pages::Pages, Paintbrush_X, Paintbrush_Y, T_Image::Pixels, Print_general(), Print_in_menu(), Read_pixel_from_current_screen(), and Update_status_line().

Referenced by Airbrush_12_2(), Brush_12_5(), Centered_lines_12_7(), Circle_12_5(), Colorpicker_1_1(), Colorpicker_2_1(), Curve_3_points_0_5(), Curve_4_points_0_5(), Curve_4_points_1_9(), Curve_drag(), Display_coords_rel_or_abs(), Display_menu(), Distort_brush_1_8(), Distort_brush_1_9(), Empty_circle_0_5(), Empty_ellipse_0_5(), Empty_rectangle_0_5(), Filled_circle_0_5(), Filled_contour_0_8(), Filled_ellipse_0_5(), Filled_polyform_0_8(), Filled_polyform_12_8(), Filled_rectangle_0_5(), Freehand_mode1_1_2(), Freehand_mode1_2_2(), Freehand_mode2_1_0(), Freehand_mode2_1_2(), Freehand_mode2_2_0(), Freehand_mode2_2_2(), Grad_circle_0_6(), Grad_circle_12_6(), Grad_circle_12_8(), Grad_ellipse_0_6(), Grad_ellipse_12_8(), Grad_rectangle_0_7(), Grad_rectangle_0_9(), Grad_rectangle_12_5(), Init_operations(), K_line_12_7(), Line_0_5(), Pan_view_0_0(), Pan_view_12_2(), Polybrush_12_8(), Polyfill_12_9(), Polyform_0_8(), Polyform_12_8(), Polygon_12_9(), Rectangle_12_5(), Return_to_draw_mode(), Rightclick_colorpick_0_1(), Rightclick_colorpick_2_1(), Rotate_brush_0_5(), Rotate_brush_1_5(), Scroll_0_5(), Stretch_brush_0_7(), and Stretch_brush_1_7().

◆ Print_filename()

◆ Print_counter()

void Print_counter ( short  x,
short  y,
const char *  str,
byte  text_color,
byte  background_color 
)

◆ Display_image_limits()

◆ Display_all_screen()

void Display_all_screen ( void  )

References T_Document::backups, Block, Config, T_Config::Display_image_limits, Display_image_limits(), Display_screen, Display_separator(), Display_zoomed_screen, Horizontal_line_buffer, T_Document::image_height, T_Document::image_width, T_Document::magnifier_factor, T_Document::magnifier_height, T_Document::magnifier_mode, T_Document::magnifier_offset_Y, T_Document::magnifier_width, Main, Menu_Y, T_List_of_pages::Pages, Screen_width, T_Document::separator_position, T_Page::Transparent_color, Update_rect(), and T_Document::X_zoom.

Referenced by Button_Clear(), Button_Clear_with_backcolor(), Button_Constraint_menu(), Button_Hide_menu(), Button_Kill(), Button_Layer_add(), Button_Layer_down(), Button_Layer_duplicate(), Button_Layer_menu(), Button_Layer_merge(), Button_Layer_remove(), Button_Layer_set_transparent(), Button_Layer_up(), Button_Magnify(), Button_Magnify_menu(), Button_Message_initial(), Button_Page(), Button_Redo(), Button_Reload(), Button_Resolution(), Button_Safety_resolution(), Button_Show_grid(), Button_Toggle_all_toolbars(), Button_Toggle_toolbar(), Button_Transform_menu(), Button_Undo(), Button_Unselect_magnifier(), Close_popup(), Close_window(), Distort_brush_1_9(), Distort_brush_2_0(), Distort_brush_2_8(), Filled_contour_0_8(), Filled_polyform_12_8(), Get_color_behind_window(), Get_colors_from_brush(), Init_program(), Layer_activate(), Load_picture(), Magnifier_12_0(), Main_handler(), Move_separator(), Polybrush_12_8(), Polyfill_12_9(), Process_backups(), Replace_1_0(), Replace_2_0(), Rotate_brush_0_5(), Rotate_brush_1_5(), Rotate_brush_2_5(), Scroll_12_5(), Scroll_magnifier(), Scroll_screen(), Set_bar_visibility(), Stretch_brush_0_7(), Stretch_brush_1_7(), Stretch_brush_2_7(), Zoom(), and Zoom_set().

◆ Window_rectangle()

◆ Window_display_frame_generic()

void Window_display_frame_generic ( word  x_pos,
word  y_pos,
word  width,
word  height,
byte  color_tl,
byte  color_br,
byte  color_s,
byte  color_tlc,
byte  color_brc 
)

◆ Window_display_frame_mono()

void Window_display_frame_mono ( word  x_pos,
word  y_pos,
word  width,
word  height,
byte  color 
)

◆ Window_display_frame_in()

◆ Window_display_frame_out()

◆ Window_display_frame()

◆ Display_sprite_in_menu()

◆ Display_paintbrush_in_menu()

◆ Display_paintbrush_in_window()

void Display_paintbrush_in_window ( word  x,
word  y,
int  number 
)

◆ Draw_thingumajig()

void Draw_thingumajig ( word  x,
word  y,
byte  color,
short  direction 
)

References Pixel_in_window().

Referenced by Button_Palette().

◆ Display_grad_block_in_window()

void Display_grad_block_in_window ( word  x_pos,
word  y_pos,
word  width,
word  height,
word  block_start,
word  block_end 
)

◆ Window_display_icon_sprite()

◆ Best_color()

◆ Best_color_nonexcluded()

byte Best_color_nonexcluded ( byte  red,
byte  green,
byte  blue 
)

References Main, and T_Document::palette.

Referenced by Set_nice_menu_colors().

◆ Best_color_range()

byte Best_color_range ( byte  red,
byte  green,
byte  blue,
byte  max 
)

References Exclude_color, Main, and T_Document::palette.

Referenced by Init_program().

◆ Best_color_perceptual()

byte Best_color_perceptual ( byte  r,
byte  g,
byte  b 
)

References Exclude_color, Main, and T_Document::palette.

Referenced by Remap_spare().

◆ Best_color_perceptual_except()

byte Best_color_perceptual_except ( byte  r,
byte  g,
byte  b,
byte  except 
)

◆ Horizontal_XOR_line_zoom()

void Horizontal_XOR_line_zoom ( short  x_pos,
short  y_pos,
short  width 
)

◆ Vertical_XOR_line_zoom()

void Vertical_XOR_line_zoom ( short  x_pos,
short  y_pos,
short  height 
)

◆ Change_magnifier_factor()

◆ Copy_view_to_spare()

Variable Documentation

◆ Layer_button_width

word Layer_button_width
extern

Width of one layer button, in pixels before scaling.

Referenced by Display_layerbar(), Layer_preview_on(), and Layer_under_mouse().

◆ Buttons_Pool

◆ Menu_bars