Skip to content
Snippets Groups Projects
scintilla.rb 100 KiB
Newer Older
  • Learn to ignore specific revisions
  • # This file is automatically generated from Scintilla.iface
    # DO NOT MODIFY
    
    module Fox
      class FXScintilla
        # 
    
    
    
    
    
    
    
        # Basics
    
        INVALID_POSITION = -1
        # Define start of Scintilla messages to be greater than all Windows edit (EM_*) messages
        # as many EM_ messages can be used although that use is deprecated.
        SCI_START = 2000
        SCI_OPTIONAL_START = 3000
        SCI_LEXER_START = 4000
    
        # Add text to the document at current position.
        def addText(length, text)
          sendMessage(2001, length, text)
        end
    
        # Add array of cells to document.
        def addStyledText(length, c)
          sendMessage(2002, length, c)
        end
    
        # Insert string at a position.
        def insertText(pos, text)
          sendMessage(2003, pos, text)
        end
    
        # Delete all text in the document.
        def clearAll
          sendMessage(2004, 0, 0)
        end
    
        # Set all style bytes to 0, remove all folding information.
        def clearDocumentStyle
          sendMessage(2005, 0, 0)
        end
    
        # Returns the number of characters in the document.
        def getLength
          sendMessage(2006, 0, 0)
        end
    
        # Returns the character byte at the position.
        def getCharAt(pos)
          sendMessage(2007, pos, 0)
        end
    
        # Returns the position of the caret.
        def getCurrentPos
          sendMessage(2008, 0, 0)
        end
    
        # Returns the position of the opposite end of the selection to the caret.
        def getAnchor
          sendMessage(2009, 0, 0)
        end
    
        # Returns the style byte at the position.
        def getStyleAt(pos)
          sendMessage(2010, pos, 0)
        end
    
        # Redoes the next action on the undo history.
        def redo
          sendMessage(2011, 0, 0)
        end
    
        # Choose between collecting actions into the undo
        # history and discarding them.
        def setUndoCollection(collectUndo)
          sendMessage(2012, collectUndo, 0)
        end
    
        # Select all the text in the document.
        def selectAll
          sendMessage(2013, 0, 0)
        end
    
        # Remember the current position in the undo history as the position
        # at which the document was saved.
        def setSavePoint
          sendMessage(2014, 0, 0)
        end
    
        # Retrieve a buffer of cells.
        # Returns the number of bytes in the buffer not including terminating NULs.
        def getStyledText(tr)
          sendMessage(2015, 0, tr)
        end
    
        # Are there any redoable actions in the undo history?
        def canRedo
          sendMessage(2016, 0, 0) == 1 ? true : false
        end
    
        # Retrieve the line number at which a particular marker is located.
        def markerLineFromHandle(handle)
          sendMessage(2017, handle, 0)
        end
    
        # Delete a marker.
        def markerDeleteHandle(handle)
          sendMessage(2018, handle, 0)
        end
    
        # Is undo history being collected?
        def getUndoCollection
          sendMessage(2019, 0, 0) == 1 ? true : false
        end
    
        SCWS_INVISIBLE = 0
        SCWS_VISIBLEALWAYS = 1
        SCWS_VISIBLEAFTERINDENT = 2
    
        # Are white space characters currently visible?
        # Returns one of SCWS_* constants.
        def getViewWS
          sendMessage(2020, 0, 0)
        end
    
        # Make white space characters invisible, always visible or visible outside indentation.
        def setViewWS(viewWS)
          sendMessage(2021, viewWS, 0)
        end
    
        # Find the position from a point within the window.
        def positionFromPoint(x, y)
          sendMessage(2022, x, y)
        end
    
        # Find the position from a point within the window but return
        # INVALID_POSITION if not close to text.
        def positionFromPointClose(x, y)
          sendMessage(2023, x, y)
        end
    
        # Set caret to start of a line and ensure it is visible.
        def gotoLine(line)
          sendMessage(2024, line, 0)
        end
    
        # Set caret to a position and ensure it is visible.
        def gotoPos(pos)
          sendMessage(2025, pos, 0)
        end
    
        # Set the selection anchor to a position. The anchor is the opposite
        # end of the selection from the caret.
        def setAnchor(posAnchor)
          sendMessage(2026, posAnchor, 0)
        end
    
        # Retrieve the text of the line containing the caret.
        # Returns the index of the caret on the line.
        def getCurLine(length)
          buffer = "".ljust(length)
          sendMessage(2027, length, buffer)
          buffer
        end
    
        # Retrieve the position of the last correctly styled character.
        def getEndStyled
          sendMessage(2028, 0, 0)
        end
    
        SC_EOL_CRLF = 0
        SC_EOL_CR = 1
        SC_EOL_LF = 2
    
        # Convert all line endings in the document to one mode.
        def convertEOLs(eolMode)
          sendMessage(2029, eolMode, 0)
        end
    
        # Retrieve the current end of line mode - one of CRLF, CR, or LF.
        def getEOLMode
          sendMessage(2030, 0, 0)
        end
    
        # Set the current end of line mode.
        def setEOLMode(eolMode)
          sendMessage(2031, eolMode, 0)
        end
    
        # Set the current styling position to pos and the styling mask to mask.
        # The styling mask can be used to protect some bits in each styling byte from modification.
        def startStyling(pos, mask)
          sendMessage(2032, pos, mask)
        end
    
        # Change style from current styling position for length characters to a style
        # and move the current styling position to after this newly styled segment.
        def setStyling(length, style)
          sendMessage(2033, length, style)
        end
    
        # Is drawing done first into a buffer or direct to the screen?
        def getBufferedDraw
          sendMessage(2034, 0, 0) == 1 ? true : false
        end
    
        # If drawing is buffered then each line of text is drawn into a bitmap buffer
        # before drawing it to the screen to avoid flicker.
        def setBufferedDraw(buffered)
          sendMessage(2035, buffered, 0)
        end
    
        # Change the visible size of a tab to be a multiple of the width of a space character.
        def setTabWidth(tabWidth)
          sendMessage(2036, tabWidth, 0)
        end
    
        # Retrieve the visible size of a tab.
        def getTabWidth
          sendMessage(2121, 0, 0)
        end
    
        # The SC_CP_UTF8 value can be used to enter Unicode mode.
        # This is the same value as CP_UTF8 in Windows
        SC_CP_UTF8 = 65001
    
        # The SC_CP_DBCS value can be used to indicate a DBCS mode for GTK+.
        SC_CP_DBCS = 1
    
        # Set the code page used to interpret the bytes of the document as characters.
        # The SC_CP_UTF8 value can be used to enter Unicode mode.
        def setCodePage(codePage)
          sendMessage(2037, codePage, 0)
        end
    
        # In palette mode, Scintilla uses the environment's palette calls to display
        # more colours. This may lead to ugly displays.
        def setUsePalette(usePalette)
          sendMessage(2039, usePalette, 0)
        end
    
        MARKER_MAX = 31
        SC_MARK_CIRCLE = 0
        SC_MARK_ROUNDRECT = 1
        SC_MARK_ARROW = 2
        SC_MARK_SMALLRECT = 3
        SC_MARK_SHORTARROW = 4
        SC_MARK_EMPTY = 5
        SC_MARK_ARROWDOWN = 6
        SC_MARK_MINUS = 7
        SC_MARK_PLUS = 8
    
        # Shapes used for outlining column.
        SC_MARK_VLINE = 9
        SC_MARK_LCORNER = 10
        SC_MARK_TCORNER = 11
        SC_MARK_BOXPLUS = 12
        SC_MARK_BOXPLUSCONNECTED = 13
        SC_MARK_BOXMINUS = 14
        SC_MARK_BOXMINUSCONNECTED = 15
        SC_MARK_LCORNERCURVE = 16
        SC_MARK_TCORNERCURVE = 17
        SC_MARK_CIRCLEPLUS = 18
        SC_MARK_CIRCLEPLUSCONNECTED = 19
        SC_MARK_CIRCLEMINUS = 20
        SC_MARK_CIRCLEMINUSCONNECTED = 21
    
        # Invisible mark that only sets the line background color.
        SC_MARK_BACKGROUND = 22
        SC_MARK_DOTDOTDOT = 23
        SC_MARK_ARROWS = 24
        SC_MARK_PIXMAP = 25
        SC_MARK_FULLRECT = 26
    
        SC_MARK_CHARACTER = 10000
    
        # Markers used for outlining column.
        SC_MARKNUM_FOLDEREND = 25
        SC_MARKNUM_FOLDEROPENMID = 26
        SC_MARKNUM_FOLDERMIDTAIL = 27
        SC_MARKNUM_FOLDERTAIL = 28
        SC_MARKNUM_FOLDERSUB = 29
        SC_MARKNUM_FOLDER = 30
        SC_MARKNUM_FOLDEROPEN = 31
    
        SC_MASK_FOLDERS = 0xFE000000
    
        # Set the symbol used for a particular marker number.
        def markerDefine(markerNumber, markerSymbol)
          sendMessage(2040, markerNumber, markerSymbol)
        end
    
        # Set the foreground colour used for a particular marker number.
        def markerSetFore(markerNumber, fore)
          sendMessage(2041, markerNumber, fore & 0xffffff)
        end
    
        # Set the background colour used for a particular marker number.
        def markerSetBack(markerNumber, back)
          sendMessage(2042, markerNumber, back & 0xffffff)
        end
    
        # Add a marker to a line, returning an ID which can be used to find or delete the marker.
        def markerAdd(line, markerNumber)
          sendMessage(2043, line, markerNumber)
        end
    
        # Delete a marker from a line.
        def markerDelete(line, markerNumber)
          sendMessage(2044, line, markerNumber)
        end
    
        # Delete all markers with a particular number from all lines.
        def markerDeleteAll(markerNumber)
          sendMessage(2045, markerNumber, 0)
        end
    
        # Get a bit mask of all the markers set on a line.
        def markerGet(line)
          sendMessage(2046, line, 0)
        end
    
        # Find the next line after lineStart that includes a marker in mask.
        def markerNext(lineStart, markerMask)
          sendMessage(2047, lineStart, markerMask)
        end
    
        # Find the previous line before lineStart that includes a marker in mask.
        def markerPrevious(lineStart, markerMask)
          sendMessage(2048, lineStart, markerMask)
        end
    
        # Define a marker from a pixmap.
        def markerDefinePixmap(markerNumber, pixmap)
          sendMessage(2049, markerNumber, pixmap)
        end
    
        # Add a set of markers to a line.
        def markerAddSet(line, set)
          sendMessage(2466, line, set)
        end
    
    
        # Set the alpha used for a marker that is drawn in the text area, not the margin.
        def markerSetAlpha(markerNumber, alpha)
          sendMessage(2476, markerNumber, alpha)
        end
    
    
        SC_MARGIN_SYMBOL = 0
        SC_MARGIN_NUMBER = 1
    
        SC_MARGIN_BACK = 2
        SC_MARGIN_FORE = 3
    
    
        # Set a margin to be either numeric or symbolic.
        def setMarginTypeN(margin, marginType)
          sendMessage(2240, margin, marginType)
        end
    
        # Retrieve the type of a margin.
        def getMarginTypeN(margin)
          sendMessage(2241, margin, 0)
        end
    
        # Set the width of a margin to a width expressed in pixels.
        def setMarginWidthN(margin, pixelWidth)
          sendMessage(2242, margin, pixelWidth)
        end
    
        # Retrieve the width of a margin in pixels.
        def getMarginWidthN(margin)
          sendMessage(2243, margin, 0)
        end
    
        # Set a mask that determines which markers are displayed in a margin.
        def setMarginMaskN(margin, mask)
          sendMessage(2244, margin, mask)
        end
    
        # Retrieve the marker mask of a margin.
        def getMarginMaskN(margin)
          sendMessage(2245, margin, 0)
        end
    
        # Make a margin sensitive or insensitive to mouse clicks.
        def setMarginSensitiveN(margin, sensitive)
          sendMessage(2246, margin, sensitive)
        end
    
        # Retrieve the mouse click sensitivity of a margin.
        def getMarginSensitiveN(margin)
          sendMessage(2247, margin, 0) == 1 ? true : false
        end
    
    
        # Styles in range 32..38 are predefined for parts of the UI and are not used as normal styles.
        # Style 39 is for future use.
    
        STYLE_DEFAULT = 32
        STYLE_LINENUMBER = 33
        STYLE_BRACELIGHT = 34
        STYLE_BRACEBAD = 35
        STYLE_CONTROLCHAR = 36
        STYLE_INDENTGUIDE = 37
    
        STYLE_LASTPREDEFINED = 39
        STYLE_MAX = 127
    
        # Character set identifiers are used in StyleSetCharacterSet.
        # The values are the same as the Windows *_CHARSET values.
        SC_CHARSET_ANSI = 0
        SC_CHARSET_DEFAULT = 1
        SC_CHARSET_BALTIC = 186
        SC_CHARSET_CHINESEBIG5 = 136
        SC_CHARSET_EASTEUROPE = 238
        SC_CHARSET_GB2312 = 134
        SC_CHARSET_GREEK = 161
        SC_CHARSET_HANGUL = 129
        SC_CHARSET_MAC = 77
        SC_CHARSET_OEM = 255
        SC_CHARSET_RUSSIAN = 204
        SC_CHARSET_CYRILLIC = 1251
        SC_CHARSET_SHIFTJIS = 128
        SC_CHARSET_SYMBOL = 2
        SC_CHARSET_TURKISH = 162
        SC_CHARSET_JOHAB = 130
        SC_CHARSET_HEBREW = 177
        SC_CHARSET_ARABIC = 178
        SC_CHARSET_VIETNAMESE = 163
        SC_CHARSET_THAI = 222
        SC_CHARSET_8859_15 = 1000
    
        # Clear all the styles and make equivalent to the global default style.
        def styleClearAll
          sendMessage(2050, 0, 0)
        end
    
        # Set the foreground colour of a style.
        def styleSetFore(style, fore)
          sendMessage(2051, style, fore & 0xffffff)
        end
    
        # Set the background colour of a style.
        def styleSetBack(style, back)
          sendMessage(2052, style, back & 0xffffff)
        end
    
        # Set a style to be bold or not.
        def styleSetBold(style, bold)
          sendMessage(2053, style, bold)
        end
    
        # Set a style to be italic or not.
        def styleSetItalic(style, italic)
          sendMessage(2054, style, italic)
        end
    
        # Set the size of characters of a style.
        def styleSetSize(style, sizePoints)
          sendMessage(2055, style, sizePoints)
        end
    
        # Set the font of a style.
        def styleSetFont(style, fontName)
          sendMessage(2056, style, fontName)
        end
    
        # Set a style to have its end of line filled or not.
        def styleSetEOLFilled(style, filled)
          sendMessage(2057, style, filled)
        end
    
        # Reset the default style to its state at startup
        def styleResetDefault
          sendMessage(2058, 0, 0)
        end
    
        # Set a style to be underlined or not.
        def styleSetUnderline(style, underline)
          sendMessage(2059, style, underline)
        end
    
        SC_CASE_MIXED = 0
        SC_CASE_UPPER = 1
        SC_CASE_LOWER = 2
        # Set a style to be mixed case, or to force upper or lower case.
        def styleSetCase(style, caseForce)
          sendMessage(2060, style, caseForce)
        end
    
        # Set the character set of the font in a style.
        def styleSetCharacterSet(style, characterSet)
          sendMessage(2066, style, characterSet)
        end
    
        # Set a style to be a hotspot or not.
        def styleSetHotSpot(style, hotspot)
          sendMessage(2409, style, hotspot)
        end
    
        # Set the foreground colour of the selection and whether to use this setting.
        def setSelFore(useSetting, fore)
          sendMessage(2067, useSetting, fore & 0xffffff)
        end
    
        # Set the background colour of the selection and whether to use this setting.
        def setSelBack(useSetting, back)
          sendMessage(2068, useSetting, back & 0xffffff)
        end
    
    
        # Get the alpha of the selection.
        def getSelAlpha
          sendMessage(2477, 0, 0)
        end
    
        # Set the alpha of the selection.
        def setSelAlpha(alpha)
          sendMessage(2478, alpha, 0)
        end
    
    
        # Set the foreground colour of the caret.
        def setCaretFore(fore)
          sendMessage(2069, fore & 0xffffff, 0)
        end
    
        # When key+modifier combination km is pressed perform msg.
        def assignCmdKey(km, msg)
          sendMessage(2070, km, msg)
        end
    
        # When key+modifier combination km is pressed do nothing.
        def clearCmdKey(km)
          sendMessage(2071, km, 0)
        end
    
        # Drop all key mappings.
        def clearAllCmdKeys
          sendMessage(2072, 0, 0)
        end
    
        # Set the styles for a segment of the document.
        def setStylingEx(length, styles)
          sendMessage(2073, length, styles)
        end
    
        # Set a style to be visible or not.
        def styleSetVisible(style, visible)
          sendMessage(2074, style, visible)
        end
    
        # Get the time in milliseconds that the caret is on and off.
        def getCaretPeriod
          sendMessage(2075, 0, 0)
        end
    
        # Get the time in milliseconds that the caret is on and off. 0 = steady on.
        def setCaretPeriod(periodMilliseconds)
          sendMessage(2076, periodMilliseconds, 0)
        end
    
        # Set the set of characters making up words for when moving or selecting by word.
        # First sets deaults like SetCharsDefault.
        def setWordChars(characters)
          sendMessage(2077, 0, characters)
        end
    
        # Start a sequence of actions that is undone and redone as a unit.
        # May be nested.
        def beginUndoAction
          sendMessage(2078, 0, 0)
        end
    
        # End a sequence of actions that is undone and redone as a unit.
        def endUndoAction
          sendMessage(2079, 0, 0)
        end
    
        INDIC_MAX = 7
        INDIC_PLAIN = 0
        INDIC_SQUIGGLE = 1
        INDIC_TT = 2
        INDIC_DIAGONAL = 3
        INDIC_STRIKE = 4
        INDIC_HIDDEN = 5
        INDIC_BOX = 6
    
    588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000
        INDIC0_MASK = 0x20
        INDIC1_MASK = 0x40
        INDIC2_MASK = 0x80
        INDICS_MASK = 0xE0
    
        # Set an indicator to plain, squiggle or TT.
        def indicSetStyle(indic, style)
          sendMessage(2080, indic, style)
        end
    
        # Retrieve the style of an indicator.
        def indicGetStyle(indic)
          sendMessage(2081, indic, 0)
        end
    
        # Set the foreground colour of an indicator.
        def indicSetFore(indic, fore)
          sendMessage(2082, indic, fore & 0xffffff)
        end
    
        # Retrieve the foreground colour of an indicator.
        def indicGetFore(indic)
          sendMessage(2083, indic, 0)
        end
    
        # Set the foreground colour of all whitespace and whether to use this setting.
        def setWhitespaceFore(useSetting, fore)
          sendMessage(2084, useSetting, fore & 0xffffff)
        end
    
        # Set the background colour of all whitespace and whether to use this setting.
        def setWhitespaceBack(useSetting, back)
          sendMessage(2085, useSetting, back & 0xffffff)
        end
    
        # Divide each styling byte into lexical class bits (default: 5) and indicator
        # bits (default: 3). If a lexer requires more than 32 lexical states, then this
        # is used to expand the possible states.
        def setStyleBits(bits)
          sendMessage(2090, bits, 0)
        end
    
        # Retrieve number of bits in style bytes used to hold the lexical state.
        def getStyleBits
          sendMessage(2091, 0, 0)
        end
    
        # Used to hold extra styling information for each line.
        def setLineState(line, state)
          sendMessage(2092, line, state)
        end
    
        # Retrieve the extra styling information for a line.
        def getLineState(line)
          sendMessage(2093, line, 0)
        end
    
        # Retrieve the last line number that has line state.
        def getMaxLineState
          sendMessage(2094, 0, 0)
        end
    
        # Is the background of the line containing the caret in a different colour?
        def getCaretLineVisible
          sendMessage(2095, 0, 0) == 1 ? true : false
        end
    
        # Display the background of the line containing the caret in a different colour.
        def setCaretLineVisible(show)
          sendMessage(2096, show, 0)
        end
    
        # Get the colour of the background of the line containing the caret.
        def getCaretLineBack
          sendMessage(2097, 0, 0)
        end
    
        # Set the colour of the background of the line containing the caret.
        def setCaretLineBack(back)
          sendMessage(2098, back & 0xffffff, 0)
        end
    
        # Set a style to be changeable or not (read only).
        # Experimental feature, currently buggy.
        def styleSetChangeable(style, changeable)
          sendMessage(2099, style, changeable)
        end
    
        # Display a auto-completion list.
        # The lenEntered parameter indicates how many characters before
        # the caret should be used to provide context.
        def autoCShow(lenEntered, itemList)
          sendMessage(2100, lenEntered, itemList)
        end
    
        # Remove the auto-completion list from the screen.
        def autoCCancel
          sendMessage(2101, 0, 0)
        end
    
        # Is there an auto-completion list visible?
        def autoCActive
          sendMessage(2102, 0, 0) == 1 ? true : false
        end
    
        # Retrieve the position of the caret when the auto-completion list was displayed.
        def autoCPosStart
          sendMessage(2103, 0, 0)
        end
    
        # User has selected an item so remove the list and insert the selection.
        def autoCComplete
          sendMessage(2104, 0, 0)
        end
    
        # Define a set of character that when typed cancel the auto-completion list.
        def autoCStops(characterSet)
          sendMessage(2105, 0, characterSet)
        end
    
        # Change the separator character in the string setting up an auto-completion list.
        # Default is space but can be changed if items contain space.
        def autoCSetSeparator(separatorCharacter)
          sendMessage(2106, separatorCharacter, 0)
        end
    
        # Retrieve the auto-completion list separator character.
        def autoCGetSeparator
          sendMessage(2107, 0, 0)
        end
    
        # Select the item in the auto-completion list that starts with a string.
        def autoCSelect(text)
          sendMessage(2108, 0, text)
        end
    
        # Should the auto-completion list be cancelled if the user backspaces to a
        # position before where the box was created.
        def autoCSetCancelAtStart(cancel)
          sendMessage(2110, cancel, 0)
        end
    
        # Retrieve whether auto-completion cancelled by backspacing before start.
        def autoCGetCancelAtStart
          sendMessage(2111, 0, 0) == 1 ? true : false
        end
    
        # Define a set of characters that when typed will cause the autocompletion to
        # choose the selected item.
        def autoCSetFillUps(characterSet)
          sendMessage(2112, 0, characterSet)
        end
    
        # Should a single item auto-completion list automatically choose the item.
        def autoCSetChooseSingle(chooseSingle)
          sendMessage(2113, chooseSingle, 0)
        end
    
        # Retrieve whether a single item auto-completion list automatically choose the item.
        def autoCGetChooseSingle
          sendMessage(2114, 0, 0) == 1 ? true : false
        end
    
        # Set whether case is significant when performing auto-completion searches.
        def autoCSetIgnoreCase(ignoreCase)
          sendMessage(2115, ignoreCase, 0)
        end
    
        # Retrieve state of ignore case flag.
        def autoCGetIgnoreCase
          sendMessage(2116, 0, 0) == 1 ? true : false
        end
    
        # Display a list of strings and send notification when user chooses one.
        def userListShow(listType, itemList)
          sendMessage(2117, listType, itemList)
        end
    
        # Set whether or not autocompletion is hidden automatically when nothing matches.
        def autoCSetAutoHide(autoHide)
          sendMessage(2118, autoHide, 0)
        end
    
        # Retrieve whether or not autocompletion is hidden automatically when nothing matches.
        def autoCGetAutoHide
          sendMessage(2119, 0, 0) == 1 ? true : false
        end
    
        # Set whether or not autocompletion deletes any word characters
        # after the inserted text upon completion.
        def autoCSetDropRestOfWord(dropRestOfWord)
          sendMessage(2270, dropRestOfWord, 0)
        end
    
        # Retrieve whether or not autocompletion deletes any word characters
        # after the inserted text upon completion.
        def autoCGetDropRestOfWord
          sendMessage(2271, 0, 0) == 1 ? true : false
        end
    
        # Register an XPM image for use in autocompletion lists.
        def registerImage(type, xpmData)
          sendMessage(2405, type, xpmData)
        end
    
        # Clear all the registered XPM images.
        def clearRegisteredImages
          sendMessage(2408, 0, 0)
        end
    
        # Retrieve the auto-completion list type-separator character.
        def autoCGetTypeSeparator
          sendMessage(2285, 0, 0)
        end
    
        # Change the type-separator character in the string setting up an auto-completion list.
        # Default is '?' but can be changed if items contain '?'.
        def autoCSetTypeSeparator(separatorCharacter)
          sendMessage(2286, separatorCharacter, 0)
        end
    
        # Set the maximum width, in characters, of auto-completion and user lists.
        # Set to 0 to autosize to fit longest item, which is the default.
        def autoCSetMaxWidth(characterCount)
          sendMessage(2208, characterCount, 0)
        end
    
        # Get the maximum width, in characters, of auto-completion and user lists.
        def autoCGetMaxWidth
          sendMessage(2209, 0, 0)
        end
    
        # Set the maximum height, in rows, of auto-completion and user lists.
        # The default is 5 rows.
        def autoCSetMaxHeight(rowCount)
          sendMessage(2210, rowCount, 0)
        end
    
        # Set the maximum height, in rows, of auto-completion and user lists.
        def autoCGetMaxHeight
          sendMessage(2211, 0, 0)
        end
    
        # Set the number of spaces used for one level of indentation.
        def setIndent(indentSize)
          sendMessage(2122, indentSize, 0)
        end
    
        # Retrieve indentation size.
        def getIndent
          sendMessage(2123, 0, 0)
        end
    
        # Indentation will only use space characters if useTabs is false, otherwise
        # it will use a combination of tabs and spaces.
        def setUseTabs(useTabs)
          sendMessage(2124, useTabs, 0)
        end
    
        # Retrieve whether tabs will be used in indentation.
        def getUseTabs
          sendMessage(2125, 0, 0) == 1 ? true : false
        end
    
        # Change the indentation of a line to a number of columns.
        def setLineIndentation(line, indentSize)
          sendMessage(2126, line, indentSize)
        end
    
        # Retrieve the number of columns that a line is indented.
        def getLineIndentation(line)
          sendMessage(2127, line, 0)
        end
    
        # Retrieve the position before the first non indentation character on a line.
        def getLineIndentPosition(line)
          sendMessage(2128, line, 0)
        end
    
        # Retrieve the column number of a position, taking tab width into account.
        def getColumn(pos)
          sendMessage(2129, pos, 0)
        end
    
        # Show or hide the horizontal scroll bar.
        def setHScrollBar(show)
          sendMessage(2130, show, 0)
        end
    
        # Is the horizontal scroll bar visible?
        def getHScrollBar
          sendMessage(2131, 0, 0) == 1 ? true : false
        end
    
        # Show or hide indentation guides.
        def setIndentationGuides(show)
          sendMessage(2132, show, 0)
        end
    
        # Are the indentation guides visible?
        def getIndentationGuides
          sendMessage(2133, 0, 0) == 1 ? true : false
        end
    
        # Set the highlighted indentation guide column.
        # 0 = no highlighted guide.
        def setHighlightGuide(column)
          sendMessage(2134, column, 0)
        end
    
        # Get the highlighted indentation guide column.
        def getHighlightGuide
          sendMessage(2135, 0, 0)
        end
    
        # Get the position after the last visible characters on a line.
        def getLineEndPosition(line)
          sendMessage(2136, line, 0)
        end
    
        # Get the code page used to interpret the bytes of the document as characters.
        def getCodePage
          sendMessage(2137, 0, 0)
        end
    
        # Get the foreground colour of the caret.
        def getCaretFore
          sendMessage(2138, 0, 0)
        end
    
        # In palette mode?
        def getUsePalette
          sendMessage(2139, 0, 0) == 1 ? true : false
        end
    
        # In read-only mode?
        def getReadOnly
          sendMessage(2140, 0, 0) == 1 ? true : false
        end
    
        # Sets the position of the caret.
        def setCurrentPos(pos)
          sendMessage(2141, pos, 0)
        end
    
        # Sets the position that starts the selection - this becomes the anchor.
        def setSelectionStart(pos)
          sendMessage(2142, pos, 0)
        end
    
        # Returns the position at the start of the selection.
        def getSelectionStart
          sendMessage(2143, 0, 0)
        end
    
        # Sets the position that ends the selection - this becomes the currentPosition.
        def setSelectionEnd(pos)
          sendMessage(2144, pos, 0)
        end
    
        # Returns the position at the end of the selection.
        def getSelectionEnd
          sendMessage(2145, 0, 0)
        end
    
        # Sets the print magnification added to the point size of each style for printing.
        def setPrintMagnification(magnification)
          sendMessage(2146, magnification, 0)
        end
    
        # Returns the print magnification.
        def getPrintMagnification
          sendMessage(2147, 0, 0)
        end
    
        # PrintColourMode - use same colours as screen.
        SC_PRINT_NORMAL = 0
        # PrintColourMode - invert the light value of each style for printing.
        SC_PRINT_INVERTLIGHT = 1
        # PrintColourMode - force black text on white background for printing.
        SC_PRINT_BLACKONWHITE = 2
        # PrintColourMode - text stays coloured, but all background is forced to be white for printing.
        SC_PRINT_COLOURONWHITE = 3
        # PrintColourMode - only the default-background is forced to be white for printing.
        SC_PRINT_COLOURONWHITEDEFAULTBG = 4
    
        # Modify colours when printing for clearer printed text.
        def setPrintColourMode(mode)
          sendMessage(2148, mode, 0)
        end
    
        # Returns the print colour mode.
        def getPrintColourMode
          sendMessage(2149, 0, 0)
        end
    
        SCFIND_WHOLEWORD = 2
        SCFIND_MATCHCASE = 4
        SCFIND_WORDSTART = 0x00100000
        SCFIND_REGEXP = 0x00200000
        SCFIND_POSIX = 0x00400000
    
        # Find some text in the document.
        def findText(flags, ft)
          sendMessage(2150, flags, ft)
        end
    
        # On Windows, will draw the document into a display context such as a printer.
        def formatRange(draw, fr)
          sendMessage(2151, draw, fr)
        end
    
        # Retrieve the display line at the top of the display.