PreviousUpNext

15.4.1436  src/lib/x-kit/widget/edit/textpane-types.pkg

## textpane-types.pkg
#
# Here we define types which
#
#     src/lib/x-kit/widget/edit/textpane.pkg
#
# exports to other packages like
#
#     src/lib/x-kit/widget/edit/screenline.pkg

# Compiled by:
#     src/lib/x-kit/widget/xkit-widget.sublib



stipulate
    include package   threadkit;                                                                        # threadkit                     is from   src/lib/src/lib/thread-kit/src/core-thread-kit/threadkit.pkg
    #
    package g2d =  geometry2d;                                                                          # geometry2d                    is from   src/lib/std/2d/geometry2d.pkg
    package nl  =  red_black_numbered_list;                                                             # red_black_numbered_list       is from   src/lib/src/red-black-numbered-list.pkg
    package wit =  widget_imp_types;                                                                    # widget_imp_types              is from   src/lib/x-kit/widget/xkit/theme/widget/default/look/widget-imp-types.pkg
    package gt  =  guiboss_types;                                                                       # guiboss_types                 is from   src/lib/x-kit/widget/gui/guiboss-types.pkg
    package evt =  gui_event_types;                                                                     # gui_event_types               is from   src/lib/x-kit/widget/gui/gui-event-types.pkg
    package g2d =  geometry2d;                                                                          # geometry2d                    is from   src/lib/std/2d/geometry2d.pkg
    package wt  =  widget_theme;                                                                        # widget_theme                  is from   src/lib/x-kit/widget/theme/widget/widget-theme.pkg
herein

    # This port is implemented in:
    #
    #     src/lib/x-kit/widget/edit/textpane.pkg
    #
    package textpane_types {
        #
        Key_Event_Fn_Arg                                                                                # This type is intended to be identical to wit::Key_Event_Fn_Arg except for lacking the 'to' + 'do' fields.  Unfortunately the language doesn't allow us to say that directly, at present.
          =
          {
            id:                                 Id,                                                     # Unique id.
            doc:                                String,                                                 # Human-readable description of this widget, for debug and inspection.
            key_event:                          gt::Key_Event,                                          # KEY_PRESS or KEY_RELEASE
            keycode:                            evt::Keycode,                                           # Keycode of the depressed key. (Is this of any conceivable use?)
            keysym:                             evt::Keysym,                                            # Keysym  of the depressed key.  See Note[1].  See Note[1] in src/lib/x-kit/widget/xkit/theme/widget/default/look/widget-imp.api
            keystring:                          String,                                                 # Ascii  for the depressed key.  See Note[1].  See Note[1] in src/lib/x-kit/widget/xkit/theme/widget/default/look/widget-imp.api
            keychar:                            Char,                                                   # First char of 'string' ('\0' if string-length != 1).
            widget_layout_hint:                 gt::Widget_Layout_Hint,
            frame_indent_hint:                  gt::Frame_Indent_Hint,
            site:                               g2d::Box,                                               # Widget's assigned area in window coordinates.
            modifier_keys_state:                evt::Modifier_Keys_State,                               # State of the modifier keys (shift, ctrl...).
            mousebuttons_state:                 evt::Mousebuttons_State,                                # State of mouse buttons as a bool record.
            widget_to_guiboss:                  gt::Widget_To_Guiboss,
            theme:                              wt::Widget_Theme
          };
        Key_Event_Fn = Key_Event_Fn_Arg -> Void;                                                        # 

        Mouse_Click_Fn_Arg                                                                              # This type is intended to be identical to wit::Mouse_Click_Fn_Arg except for lacking the 'to' + 'do' fields.  Unfortunately the language doesn't allow us to say that directly, at present.
          =
          {
            id:                                 Id,                                                     # Unique id.
            doc:                                String,                                                 # Human-readable description of this widget, for debug and inspection.
            event:                              gt::Mousebutton_Event,                                  # MOUSEBUTTON_PRESS or MOUSEBUTTON_RELEASE.
            button:                             evt::Mousebutton,
            point:                              g2d::Point,
            widget_layout_hint:                 gt::Widget_Layout_Hint,
            frame_indent_hint:                  gt::Frame_Indent_Hint,
            site:                               g2d::Box,                                               # Widget's assigned area in window coordinates.
            modifier_keys_state:                evt::Modifier_Keys_State,                               # State of the modifier keys (shift, ctrl...).
            mousebuttons_state:                 evt::Mousebuttons_State,                                # State of mouse buttons as a bool record.
            widget_to_guiboss:                  gt::Widget_To_Guiboss,
            theme:                              wt::Widget_Theme
          };
        Mouse_Click_Fn = Mouse_Click_Fn_Arg -> Void;

    };
end;




Comments and suggestions to: bugs@mythryl.org

PreviousUpNext