(* Tags for GTK *)

package "gtk"

(* gtkenums.h *)

type align = "GTK_ALIGN_"
  [ `FILL | `START | `END | `CENTER | `BASELINE ]

type arrow_type = "GTK_ARROW_"
  [ `UP | `DOWN | `LEFT | `RIGHT | `NONE ]

type attach_options = "GTK_"
  [ `EXPAND | `SHRINK | `FILL ]

type baseline_position = "GTK_BASELINE_POSITION_"
  [ `TOP | `CENTER | `BOTTOM ]

type delete_type = "GTK_DELETE_"
  [ `CHARS | `WORD_ENDS | `WORDS
  | `DISPLAY_LINES | `DISPLAY_LINE_ENDS
  | `PARAGRAPH_ENDS | `PARAGRAPHS
  | `WHITESPACE ]

type direction_type = "GTK_DIR_"
  [ `TAB_FORWARD | `TAB_BACKWARD | `UP | `DOWN | `LEFT | `RIGHT ]

type icon_size = "GTK_ICON_SIZE_"
  [ `INVALID | `MENU | `SMALL_TOOLBAR | `LARGE_TOOLBAR
  | `BUTTON | `DND | `DIALOG ]

type sensitivity_type = "GTK_SENSITIVITY_"
  [ `AUTO | `ON | `OFF ]

type text_direction = "GTK_TEXT_DIR_"
  [ `NONE | `LTR | `RTL ]

type justification = "GTK_JUSTIFY_"
  [ `LEFT | `RIGHT | `CENTER | `FILL ]

type menu_direction_type = "GTK_MENU_DIR_"
  [ `PARENT | `CHILD | `NEXT | `PREV ]

type message_type = "GTK_MESSAGE_"
  [ `INFO | `WARNING | `QUESTION | `ERROR | `OTHER ]

(* type metric_type = "GTK_"
  [ `PIXELS | `INCHES | `CENTIMETERS ] *)

type movement_step = "GTK_MOVEMENT_"
  [ `LOGICAL_POSITIONS | `VISUAL_POSITIONS | `WORDS
  | `DISPLAY_LINES | `DISPLAY_LINE_ENDS | `PARAGRAPH_ENDS | `PARAGRAPHS
  | `PAGES | `BUFFER_ENDS | `HORIZONTAL_PAGES ]

type orientation = "GTK_ORIENTATION_"
  [ `HORIZONTAL | `VERTICAL ]

type pack_type = "GTK_PACK_"
  [ `START | `END ]

(*
type path_priority = "GTK_PATH_PRIO_"
  [ `LOWEST | `GTK | `APPLICATION | `THEME | `RC | `HIGHEST ]

type path_type = "GTK_PATH_"
  [ `WIDGET | `WIDGET_CLASS | `CLASS ]

type policy_type = "GTK_POLICY_"
  [ `ALWAYS | `AUTOMATIC | `NEVER ]
*)

type position_type = "GTK_POS_"
  [ `LEFT | `RIGHT | `TOP | `BOTTOM ]

(*
type preview_type = "GTK_PREVIEW_"
  [ `COLOR | `GRAYSCALE ]
*)

type relief_style = "GTK_RELIEF_"
  [ `NORMAL | `HALF | `NONE ]

(*
type resize_mode = "GTK_RESIZE_"
  [ `PARENT | `QUEUE | `IMMEDIATE ]

type signal_run_type = "GTK_RUN_"
  [ `FIRST | `LAST | `BOTH | `NO_RECURSE | `ACTION | `NO_HOOKS ]
*)

type scroll_step = "GTK_SCROLL_"
  [ `STEPS | `PAGES | `END
  | `HORIZONTAL_STEPS | `HORIZONTAL_PAGES | `HORIZONTAL_ENDS ]

type scroll_type = "GTK_SCROLL_"
  [ `NONE | `JUMP | `STEP_FORWARD | `STEP_BACKWARD
  | `PAGE_BACKWARD | `PAGE_FORWARD | `STEP_UP | `STEP_DOWN
  | `PAGE_UP | `PAGE_DOWN | `STEP_LEFT | `STEP_RIGHT
  | `PAGE_LEFT | `PAGE_RIGHT | `START | `END ]

type selection_mode = "GTK_SELECTION_"
  [ `NONE | `SINGLE | `BROWSE | `MULTIPLE ]

type shadow_type = "GTK_SHADOW_"
  [ `NONE | `IN | `OUT | `ETCHED_IN | `ETCHED_OUT ]

type state_type = "GTK_STATE_"
  [ `NORMAL | `ACTIVE | `PRELIGHT | `SELECTED | `INSENSITIVE
  | `INCONSISTENT | `FOCUSED ] 

(*
type submenu_direction = "GTK_DIRECTION_"
  [ `LEFT | `RIGHT ]

type submenu_placement = "GTK_"
  [ `TOP_BOTTOM | `LEFT_RIGHT ]
*)
type toolbar_style = "GTK_TOOLBAR_"
  [ `ICONS | `TEXT | `BOTH | `BOTH_HORIZ ]

(*
type update_type = "GTK_UPDATE_"
  [ `CONTINUOUS | `DISCONTINUOUS | `DELAYED ]

type visibility = "GTK_VISIBILITY_"
  [ `NONE | `PARTIAL | `FULL ]
*)

type wrap_mode = "GTK_WRAP_"
  [ `NONE | `CHAR | `WORD | `WORD_CHAR ]

type sort_type = "GTK_SORT_"
  [ `ASCENDING | `DESCENDING ]

type pack_direction = "GTK_PACK_DIRECTION_"
  [ `LTR | `RTL | `TTB | `BTT ]

type print_pages = "GTK_PRINT_PAGES_"
  [ `ALL | `CURRENT | `RANGES | `SELECTION ]

type page_set = "GTK_PAGE_SET_"
  [ `ALL | `EVEN | `ODD ]

type number_up_layout = "GTK_NUMBER_UP_LAYOUT_"
  [ `LEFT_TO_RIGHT_TOP_TO_BOTTOM
  | `LEFT_TO_RIGHT_BOTTOM_TO_TOP
  | `RIGHT_TO_LEFT_TOP_TO_BOTTOM
  | `RIGHT_TO_LEFT_BOTTOM_TO_TOP
  | `TOP_TO_BOTTOM_LEFT_TO_RIGHT
  | `TOP_TO_BOTTOM_RIGHT_TO_LEFT
  | `BOTTOM_TO_TOP_LEFT_TO_RIGHT
  | `BOTTOM_TO_TOP_RIGHT_TO_LEFT ]

type page_orientation = "GTK_PAGE_ORIENTATION_"
  [ `PORTRAIT | `LANDSCAPE | `REVERSE_PORTRAIT | `REVERSE_LANDSCAPE ]

type print_quality = "GTK_PRINT_QUALITY_"
  [ `LOW | `NORMAL | `HIGH | `DRAFT ]

type print_duplex = "GTK_PRINT_DUPLEX_"
  [ `SIMPLEX | `HORIZONTAL | `VERTICAL ]

type gtk_unit = "GTK_UNIT_"
  [ `NONE | `POINTS | `INCH | `MM | `PIXEL ]

type tree_view_grid_lines = "GTK_TREE_VIEW_GRID_LINES_"
  [ `NONE | `HORIZONTAL | `VERTICAL | `BOTH ]

type drag_result = "GTK_DRAG_RESULT_"
  [ `SUCCESS | `NO_TARGET | `USER_CANCELLED | `TIMEOUT_EXPIRED
  | `GRAB_BROKEN | `ERROR ]

type size_group_mode = "GTK_SIZE_GROUP_"
  [ `NONE | `HORIZONTAL | `VERTICAL | `BOTH ]

type size_request_mode = "GTK_SIZE_REQUEST_"
  [ `HEIGHT_FOR_WIDTH | `WIDTH_FOR_HEIGHT | `CONSTANT_SIZE ]

type scrollable_policy = "GTK_SCROLL_"
  [ `MINIMUM | `NATURAL ]

type flags state_flag = "GTK_STATE_FLAG_"
  [ `NORMAL | `ACTIVE | `PRELIGHT | `SELECTED | `INSENSITIVE | `INCONSISTENT
  | `FOCUSED | `BACKDROP | `DIR_LTR | `DIR_RTL | `LINK | `VISITED | `CHECKED
  (* 3.20 | `DROP_ACTIVE *) ]

type flags region_flag = "GTK_REGION_"
  [ `EVEN | `ODD | `FIRST | `LAST | `ONLY | `SORTED ]

type junction_sides = "GTK_JUNCTION_"
  [ `NONE | `CORNER_TOPLEFT | `CORNER_TOPRIGHT | `CORNER_BOTTOMLEFT
  | `CORNER_BOTTOMRIGHT | `TOP | `BOTTOM | `LEFT | `RIGHT ]

type border_style = "GTK_BORDER_STYLE_"
  [ `NONE | `SOLID | `INSET | `OUTSET | `HIDDEN
  | `DOTTED | `DASHED | `DOUBLE | `GROOVE | `RIDGE ]

type level_bar_mode = "GTK_LEVEL_BAR_MODE_"
  [ `CONTINUOUS | `DISCRETE ]

type input_purpose = "GTK_INPUT_PURPOSE_"
  [ `FREE_FORM | `ALPHA | `DIGITS | `NUMBER
  | `PHONE | `URL | `EMAIL | `NAME | `PASSWORD | `PIN ]

type input_hints = "GTK_INPUT_HINT_"
  [ `NONE | `SPELLCHECK | `NO_SPELLCHECK | `WORD_COMPLETION
  | `LOWERCASE | `UPPERCASE_CHARS | `UPPERCASE_WORDS | `UPPERCASE_SENTENCES
  | `INHIBIT_OSK
  (* >= 3.18 | `VERTICAL_WRITING *)
  (* >= 3.22 | `EMOJI | `NO_EMOJI *) ]

type propagation_phase = "GTK_PHASE_"
  [ `NONE | `CAPTURE | `BUBBLE | `TARGET ]

type event_sequence_state = "GTK_EVENT_SEQUENCE_"
  [ `NONE | `CLAIMED | `DENIED ]

type pan_direction = "GTK_PAN_DIRECTION_"
  [ `LEFT | `RIGHT | `UP | `DOWN ]

type stack_transition_type = "GTK_STACK_TRANSITION_TYPE_"
  [ `NONE | `CROSSFADE | `SLIDE_RIGHT | `SLIDE_LEFT 
  | `SLIDE_UP | `SLIDE_DOWN | `SLIDE_LEFT_RIGHT | `SLIDE_UP_DOWN
  | `OVER_UP | `OVER_DOWN | `OVER_LEFT | `OVER_RIGHT
  | `UNDER_UP | `UNDER_DOWN | `UNDER_LEFT | `UNDER_RIGHT
  | `OVER_UP_DOWN | `OVER_DOWN_UP | `OVER_LEFT_RIGHT | `OVER_RIGHT_LEFT ]

(* >= 3.20
type popover_constraint = "GTK_POPOVER_CONSTRAINT_"
  [ `NONE | `WINDOW ] *)

(* gtktextview.h *)
type text_window_type = "GTK_TEXT_WINDOW_"
  [ `PRIVATE | `WIDGET | `TEXT | `LEFT 
  | `RIGHT | `TOP | `BOTTOM ]

type text_view_layer = "GTK_TEXT_VIEW_LAYER_"
  [ `BELOW | `ABOVE (* Since 3.20: | `BELOW_TEXT | `ABOVE_TEXT *) ]

type text_extend_selection = "GTK_TEXT_EXTEND_SELECTION_"
  [ `WORD | `LINE ]

(* gtktextiter.h *)
type text_search_flag = "GTK_TEXT_SEARCH_"
  [ `VISIBLE_ONLY | `TEXT_ONLY | `CASE_INSENSITIVE ]

(* gtktoolbar.h *)
type toolbar_space_style = "GTK_TOOLBAR_SPACE_"
  [ `EMPTY | `LINE ]

(* gtkspinbutton.h *)
type spin_button_update_policy = "GTK_UPDATE_"
  [ `ALWAYS | `IF_VALID ]

type spin_type = "GTK_SPIN_"
  [ `STEP_FORWARD | `STEP_BACKWARD | `PAGE_FORWARD | `PAGE_BACKWARD
  | `HOME | `END | `USER_DEFINED ]

(* gtkaccelgroup.h *)
type accel_flag = "GTK_ACCEL_"
  [ `VISIBLE | `LOCKED ]

(* gtkbbox.h *)
type button_box_style = "GTK_BUTTONBOX_"
  [ `SPREAD | `EDGE | `START | `END | `CENTER | `EXPAND ]

(* gtkcalendar.h *)
type calendar_display_options = "GTK_CALENDAR_"
  [ `SHOW_HEADING | `SHOW_DAY_NAMES | `NO_MONTH_CHANGE | `SHOW_WEEK_NUMBERS
  | `SHOW_DETAILS ]

(* gtkcontainer.h *)
type resize_mode = "GTK_RESIZE_"
  [ `PARENT | `QUEUE | `IMMEDIATE ]

(* gtkdragdest.h *)
type dest_defaults = "GTK_DEST_DEFAULT_"
  [ `MOTION | `HIGHLIGHT | `DROP | `ALL ]

(* gtkselection.h *)
type target_flags = "GTK_TARGET_"
  [ `SAME_APP | `SAME_WIDGET | `OTHER_APP | `OTHER_WIDGET ]

(* gtkscrolledwindow.h *)
type corner_type = "GTK_CORNER_"
  [ `TOP_LEFT | `BOTTOM_LEFT | `TOP_RIGHT | `BOTTOM_RIGHT ]

type policy_type = "GTK_POLICY_"
  [ `ALWAYS | `AUTOMATIC | `NEVER | `EXTERNAL ]

(* gtktreemodel.h *)
type tree_model_flags = "GTK_TREE_MODEL_"
  [ `ITERS_PERSIST | `LIST_ONLY ]

(* gtktreeview.h *)
type tree_view_drop_position = "GTK_TREE_VIEW_DROP_"
  [ `BEFORE | `AFTER | `INTO_OR_BEFORE | `INTO_OR_AFTER ]

(* gtktreeviewcolumn.h *)
type tree_view_column_sizing = "GTK_TREE_VIEW_COLUMN_"
  [ `GROW_ONLY | `AUTOSIZE | `FIXED ]

(* gtkcellrenderer.h *)
type cell_renderer_state = "GTK_CELL_RENDERER_"
  [ `SELECTED | `PRELIT | `INSENSITIVE | `SORTED | `FOCUSED
  | `EXPANDABLE | `EXPANDED ]

type cell_renderer_mode = "GTK_CELL_RENDERER_MODE_"
  [ `INERT | `ACTIVATABLE | `EDITABLE ]

(* gtkcellrendereraccel.h *)
type cell_renderer_accel_mode = "GTK_CELL_RENDERER_ACCEL_MODE_"
  [ `GTK | `OTHER ]

(* gtkmessagedialog.h *)
type buttons_type = "GTK_BUTTONS_"
  [ `NONE | `OK | `CLOSE
  | `CANCEL | `YES_NO | `OK_CANCEL ]

(* gtkdialog.h *)
type dialog_flag = "GTK_DIALOG_"
  [ `MODAL | `DESTROY_WITH_PARENT | `USE_HEADER_BAR ]

type response = "GTK_RESPONSE_"
  [ `NONE | `REJECT | `ACCEPT | `DELETE_EVENT
  | `OK | `CANCEL | `CLOSE  | `YES | `NO | `APPLY | `HELP ]

(* gtkwidget.h *)
type widget_help_type = "GTK_WIDGET_HELP_"
  [ `TOOLTIP | `WHATS_THIS ]

(* gtkwindow.h *)
type window_position = "GTK_WIN_POS_"
  [ `NONE | `CENTER | `MOUSE | `CENTER_ALWAYS | `CENTER_ON_PARENT ]

type window_type = "GTK_WINDOW_"
  [ `TOPLEVEL | `POPUP ]

(* gtkimage.h *)
type image_type = "GTK_IMAGE_"
  [ `EMPTY | `PIXBUF | `STOCK | `ICON_SET | `ANIMATION
  | `ICON_NAME | `GICON | `SURFACE ]

(* gtkfilechooser.h *)
type file_chooser_action = "GTK_FILE_CHOOSER_ACTION_"
  [ `OPEN | `SAVE | `SELECT_FOLDER | `CREATE_FOLDER ]

type file_chooser_confirmation = "GTK_FILE_CHOOSER_CONFIRMATION_"
  [ `CONFIRM | `ACCEPT_FILENAME | `SELECT_AGAIN ]

type file_chooser_errot = "GTK_FILE_CHOOSER_ERROR_"
  [ `NONEXISTENT | `BAD_FILENAME | `ALREADY_EXISTS | `INCOMPLETE_HOSTNAME ]

(* gtkfilefilter.h *)
type file_filter_flags = "GTK_FILE_FILTER_"
  [ `FILENAME | `URI | `DISPLAY_NAME | `MIME_TYPE ]

(* gtkuimanager.h *)
type protect HASGTK24 ui_manager_item_type = "GTK_UI_MANAGER_"
  [ `AUTO | `MENUBAR | `MENU | `TOOLBAR | `PLACEHOLDER
  | `POPUP | `MENUITEM | `TOOLITEM | `SEPARATOR | `ACCELERATOR
  | `POPUP_WITH_ACCELS ]

(* gtkassistant.h *)
type protect HASGTK210 assistant_page_type = "GTK_ASSISTANT_PAGE_"
  [ `CONTENT | `INTRO | `CONFIRM | `SUMMARY | `PROGRESS | `CUSTOM ]

(* gtkentry.h *)
type entry_icon_position = "GTK_ENTRY_ICON_"
  [ `PRIMARY | `SECONDARY ]
