Go to the first, previous, next, last section, table of contents.


The Tk module

val openTk : unit -> Widget.widget

val openTkClass : string -> Widget.widget

val openTkDisplayClass : string -> string -> Widget.widget

val closeTk : unit -> unit

val mainLoop : unit -> unit

val register : string -> (Protocol.callback_buffer -> unit) -> unit
type xEvent =
    ButtonPress
  | ButtonPressDetail of int
  | ButtonRelease
  | ButtonReleaseDetail of int
  | Circulate
  | ColorMap
  | Configure
  | Destroy
  | Enter
  | Expose
  | FocusIn
  | FocusOut
  | Gravity
  | KeyPress
  | KeyPressDetail of string
  | KeyRelease
  | KeyReleaseDetail of string
  | Leave
  | Map
  | Motion
  | Property
  | Reparent
  | Unmap
  | Visibility

val cCAMLtoTKxEvent : xEvent -> string
type modifier =
    Control
  | Shift
  | Lock
  | Button1
  | Button2
  | Button3
  | Button4
  | Button5
  | Double
  | Triple
  | Mod1
  | Mod2
  | Mod3
  | Mod4
  | Mod5
  | Meta
  | Alt

val cCAMLtoTKmodifier : modifier -> string

val cCAMLtoTKevent : modifier list * xEvent -> string

val cCAMLtoTKeventSequence : (modifier list * xEvent) list -> Protocol.tkArgs
type eventInfo = {
  mutable ev_Above : int;
  mutable ev_ButtonNumber : int;
  mutable ev_Count : int;
  mutable ev_Detail : string;
  mutable ev_Focus : bool;
  mutable ev_Height : int;
  mutable ev_KeyCode : int;
  mutable ev_Mode : string;
  mutable ev_OverrideRedirect : bool;
  mutable ev_Place : string;
  mutable ev_State : string;
  mutable ev_Time : int;
  mutable ev_Width : int;
  mutable ev_MouseX : int;
  mutable ev_MouseY : int;
  mutable ev_Char : string;
  mutable ev_BorderWidth : int;
  mutable ev_SendEvent : bool;
  mutable ev_KeySymString : string;
  mutable ev_KeySymInt : int;
  mutable ev_RootWindow : int;
  mutable ev_SubWindow : int;
  mutable ev_Type : int;
  mutable ev_Widget : Widget.widget;
  mutable ev_RootX : int;
  mutable ev_RootY : int;
} 
and eventField =
    Ev_Above
  | Ev_ButtonNumber
  | Ev_Count
  | Ev_Detail
  | Ev_Focus
  | Ev_Height
  | Ev_KeyCode
  | Ev_Mode
  | Ev_OverrideRedirect
  | Ev_Place
  | Ev_State
  | Ev_Time
  | Ev_Width
  | Ev_MouseX
  | Ev_MouseY
  | Ev_Char
  | Ev_BorderWidth
  | Ev_SendEvent
  | Ev_KeySymString
  | Ev_KeySymInt
  | Ev_RootWindow
  | Ev_SubWindow
  | Ev_Type
  | Ev_Widget
  | Ev_RootX
  | Ev_RootY

val filleventInfo : eventInfo -> string -> eventField -> unit

val wrapeventInfo : (eventInfo -> 'a) -> eventField list -> string list -> 'a

val writeeventField : eventField list -> string
type bindAction =
    BindSet of eventField list * (eventInfo -> unit)
  | BindSetBreakable of eventField list * (eventInfo -> unit)
  | BindRemove
  | BindExtend of eventField list * (eventInfo -> unit)

val bind :
  Widget.widget -> (modifier list * xEvent) list -> bindAction -> unit

val class_bind :
  string -> (modifier list * xEvent) list -> bindAction -> unit

val tag_bind : string -> (modifier list * xEvent) list -> bindAction -> unit

val break : unit -> unit
type bindings = TagBindings of string | WidgetBindings of Widget.widget

val cCAMLtoTKbindings : bindings -> Protocol.tkArgs

val cTKtoCAMLbindings : string -> bindings
type bitmap = BitmapFile of string | Predefined of string

val cCAMLtoTKbitmap : bitmap -> Protocol.tkArgs

val cTKtoCAMLbitmap : string -> bitmap
type color =
    NamedColor of string
  | Black
  | White
  | Red
  | Green
  | Blue
  | Yellow

val cCAMLtoTKcolor : color -> Protocol.tkArgs

val cTKtoCAMLcolor : string -> color
type cursor =
    XCursor of string
  | XCursorFg of string * color
  | XCursortFgBg of string * color * color
  | CursorFileFg of string * color
  | CursorMaskFile of string * string * color * color

val cCAMLtoTKcursor : cursor -> Protocol.tkArgs
type units =
    Pixels of int
  | Centimeters of float
  | Inches of float
  | Millimeters of float
  | PrinterPoint of float

val cCAMLtoTKunits : units -> Protocol.tkArgs

val cTKtoCAMLunits : string -> units
type index =
    Number of int
  | ActiveElement
  | End
  | Last
  | NoIndex
  | Insert
  | SelFirst
  | SelLast
  | At of int
  | AtXY of int * int
  | AnchorPoint
  | Pattern of string
  | LineChar of int * int
  | Mark of string
  | TagFirst of string
  | TagLast of string
  | Embedded of Widget.widget
and index_constrs =
    CNumber
  | CActiveElement
  | CEnd
  | CLast
  | CNoIndex
  | CInsert
  | CSelFirst
  | CSelLast
  | CAt
  | CAtXY
  | CAnchorPoint
  | CPattern
  | CLineChar
  | CMark
  | CTagFirst
  | CTagLast
  | CEmbedded

val index_any_table : index_constrs list

val index_canvas_table : index_constrs list

val index_entry_table : index_constrs list

val index_listbox_table : index_constrs list

val index_menu_table : index_constrs list

val index_text_table : index_constrs list

val cCAMLtoTKindex : index_constrs list -> index -> Protocol.tkArgs

val char_index : char -> string -> int

val cTKtoCAMLindex : string -> index
type paletteType = GrayShades of int | RGBShades of int * int * int

val cCAMLtoTKpaletteType : paletteType -> Protocol.tkArgs
type scrollValue = ScrollPage of int | ScrollUnit of int | MoveTo of float

val cCAMLtoTKscrollValue : scrollValue -> Protocol.tkArgs

val cTKtoCAMLscrollValue : string list -> scrollValue * string list
type textMark = string

val cCAMLtoTKtextMark : string -> Protocol.tkArgs

val cTKtoCAMLtextMark : 'a -> 'a
type textTag = string

val cCAMLtoTKtextTag : string -> Protocol.tkArgs

val cTKtoCAMLtextTag : 'a -> 'a
type textModifier =
    CharOffset of int
  | LineOffset of int
  | LineStart
  | LineEnd
  | WordStart
  | WordEnd

val ppTextModifier : textModifier -> string
type textIndex = TextIndex of index * textModifier list | TextIndexNone

val ppTextIndex : textIndex -> string

val cCAMLtoTKtextIndex : textIndex -> Protocol.tkArgs
type anchor = Center | E | N | NE | NW | S | SE | SW | W

val cCAMLtoTKanchor : anchor -> Protocol.tkArgs
type imageBitmap = BitmapImage of string

val cCAMLtoTKimageBitmap : imageBitmap -> Protocol.tkArgs

val cTKtoCAMLimageBitmap : string -> imageBitmap
type imagePhoto = PhotoImage of string

val cCAMLtoTKimagePhoto : imagePhoto -> Protocol.tkArgs

val cTKtoCAMLimagePhoto : string -> imagePhoto
type justification = Justify_Center | Justify_Left | Justify_Right

val cCAMLtoTKjustification : justification -> Protocol.tkArgs
type orientation = Horizontal | Vertical

val cCAMLtoTKorientation : orientation -> Protocol.tkArgs
type relief = Flat | Groove | Raised | Ridge | Sunken

val cCAMLtoTKrelief : relief -> Protocol.tkArgs
type state = Active | Disabled | Normal

val cCAMLtoTKstate : state -> Protocol.tkArgs
type colorMode = Color | Gray | Mono

val cCAMLtoTKcolorMode : colorMode -> Protocol.tkArgs
type arcStyle = Arc | Chord | PieSlice

val cCAMLtoTKarcStyle : arcStyle -> Protocol.tkArgs
type tagOrId = Id of int | Tag of string

val cCAMLtoTKtagOrId : tagOrId -> Protocol.tkArgs

val cTKtoCAMLtagOrId : string -> tagOrId
type arrowStyle = Arrow_Both | Arrow_First | Arrow_Last | Arrow_None

val cCAMLtoTKarrowStyle : arrowStyle -> Protocol.tkArgs
type capStyle = Cap_Butt | Cap_Projecting | Cap_Round

val cCAMLtoTKcapStyle : capStyle -> Protocol.tkArgs
type joinStyle = Join_Bevel | Join_Miter | Join_Round

val cCAMLtoTKjoinStyle : joinStyle -> Protocol.tkArgs
type visual =
    Best
  | BestDepth of int
  | ClassVisual of string * int
  | DefaultVisual
  | WidgetVisual of Widget.widget

val cCAMLtoTKvisual : visual -> Protocol.tkArgs
type colormap = NewColormap | WidgetColormap of Widget.widget

val cCAMLtoTKcolormap : colormap -> Protocol.tkArgs
type selectModeType = Browse | Extended | Multiple | Single

val cCAMLtoTKselectModeType : selectModeType -> Protocol.tkArgs
type fillMode = Fill_Both | Fill_None | Fill_X | Fill_Y

val cCAMLtoTKfillMode : fillMode -> Protocol.tkArgs
type side = Side_Bottom | Side_Left | Side_Right | Side_Top

val cCAMLtoTKside : side -> Protocol.tkArgs
type borderMode = Ignore | Inside | Outside

val cCAMLtoTKborderMode : borderMode -> Protocol.tkArgs
type alignType = Align_Baseline | Align_Bottom | Align_Center | Align_Top

val cCAMLtoTKalignType : alignType -> Protocol.tkArgs
type wrapMode = WrapChar | WrapNone | WrapWord

val cCAMLtoTKwrapMode : wrapMode -> Protocol.tkArgs
type tabType =
    TabCenter of units
  | TabLeft of units
  | TabNumeric of units
  | TabRight of units

val cCAMLtoTKtabType : tabType -> Protocol.tkArgs
type options =
    Accelerator of string
  | ActiveBackground of color
  | ActiveBorderWidth of units
  | ActiveForeground of color
  | ActiveRelief of relief
  | After of Widget.widget
  | Align of alignType
  | Anchor of anchor
  | ArcStyle of arcStyle
  | ArrowShape of units * units * units
  | ArrowStyle of arrowStyle
  | Aspect of int
  | Background of color
  | Before of Widget.widget
  | BgStipple of bitmap
  | BigIncrement of float
  | Bitmap of bitmap
  | BorderMode of borderMode
  | BorderWidth of units
  | CapStyle of capStyle
  | Class of string
  | CloseEnough of float
  | Colormap of colormap
  | Colormode of colorMode
  | Column of int
  | ColumnSpan of int
  | Command of (unit -> unit)
  | Confine of bool
  | Cursor of cursor
  | Data of string
  | Digits of int
  | DisabledForeground of color
  | ElementBorderWidth of units
  | Expand of bool
  | ExportSelection of bool
  | Extent of float
  | FgStipple of bitmap
  | File of string
  | Fill of fillMode
  | FillColor of color
  | Font of string
  | Foreground of color
  | Format of string
  | From of float
  | Gamma of float
  | Geometry of string
  | Height of units
  | HighlightBackground of color
  | HighlightColor of color
  | HighlightThickness of units
  | IPadX of units
  | IPadY of units
  | ImageBitmap of imageBitmap
  | ImagePhoto of imagePhoto
  | In of Widget.widget
  | IndicatorOn of bool
  | InsertBackground of color
  | InsertBorderWidth of units
  | InsertOffTime of int
  | InsertOnTime of int
  | InsertWidth of units
  | JoinStyle of joinStyle
  | Jump of bool
  | Justify of justification
  | LMargin1 of units
  | LMargin2 of units
  | Label of string
  | Length of units
  | Maskdata of string
  | Maskfile of string
  | Menu of Widget.widget
  | OffValue of string
  | Offset of units
  | OnValue of string
  | Orient of orientation
  | Outline of color
  | OutlineStipple of bitmap
  | OverStrike of bool
  | PadX of units
  | PadY of units
  | PageAnchor of anchor
  | PageHeight of units
  | PageWidth of units
  | PageX of units
  | PageY of units
  | Palette of paletteType
  | PostCommand of (unit -> unit)
  | RMargin of units
  | RelHeight of float
  | RelWidth of float
  | RelX of float
  | RelY of float
  | Relief of relief
  | RepeatDelay of int
  | RepeatInterval of int
  | Resolution of float
  | Rotate of bool
  | Row of int
  | RowSpan of int
  | ScaleCommand of (float -> unit)
  | Screen of string
  | ScrollCommand of (scrollValue -> unit)
  | ScrollRegion of units * units * units * units
  | SelectBackground of color
  | SelectBorderWidth of units
  | SelectColor of color
  | SelectForeground of color
  | SelectImageBitmap of imageBitmap
  | SelectImagePhoto of imagePhoto
  | SelectMode of selectModeType
  | SetGrid of bool
  | Show of char
  | ShowValue of bool
  | Side of side
  | SliderLength of units
  | Smooth of bool
  | Spacing1 of units
  | Spacing2 of units
  | Spacing3 of units
  | SplineSteps of int
  | Start of float
  | State of state
  | Sticky of string
  | Stipple of bitmap
  | Stretch of bool
  | Tabs of tabType list
  | Tags of tagOrId list
  | TakeFocus of bool
  | TearOff of bool
  | Text of string
  | TextHeight of int
  | TextVariable of Textvariable.textVariable
  | TextWidth of int
  | TickInterval of float
  | To of float
  | TroughColor of color
  | Underline of bool
  | UnderlinedChar of int
  | Value of string
  | Variable of Textvariable.textVariable
  | Visual of visual
  | Width of units
  | Window of Widget.widget
  | Wrap of wrapMode
  | WrapLength of units
  | X of units
  | XScrollCommand of (float -> float -> unit)
  | XScrollIncrement of units
  | Y of units
  | YScrollCommand of (float -> float -> unit)
  | YScrollIncrement of units
and options_constrs =
    CAccelerator
  | CActiveBackground
  | CActiveBorderWidth
  | CActiveForeground
  | CActiveRelief
  | CAfter
  | CAlign
  | CAnchor
  | CArcStyle
  | CArrowShape
  | CArrowStyle
  | CAspect
  | CBackground
  | CBefore
  | CBgStipple
  | CBigIncrement
  | CBitmap
  | CBorderMode
  | CBorderWidth
  | CCapStyle
  | CClass
  | CCloseEnough
  | CColormap
  | CColormode
  | CColumn
  | CColumnSpan
  | CCommand
  | CConfine
  | CCursor
  | CData
  | CDigits
  | CDisabledForeground
  | CElementBorderWidth
  | CExpand
  | CExportSelection
  | CExtent
  | CFgStipple
  | CFile
  | CFill
  | CFillColor
  | CFont
  | CForeground
  | CFormat
  | CFrom
  | CGamma
  | CGeometry
  | CHeight
  | CHighlightBackground
  | CHighlightColor
  | CHighlightThickness
  | CIPadX
  | CIPadY
  | CImageBitmap
  | CImagePhoto
  | CIn
  | CIndicatorOn
  | CInsertBackground
  | CInsertBorderWidth
  | CInsertOffTime
  | CInsertOnTime
  | CInsertWidth
  | CJoinStyle
  | CJump
  | CJustify
  | CLMargin1
  | CLMargin2
  | CLabel
  | CLength
  | CMaskdata
  | CMaskfile
  | CMenu
  | COffValue
  | COffset
  | COnValue
  | COrient
  | COutline
  | COutlineStipple
  | COverStrike
  | CPadX
  | CPadY
  | CPageAnchor
  | CPageHeight
  | CPageWidth
  | CPageX
  | CPageY
  | CPalette
  | CPostCommand
  | CRMargin
  | CRelHeight
  | CRelWidth
  | CRelX
  | CRelY
  | CRelief
  | CRepeatDelay
  | CRepeatInterval
  | CResolution
  | CRotate
  | CRow
  | CRowSpan
  | CScaleCommand
  | CScreen
  | CScrollCommand
  | CScrollRegion
  | CSelectBackground
  | CSelectBorderWidth
  | CSelectColor
  | CSelectForeground
  | CSelectImageBitmap
  | CSelectImagePhoto
  | CSelectMode
  | CSetGrid
  | CShow
  | CShowValue
  | CSide
  | CSliderLength
  | CSmooth
  | CSpacing1
  | CSpacing2
  | CSpacing3
  | CSplineSteps
  | CStart
  | CState
  | CSticky
  | CStipple
  | CStretch
  | CTabs
  | CTags
  | CTakeFocus
  | CTearOff
  | CText
  | CTextHeight
  | CTextVariable
  | CTextWidth
  | CTickInterval
  | CTo
  | CTroughColor
  | CUnderline
  | CUnderlinedChar
  | CValue
  | CVariable
  | CVisual
  | CWidth
  | CWindow
  | CWrap
  | CWrapLength
  | CX
  | CXScrollCommand
  | CXScrollIncrement
  | CY
  | CYScrollCommand
  | CYScrollIncrement

val options_any_table : options_constrs list

val options_toplevel_table : options_constrs list

val options_texttag_table : options_constrs list

val options_text_table : options_constrs list

val options_embeddedw_table : options_constrs list

val options_scrollbar_table : options_constrs list

val options_scale_table : options_constrs list

val options_radiobutton_table : options_constrs list

val options_place_table : options_constrs list

val options_photoimage_table : options_constrs list

val options_pack_table : options_constrs list

val options_message_table : options_constrs list

val options_menubutton_table : options_constrs list

val options_menu_table : options_constrs list

val options_menucommand_table : options_constrs list

val options_menucheck_table : options_constrs list

val options_menuradio_table : options_constrs list

val options_menucascade_table : options_constrs list

val options_menuentry_table : options_constrs list

val options_listbox_table : options_constrs list

val options_label_table : options_constrs list

val options_grid_table : options_constrs list

val options_frame_table : options_constrs list

val options_entry_table : options_constrs list

val options_checkbutton_table : options_constrs list

val options_canvas_table : options_constrs list

val options_window_table : options_constrs list

val options_canvastext_table : options_constrs list

val options_rectangle_table : options_constrs list

val options_polygon_table : options_constrs list

val options_oval_table : options_constrs list

val options_line_table : options_constrs list

val options_image_table : options_constrs list

val options_bitmap_table : options_constrs list

val options_arc_table : options_constrs list

val options_postscript_table : options_constrs list

val options_button_table : options_constrs list

val options_bitmapimage_table : options_constrs list

val options_standard_table : options_constrs list

val cCAMLtoTKoptions :
  Widget.widget -> options_constrs list -> options -> Protocol.tkArgs
type searchSpec =
    Above of tagOrId
  | All
  | Below of tagOrId
  | Closest of units * units
  | ClosestHalo of units * units * units
  | ClosestHaloStart of units * units * units * tagOrId
  | Enclosed of units * units * units * units
  | Overlapping of int * int * int * int
  | Withtag of tagOrId

val cCAMLtoTKsearchSpec : searchSpec -> Protocol.tkArgs
type canvasItem =
    Arc_item
  | Bitmap_item
  | Image_item
  | Line_item
  | Oval_item
  | Polygon_item
  | Rectangle_item
  | Text_item
  | User_item of string
  | Window_item

val cCAMLtoTKcanvasItem : canvasItem -> Protocol.tkArgs

val cTKtoCAMLcanvasItem : string -> canvasItem
type icccm =
    DisplayOf of Widget.widget
  | ICCCMFormat of string
  | ICCCMType of string
  | LostCommand of (unit -> unit)
  | Selection of string
and icccm_constrs =
    CDisplayOf
  | CICCCMFormat
  | CICCCMType
  | CLostCommand
  | CSelection

val icccm_any_table : icccm_constrs list

val icccm_selection_handle_table : icccm_constrs list

val icccm_selection_ownset_table : icccm_constrs list

val icccm_selection_get_table : icccm_constrs list

val icccm_selection_clear_table : icccm_constrs list

val icccm_clipboard_append_table : icccm_constrs list

val icccm_clipboard_clear_table : icccm_constrs list

val cCAMLtoTKicccm :
  Widget.widget -> icccm_constrs list -> icccm -> Protocol.tkArgs
type grabStatus = GrabGlobal | GrabLocal | GrabNone

val cCAMLtoTKgrabStatus : grabStatus -> Protocol.tkArgs

val cTKtoCAMLgrabStatus : string -> grabStatus
type gridopt = Minsize of units | Weight of float

val cCAMLtoTKgridopt : gridopt -> Protocol.tkArgs
type menuItem =
    Cascade_Item
  | Checkbutton_Item
  | Command_Item
  | Radiobutton_Item
  | Separator_Item
  | TearOff_Item

val cCAMLtoTKmenuItem : menuItem -> Protocol.tkArgs

val cTKtoCAMLmenuItem : string -> menuItem
type optionPriority =
    Interactive
  | Priority of int
  | StartupFile
  | UserDefault
  | WidgetDefault

val cCAMLtoTKoptionPriority : optionPriority -> Protocol.tkArgs
type photo =
    ImgFormat of string
  | ImgFrom of int * int * int * int
  | ImgTo of int * int * int * int
  | Shrink
  | Subsample of int * int
  | TopLeft of int * int
  | Zoom of int * int
and photo_constrs =
    CImgFormat
  | CImgFrom
  | CImgTo
  | CShrink
  | CSubsample
  | CTopLeft
  | CZoom

val photo_any_table : photo_constrs list

val photo_write_table : photo_constrs list

val photo_read_table : photo_constrs list

val photo_put_table : photo_constrs list

val photo_copy_table : photo_constrs list

val cCAMLtoTKphoto : photo_constrs list -> photo -> Protocol.tkArgs
type widgetElement = Arrow1 | Arrow2 | Beyond | Slider | Trough1 | Trough2
and widgetElement_constrs =
    CArrow1
  | CArrow2
  | CBeyond
  | CSlider
  | CTrough1
  | CTrough2

val widgetElement_any_table : widgetElement_constrs list

val widgetElement_scrollbar_table : widgetElement_constrs list

val widgetElement_scale_table : widgetElement_constrs list

val cCAMLtoTKwidgetElement :
  widgetElement_constrs list -> widgetElement -> Protocol.tkArgs

val cTKtoCAMLwidgetElement : string -> widgetElement
type comparison = EQ | GE | GT | LE | LT | NEQ

val cCAMLtoTKcomparison : comparison -> Protocol.tkArgs
type markDirection = Mark_Left | Mark_Right

val cCAMLtoTKmarkDirection : markDirection -> Protocol.tkArgs

val cTKtoCAMLmarkDirection : string -> markDirection
type textSearch =
    Backwards
  | Count of Textvariable.textVariable
  | Exact
  | Forwards
  | Nocase
  | Regexp

val cCAMLtoTKtextSearch : textSearch -> Protocol.tkArgs
type atomId = AtomId of int

val cCAMLtoTKatomId : atomId -> Protocol.tkArgs

val cTKtoCAMLatomId : string -> atomId
type focusModel = FocusActive | FocusPassive

val cCAMLtoTKfocusModel : focusModel -> Protocol.tkArgs

val cTKtoCAMLfocusModel : string -> focusModel
type wmFrom = FromProgram | FromUser

val cCAMLtoTKwmFrom : wmFrom -> Protocol.tkArgs

val cTKtoCAMLwmFrom : string -> wmFrom

val cCAMLtoTKoptions_constrs : options_constrs -> Protocol.tkArgs

val update_idletasks : unit -> unit

val update : unit -> unit

val appname_get : unit -> string

val appname_set : string -> unit

val raise_window_above : Widget.widget -> Widget.widget -> unit

val raise_window : Widget.widget -> unit

val place : Widget.widget -> options list -> unit

val pack : Widget.widget list -> options list -> unit

val lower_window_below : Widget.widget -> Widget.widget -> unit

val lower_window : Widget.widget -> unit

val grid : Widget.widget list -> options list -> unit

val destroy : Widget.widget -> unit

val bindtags_get : Widget.widget -> bindings list

val bindtags : Widget.widget -> bindings list -> unit

val cget : Widget.widget -> options_constrs -> string
val cgets : Widget.widget -> string -> string


Go to the first, previous, next, last section, table of contents.