FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin para Harbour/xHarbour Scintilla
Posts: 1283
Joined: Fri Feb 10, 2006 02:34 PM
Scintilla
Posted: Tue Feb 28, 2012 12:33 PM

Hola a todos,

Alguien tiene ya hechos wrappers para usar scintilla ?

Salutacions, saludos, regards

"...programar es fácil, hacer programas es difícil..."

UT Page -> https://carles9000.github.io/
Forum UT -> https://discord.gg/bq8a9yGMWh
HIX -> https://github.com/carles9000/hix
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Scintilla
Posted: Tue Feb 28, 2012 12:35 PM

Carles,

Paco García los tiene bastante avanzados y me los ha cedido para incluirlos en FiveWin :-)

Los puedo copiar aqui por si alguien tiene interés en usarlos. A mi nunca me ha hecho gracia el usar Scintilla pues me parece mucha "mochila" para tener un editor de código fuente. Pero bueno, para gustos, colores :-)

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1283
Joined: Fri Feb 10, 2006 02:34 PM
Re: Scintilla
Posted: Tue Feb 28, 2012 12:38 PM

Paco los tiene ?

Y no ha dicho nada ? Ai ai ai :D Pues si los puedes poner o enviarmelos para probar, pues bien !!!

Salutacions, saludos, regards

"...programar es fácil, hacer programas es difícil..."

UT Page -> https://carles9000.github.io/
Forum UT -> https://discord.gg/bq8a9yGMWh
HIX -> https://github.com/carles9000/hix
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Scintilla
Posted: Tue Feb 28, 2012 12:40 PM
Código desarrollado por Paco García de CanalFive y cedido para usuarios de FiveWin:

scintila.prg (en dos posts, pues no cabe en uno solo)
Code (fw): Select all Collapse
#include "fivewin.ch"
#include "scintilla.ch"
#include "report.ch"
#include "mail.ch"
#include "scilexer.h"

static nError
static oCode
static cLastFind := ""

#define CW_USEDEFAULT      32768

static oReport

CLASS TScintilla FROM TControl

      DATA cFileName

      CLASSDATA lRegisterd AS LOGICAL
      CLASSDATA hLib
      DATA aCopys
      CLASSDATA nInst AS NUMERIC INIT 0
      CLASSDATA aMrus AS ARRAY INIT {}
      CLASSDATA cLineBuffer

      METHOD Default()
      METHOD SetColor( nClrText, nClrPane )


      METHOD New( nRow, nCol, oWnd, nWidth, nHeight ) CONSTRUCTOR
      METHOD End()
      METHOD AddText( cText )                        INLINE ::SendEditor( SCI_ADDTEXT, len( cText ), cText )
      METHOD AddTextCRLF( cText )                    INLINE ::SendEditor( SCI_ADDTEXT, len( cText )+2, cText+CRLF )
      METHOD Backtab()                               INLINE ::SendEditor( SCI_BACKTAB,0,0)
      METHOD CanRedo()                               INLINE ::SendEditor( SCI_CANREDO, 0, 0) != 0
      METHOD CanUndo()                               INLINE ::SendEditor( SCI_CANUNDO, 0, 0) != 0
      METHOD Cancel ()                               INLINE ::SendEditor( SCI_CANCEL ,0,0)
      METHOD Charleft ()                             INLINE ::SendEditor( SCI_CHARLEFT ,0,0)
      METHOD Charleftextend ()                       INLINE ::SendEditor( SCI_CHARLEFTEXTEND ,0,0)
      METHOD Charleftrectextend ()                   INLINE ::SendEditor( SCI_CHARLEFTRECTEXTEND ,0,0)
      METHOD Charright ()                            INLINE ::SendEditor( SCI_CHARRIGHT ,0,0)
      METHOD Charrightextend ()                      INLINE ::SendEditor( SCI_CHARRIGHTEXTEND ,0,0)
      METHOD Charrightrectextend ()                  INLINE ::SendEditor( SCI_CHARRIGHTRECTEXTEND ,0,0)
      METHOD ClearAll()                              INLINE ::SendEditor( SCI_CLEARALL )
      METHOD CopyLine()                              INLINE ::SendEditor( SCI_LINECOPY, 0, 0 )
      METHOD Deleteback ()                           INLINE ::SendEditor( SCI_DELETEBACK ,0,0)
      METHOD Deletebacknotline ()                    INLINE ::SendEditor( SCI_DELETEBACKNOTLINE ,0,0)
      METHOD Dellineleft ()                          INLINE ::SendEditor( SCI_DELLINELEFT ,0,0)
      METHOD Dellineright ()                         INLINE ::SendEditor( SCI_DELLINERIGHT ,0,0)
      METHOD Delwordleft ()                          INLINE ::SendEditor( SCI_DELWORDLEFT ,0,0)
      METHOD Delwordright ()                         INLINE ::SendEditor( SCI_DELWORDRIGHT ,0,0)
      METHOD DlgFindText()
      METHOD Documentend ()                          INLINE ::SendEditor( SCI_DOCUMENTEND ,0,0)
      METHOD Documentendextend ()                    INLINE ::SendEditor( SCI_DOCUMENTENDEXTEND ,0,0)
      METHOD Documentstart ()                        INLINE ::SendEditor( SCI_DOCUMENTSTART ,0,0)
      METHOD Documentstartextend ()                  INLINE ::SendEditor( SCI_DOCUMENTSTARTEXTEND ,0,0)
      METHOD Edittoggleovertype ()                   INLINE ::SendEditor( SCI_EDITTOGGLEOVERTYPE ,0,0)
      METHOD EmptyUndoBuffer()                       INLINE ::SendEditor( EM_EMPTYUNDOBUFFER )
      METHOD FindText( nFlags, ft )                  INLINE ::SendEditor( SCI_FINDTEXT, nFlags, ft )
      METHOD Formfeed ()                             INLINE ::SendEditor( SCI_FORMFEED ,0,0)
      METHOD GetCurLine ( nLength, cText )           INLINE ::SendEditor( SCI_GETCURLINE, nLength, cText )
      METHOD GetCurrentPos ()                        INLINE ::SendEditor( SCI_GETCURRENTPOS, 0, 0)
      METHOD GetCurrentStyle()
      METHOD GetLine( nLine )                        INLINE SC_GetLine( ::hWnd, nLine )
      METHOD GetLineCount ()                         INLINE ::SendEditor( SCI_GETLINECOUNT, 0, 0)
      METHOD GetModify()
      METHOD GetReadOnly()                           INLINE ::SendEditor( SCI_GETREADONLY ) != 0
      METHOD GetSelText ()                           INLINE C5GetSelText(::hWnd, ::SendEditor(SCI_GETSELECTIONEND) - ::SendEditor(SCI_GETSELECTIONSTART) )
      METHOD GetSelectionStart()                     INLINE ::SendEditor( SCI_GETSELECTIONSTART, 0, 0)
      METHOD GetText()                               INLINE SC_GetText( ::hWnd )
      METHOD GoDown()                                INLINE ::SendEditor( SCI_LINEDOWN, 0, 0 )
      METHOD GoEol()                                 INLINE ::SendEditor( SCI_LINEEND, 0, 0 )
      METHOD GoHome()                                INLINE ::SendEditor( SCI_HOME, 0, 0 )
      METHOD GoLeft()                                INLINE ::CharLeft()
      METHOD GoRight()                               INLINE ::CharRight()
      METHOD GoUp()                                  INLINE ::SendEditor( SCI_LINEUP, 0, 0 )
      METHOD GotoLine( nLine)                        INLINE ::SendEditor( SCI_GOTOLINE, nLine-1, 0)
      METHOD GotoPos(nPos)                           INLINE ::SendEditor( SCI_GOTOPOS, nPos, 0)
      METHOD Home ()                                 INLINE ::SendEditor( SCI_HOME ,0,0)
      METHOD Homedisplay ()                          INLINE ::SendEditor( SCI_HOMEDISPLAY ,0,0)
      METHOD Homedisplayextend ()                    INLINE ::SendEditor( SCI_HOMEDISPLAYEXTEND ,0,0)
      METHOD Homeextend ()                           INLINE ::SendEditor( SCI_HOMEEXTEND ,0,0)
      METHOD Homerectextend ()                       INLINE ::SendEditor( SCI_HOMERECTEXTEND ,0,0)
      METHOD Homewrap ()                             INLINE ::SendEditor( SCI_HOMEWRAP ,0,0)
      METHOD Homewrapextend ()                       INLINE ::SendEditor( SCI_HOMEWRAPEXTEND ,0,0)
      METHOD InsertText ( nPos, cText )              INLINE ::SendEditor( SCI_INSERTTEXT, nPos, cText)
      METHOD IsReadOnly()                            INLINE SC_IsReadOnly( ::hWnd )
      METHOD KeyChar( nKey, nFlags )
      METHOD KeyDown( nKey, nFlags )
      METHOD LineFromPosition( nPos)                 INLINE ::SendEditor( SCI_LINEFROMPOSITION, nPos, 0)
      METHOD LineLength( nLine )                     INLINE ::SendEditor( SCI_LINELENGTH, nLine, 0 )
      METHOD Linecopy ()                             INLINE ::SendEditor( SCI_LINECOPY ,0,0)
      METHOD Linecut ()                              INLINE ::SendEditor( SCI_LINECUT ,0,0)
      METHOD Linedelete ()                           INLINE ::SendEditor( SCI_LINEDELETE ,0,0)
      METHOD Linedown ()                             INLINE ::SendEditor( SCI_LINEDOWN ,0,0)
      METHOD Linedownextend ()                       INLINE ::SendEditor( SCI_LINEDOWNEXTEND ,0,0)
      METHOD Linedownrectextend ()                   INLINE ::SendEditor( SCI_LINEDOWNRECTEXTEND ,0,0)
      METHOD Lineduplicate ()                        INLINE ::SendEditor( SCI_LINEDUPLICATE ,0,0)
      METHOD Lineend ()                              INLINE ::SendEditor( SCI_LINEEND ,0,0)
      METHOD Lineenddisplay ()                       INLINE ::SendEditor( SCI_LINEENDDISPLAY ,0,0)
      METHOD Lineenddisplayextend ()                 INLINE ::SendEditor( SCI_LINEENDDISPLAYEXTEND ,0,0)
      METHOD Lineendextend ()                        INLINE ::SendEditor( SCI_LINEENDEXTEND ,0,0)
      METHOD Lineendrectextend ()                    INLINE ::SendEditor( SCI_LINEENDRECTEXTEND ,0,0)
      METHOD Lineendwrap ()                          INLINE ::SendEditor( SCI_LINEENDWRAP ,0,0)
      METHOD Lineendwrapextend ()                    INLINE ::SendEditor( SCI_LINEENDWRAPEXTEND ,0,0)
      METHOD Linescrolldown ()                       INLINE ::SendEditor( SCI_LINESCROLLDOWN ,0,0)
      METHOD Linescrollup ()                         INLINE ::SendEditor( SCI_LINESCROLLUP ,0,0)
      METHOD Linetranspose ()                        INLINE ::SendEditor( SCI_LINETRANSPOSE ,0,0)
      METHOD Lineup ()                               INLINE ::SendEditor( SCI_LINEUP ,0,0)
      METHOD Lineupextend ()                         INLINE ::SendEditor( SCI_LINEUPEXTEND ,0,0)
      METHOD Lineuprectextend ()                     INLINE ::SendEditor( SCI_LINEUPRECTEXTEND ,0,0)
      METHOD Lowercase ()                            INLINE ::SendEditor( SCI_LOWERCASE ,0,0)
      METHOD MarkerAdd( nLine,  nMarkerNumber)       INLINE ::SendEditor( SCI_MARKERADD, nLine, nMarkerNumber)
      METHOD MouseMove( nRow, nCol, nKeyFlags )      INLINE CallWindowProc( ::nOldProc, ::hWnd, WM_MOUSEMOVE, nKeyFlags, nMakeLong( nCol, nRow ) )
      METHOD NewLine ()                              INLINE ::SendEditor( SCI_NEWLINE, 0, 0)
      METHOD Open()
      METHOD OpenFile( cFileName )
      METHOD OptionSetFont()
      METHOD Pagedown ()                             INLINE ::SendEditor( SCI_PAGEDOWN ,0,0)
      METHOD Pagedownextend ()                       INLINE ::SendEditor( SCI_PAGEDOWNEXTEND ,0,0)
      METHOD Pagedownrectextend ()                   INLINE ::SendEditor( SCI_PAGEDOWNRECTEXTEND ,0,0)
      METHOD Pageup ()                               INLINE ::SendEditor( SCI_PAGEUP ,0,0)
      METHOD Pageupextend ()                         INLINE ::SendEditor( SCI_PAGEUPEXTEND ,0,0)
      METHOD Pageuprectextend ()                     INLINE ::SendEditor( SCI_PAGEUPRECTEXTEND ,0,0)
      METHOD Paradown ()                             INLINE ::SendEditor( SCI_PARADOWN ,0,0)
      METHOD Paradownextend ()                       INLINE ::SendEditor( SCI_PARADOWNEXTEND ,0,0)
      METHOD Paraup ()                               INLINE ::SendEditor( SCI_PARAUP ,0,0)
      METHOD Paraupextend ()                         INLINE ::SendEditor( SCI_PARAUPEXTEND ,0,0)
      METHOD Print()
      METHOD Redo()                                  INLINE ::SendEditor( SCI_REDO, 0, 0)
      METHOD ReplaceSel( cText )                     INLINE ::SendEditor( SCI_REPLACESEL, 0, cText )
      METHOD Save()
      METHOD SayMemo()
      METHOD SearchNext ( nFlags, cText)             INLINE ::SendEditor( SCI_SEARCHNEXT, nFlags, cText)
      METHOD SearchPrev ( nFlags, cText)             INLINE ::SendEditor( SCI_SEARCHPREV, nFlags, cText)
      METHOD SendAsEmail()
      METHOD SendEditor( Msg, wParam, lParam )
      METHOD SetFixedFont()
      METHOD SetReadOnly( lOn )                      INLINE ::SendEditor( SCI_SETREADONLY, if( lOn, 1, 0 ), 0 )
      METHOD SetSavePoint()                          INLINE ::SendEditor( SCI_SETSAVEPOINT )
      METHOD SetSel ( nStart,  nEnd )                INLINE ::SendEditor( SCI_SETSEL, nStart, nEnd )
      METHOD SetText( cText )                        INLINE ::SendEditor( SCI_SETTEXT, 0, cText )
      METHOD SetUndoCollection()                     INLINE ::SendEditor( SCI_SETUNDOCOLLECTION )
      METHOD Stutteredpagedown ()                    INLINE ::SendEditor( SCI_STUTTEREDPAGEDOWN ,0,0)
      METHOD StutteredpagedownextenD ()              INLINE ::SendEditor( SCI_STUTTEREDPAGEDOWNEXTEND ,0,0)
      METHOD Stutteredpageup ()                      INLINE ::SendEditor( SCI_STUTTEREDPAGEUP ,0,0)
      METHOD Stutteredpageupextend ()                INLINE ::SendEditor( SCI_STUTTEREDPAGEUPEXTEND ,0,0)
      METHOD StyleSetBold ( nStyle,  bold )
      METHOD StyleSetFont ( nStyle, cFontName)
      METHOD StyleSetFore ( nStyle, fore)
      METHOD StyleSetItalic ( nStyle,  italic)
      METHOD StyleSetSize ( nStyle,  nSizePoints)
      METHOD StyleSetUnderline ( nStyle,  underline)
      METHOD Tab ()                                  INLINE ::SendEditor( SCI_TAB ,0,0)
      METHOD Undo()                                  INLINE ::SendEditor( SCI_UNDO, 0, 0)
      METHOD Uppercase ()                            INLINE ::SendEditor( SCI_UPPERCASE ,0,0)
      METHOD Vchome ()                               INLINE ::SendEditor( SCI_VCHOME ,0,0)
      METHOD Vchomeextend ()                         INLINE ::SendEditor( SCI_VCHOMEEXTEND ,0,0)
      METHOD Vchomerectextend ()                     INLINE ::SendEditor( SCI_VCHOMERECTEXTEND ,0,0)
      METHOD Vchomewrap ()                           INLINE ::SendEditor( SCI_VCHOMEWRAP ,0,0)
      METHOD Vchomewrapextend ()                     INLINE ::SendEditor( SCI_VCHOMEWRAPEXTEND ,0,0)
      METHOD Wordleft ()                             INLINE ::SendEditor( SCI_WORDLEFT ,0,0)
      METHOD Wordleftend ()                          INLINE ::SendEditor( SCI_WORDLEFTEND ,0,0)
      METHOD Wordleftendextend ()                    INLINE ::SendEditor( SCI_WORDLEFTENDEXTEND ,0,0)
      METHOD Wordleftextend ()                       INLINE ::SendEditor( SCI_WORDLEFTEXTEND ,0,0)
      METHOD Wordpartleft ()                         INLINE ::SendEditor( SCI_WORDPARTLEFT ,0,0)
      METHOD Wordpartleftextend ()                   INLINE ::SendEditor( SCI_WORDPARTLEFTEXTEND ,0,0)
      METHOD Wordpartright ()                        INLINE ::SendEditor( SCI_WORDPARTRIGHT ,0,0)
      METHOD Wordpartrightextend ()                  INLINE ::SendEditor( SCI_WORDPARTRIGHTEXTEND ,0,0)
      METHOD Wordright ()                            INLINE ::SendEditor( SCI_WORDRIGHT ,0,0)
      METHOD Wordrightend ()                         INLINE ::SendEditor( SCI_WORDRIGHTEND ,0,0)
      METHOD Wordrightendextend ()                   INLINE ::SendEditor( SCI_WORDRIGHTENDEXTEND ,0,0)
      METHOD Wordrightextend ()                      INLINE ::SendEditor( SCI_WORDRIGHTEXTEND ,0,0)
      METHOD nLine()                                 INLINE ::LineFromPosition( ::GetCurrentPos() )+1
      METHOD nPos( nNewVal )                         SETGET

      METHOD SetAStyle( style, fore, back, size, face )
      METHOD Prueba()
      METHOD Notify( nIdCtrl, nPtrNMHDR )



ENDCLASS

/*********************************************************************/
      METHOD SendEditor( Msg, wParam, lParam ) CLASS TScintilla
/*********************************************************************/

DEFAULT wParam := 0
DEFAULT lParam := 0

return SendMessage( ::hWnd, Msg, wParam, lParam )


/*********************************************************************/
      METHOD End() CLASS TScintilla
/*********************************************************************/

if ::nInst == 0
   FreeLibrary( ::hLib )
endif

return Super:End()


/*********************************************************************/
      METHOD nPos( nNewVal ) CLASS TScintilla
/*********************************************************************/

      if pcount() > 0
         ::GotoPos( nNewVal )
      endif

      return ::GetCurrentPos()



/*********************************************************************/

METHOD New( nRow, nCol, nWidth, nHeight, oWnd ) CLASS TScintilla

DEFAULT nRow := 0, nCol := 0, nWidth := 100, nHeight := 100

   ::nTop     = nRow
   ::nLeft    = nCol
   ::nBottom  = nRow + nHeight
   ::nRight   = nCol + nWidth
   ::oWnd     = oWnd
   ::nStyle   = nOR( WS_CHILD, WS_VISIBLE, WS_TABSTOP, WS_BORDER, WS_VSCROLL, WS_HSCROLL  )
   ::nId       = ::GetNewId()
   ::cFileName = "Noname"

   //::SetColor( 0, CLR_WHITE )
   // DEFINE BRUSH ::oBrush STYLE "NULL"

   if ::nInst == 0
      ::hLib := LoadLibrary( "SciLexer.DLL" )
      ::nInst ++
   endif

   //::Register( nOR( CS_VREDRAW, CS_HREDRAW ) )

   if ! Empty( oWnd:hWnd )
      ::Create("Scintilla")
      ::Default()
      oWnd:AddControl( Self )
   else
      oWnd:DefControl( Self )
   endif

   ::aCopys := {}

   SendMessage( ::hWnd, SCI_SETMARGINWIDTHN, 0, 35 )
   ::SendEditor(SCI_SETMARGINWIDTHN, 1, 30)
   //::SendEditor(SCI_SETMARGINTYPEN, 1, SC_MARGIN_NUMBER)
   ::SendEditor(SCI_SETFOLDFLAGS, 16, 0)
   //::SendEditor( SCI_SETPROPERTY, "fold", "1")
   ::SendEditor( SCI_SETMARGINWIDTHN, 2, 25)
   ::SendEditor( SCI_SETMARGINTYPEN, 2, SC_MARGIN_SYMBOL)
   ::SendEditor( SCI_SETMARGINMASKN, 2, SC_MASK_FOLDERS)
   ::SendEditor( SCI_SETMODEVENTMASK, SC_MOD_CHANGEFOLD, 0)
   ::SendEditor( SCI_SETMARGINSENSITIVEN, 2, 1)
   ::SendEditor( SCI_MARKERDEFINE, SC_MARKNUM_FOLDEROPEN, SC_MARK_ARROWDOWN)
   ::SendEditor( SCI_MARKERSETFORE, SC_MARKNUM_FOLDEROPEN,50000)
   ::SendEditor( SCI_MARKERSETBACK, SC_MARKNUM_FOLDEROPEN, 0)
   ::SendEditor( SCI_MARKERDEFINE, SC_MARKNUM_FOLDER, SC_MARK_ARROW)
   ::SendEditor( SCI_MARKERSETFORE, SC_MARKNUM_FOLDER, 50000)
   ::SendEditor( SCI_MARKERSETBACK, SC_MARKNUM_FOLDER, 0)
   ::SendEditor( SCI_SETINDENTATIONGUIDES, 1, 0)
   ::SendEditor( SCI_SETHIGHLIGHTGUIDE, 30, 0)

   ::SetFixedFont()
   ::SetSavePoint()

   ::SetColor( 0, RGB( 222,222,222) )
   ::Prueba()

return Self

*********************************************************************************************************************************

METHOD SetColor( nClrText, nClrPane ) CLASS TScintilla

   ::SendEditor( SCI_STYLESETFORE, STYLE_DEFAULT, nClrText )
   ::SendEditor( SCI_STYLESETBACK, STYLE_DEFAULT, nClrPane )

return nil

*********************************************************************************************************************************
   METHOD Open() CLASS TScintilla
*********************************************************************************************************************************
local cFileName

cFileName := cGetFile("*.prg", "Seleccione fichero prg")

if !file( cFileName )
   return .f.
endif

::OpenFile( cFileName )

::oWnd:cTitle := "Med - [" + cFileName + "]"

::SetFixedFont()


return nil

METHOD Default() CLASS TScintilla

   local cSintax := "aadd abrwposrec2 abs achoice aclone3 acopy addfontresource adel adir adrives aeval afields afill afindfile agetworkareas ains alert alias alltrim altd amididevices ansilower ansitooem ansiupper aodata appendmenu arc aread arg array asave asc asend asize asort at atail atcbrwposrec atreebmps auxgetcaps auxgetdev auxgetvol auxsetvol b2bin baradjust barinvert barpaint beginpaint bin2d bin2i bin2l bin2w bindtoport bitblt blobdirectget blobdirectimport blobdirectput blobexport blobget blobimport blobrootget blobrootlock blobrootput blobrootunlock bof break bringwindo browse btndisable btnpaint buildcommdcb calldll calldll32 callwindowproc cargv cchr2data cctrl2chr cdlg2chr cdow cfiledisk cfileext cfilemask cfilename cfilenoext cfilepath cfilesubdir cfreadline cgetdir cgetdir32 cgetexpression cgetfile cgetfile32 cgetnewalias changeproc checkmenu childwindo choosecolor choosefont chord chr classcreat clientip clienttoscreen closeclipboard closecomm closemetafile closesocket closewindow closezipfile cmdistruct cmimedec cmimeenc cmonth cnewfilename cntxkey col colorselect colorsqty cputype createcare createcdc createdc createdlgindirect createfont createhatch createmenu createoleobject createpattern createpen createpopupmenu createsolidbrush createwindow crestostr cstrword ctempfile ctl3dlook ctod ctrldrawfo curdir curdrive cursor cursorarrow cursorcatch cursorhand cursoribeam cursorns cursorsize cursorwait cursorwe cvaltochar d2bin date day dbappend dbclearfilter dbclearindex dbclearrelation dbcloseall dbclosearea dbcommit " //+;
                 //"dbcommitall dbcreate dbcreateindex dbcretein dbdelete dbedit dbeval dbf dbfcdx dbfcdxax dbfieldinfo dbfileget dbfileput dbfilter dbfntx dbgobottom dbgoto dbgotop dbinfo dborderinfo dbpack dbpx dbrecall dbrecordinfo dbreindex dbrelation dbrlock dbrlocklist dbrselect dbrunlock dbseek dbselectarea dbsetdefa dbsetdriver dbsetfilter dbsetindex dbsetorder dbsetrelation dbskip dbstruct dbunlock dbunlockall dbusearea dbzap ddeaccessdata ddeack ddeclientt ddecmpstri ddecommand ddeconnect ddedisconn ddefreestr ddegetcommand ddegetdata ddeinitial ddequeryst ddeterminate ddeuniniti decrypt defwindowp deldbfmdx deleted deletedc deletemeta deleteobject delinientr delinisect delresource delwndbrus descend destroycursor destroyico destroymenu destroywindow devmode devout devoutpict devpos dialogboxindirect dibdraw dibfrombitmap dibheight dibpalette dibread dibwidth dibwrite dirchange directory dirmake dirremove diskchange diskname diskspace dispbegin dispbox dispend dispout ditbackgrd dlgfindtext doserror dotsadjust dow dptolp draftmode dragaccept dragfinish dragquerypoint drawbitmap drawfocusr drawgrayed drawgrid drawicon drawmasked drawmenuba drawmsgitem drawtext dtoc dtos duprecord editcell ellipse empty emptyclipboard enablecomm enablemenu enablewindow encrypt enddialog enddoc endmonitor endpage endpaint enumfontfa eof errorblock errorlevel escape escapecomm eval existwnd exitwindowsexec exp extfloodfi extracticon exttextout fattrib fclose fcount fcreate ferase ferror ffmimedec ffmimeenc fieldblock fieldget fieldpos fieldput fieldtype "+;
                 //"fieldwblock file fillevent fillrect findexecut findresource findtext findwindow fklabel fkmax flock floodfill flushcomm fmimedec fmimeenc foldpaint fopen found fread freadstr freelib32 freelibrary frename fseek fsize fwbitmap fwbrushes fwrite gellipse getactive getactivewindow getapplykey getasynckey getbkcolor getcapture getcaretpos getclassname getclientrect getclpdata getcommerror getcoors getcpu getctrlid getcurdir getcursorpos getdatas getdc getdesktopwindow getdevicecaps getdialogbaseunits getdlgbase getdlgitem getdosetkey getdrawite getdrawmenu getdropinfo getenv getfirstinzip getfocus getfontinfo getframeproc getfreefil getfreespace getftime getgridsize gethelpfile gethelptopic gethostbyname gethostname gethwnd32 getinstance getip getkeystat getkeytoggle getlocal getmapmode getmdichlp getmeaitem getmenustate getmetabit getmetafile getmitemid getmodulefilename getnextinzip getnumtask getordnames getparam getparent getpeername getpixel getport getpostvalidate getprevalidate getprinter getproc32 getprocaddress getprofint getprofstr getprop getpvpprofstring getquery getreader getresources getscrollpos getservbyname getstockobject getsubmenu getsyscolor getsysdir getsysmetrics getsystemmenu gettasks gettextalign gettextcolor gettextheight gettextwidth gettickcount getversion getwindir getwindowword getwinflags getwintxtlength getwndapp getwndframe getwndrect getwndtask gfnterase gfntload gfntset gframe ggetpixel gline globaladdatom globalalloc globalcompact globaldata globalfree globalgeta globallock globalrealloc globalsize "+;
                 //"gmode gpolygon gputpixel grect gsetclip gsetexcl gsetpal gwriteat hardcr hasresources header helpindex helppopup helpsearch helptopic hextodec hidecaret hilimenuitem htons i2bin if iif indexext indexkey indexord inet_address inkey inporbyte insertmenu int interruptunregister invalidaterect invertrect isalpha isansi isansilower isansiupper iscdrom ischild iscolor isdefbutton isdigit isdiskette isiconic islower ismenu isoem isoverwnd isprinter isupper iswin95 iswindowvisible iswinnt iszip iszoomed joygetdevcaps joygetnumdevs joygetthreshold joysetcapture joysetthre keyfast keytoggle killtimer l2bin land largefonts lastmenu lastrec lbxdrawitem lbxgetitem lbxgetselitems lbxmeasure lchdir lclose lcreat left len lfn2sfn lgettextline lineto lisdir listen llfnmkdir llfnrmdir lmdiiexist lmidioutopen lmkdir loadaccelerators loadbitmap loadcursor loadicon loadlib32 loadlibrary loadmenu loadresource loadstring loadvalue localshrink log logevent logfile logstatics lopen lower lptodp lrmdir lsaveobject ltrim lwrunning lxor lzcopyfile makewin max maxcol maxrow mcigeterrorstring mcisendcommand mcisendstring mcol mdblclk mdictrladjust mdirecedit measureitem memoedit memoline memoread memory memosetsuper memotran memowrit memstat memvarblock menubegin menudrawitem menuend menumeasureitem menumodal messagebox meterpaint mgetcreate mgetline mgetreplace mhide midinoteon min mlcount mlctopos mleftdown mlpos mod modifymenu month moreheap moveget moveto movewindow mpostolc mpresent mreststate mrightdown mrow msavestate msetbounds msetclip msetcursor "+;
                 //"msetpos msgabout msgalert msgbeep msgdate msgget msginfo msglist msglogo msgmeter msgnoyes msgpaint msgretrycancel msgrun msgsound msgstop msgtoolbar msgwait msgyesno mshow mstate nand nargc nbmpheight ncolorton ndbl2flt nddesharesetinfo ndlgbox nextdlgtabitem nextmem nfilecrc ngetbackrgb ngetforergb nhex nicons nmciopen nmciplay nmciwindow nmididevices nmsgbox nnot nor nrandom nrgb nrgbblue nrgbgreen nrgbred nseriala nserialhd nstrcrc nstrhash ntcwrow ntxpos ntxtlines nwindows nwndchrheight nwrow nwrows nxor oclone oemtoansi openclipboard opencomm oread osend outportbyte outpudebugstring paint3d palbmpdraw palbmpload palbmpread palbtnpain paramcount pbmpcolors pbmpheigh pbmpwidth peekbyte peekmessage peekword pie playmetafile pokebyte pokeword polypolygon postmessage postquitmessage printeresc printerini printersetup prnbinsource prngetdriver prngetname prngetorientation prngetport prngetsize prnlandscape prnoffset prnportrait prnsetcopies prnsetpage prnsetsize raconst radial raenumconnections raenumentries ragetconst rageterror rahangup ras_dialentry readbitmap readcomm readeven readvar realizepalette rectangle rectdotted recv regclosekey regcreatekey regdeletekey regenumkey registerclass regopenkey regqueryvalue regsetvalue releasecapture releasedc removefont removemenu removeprop report resetdc resourcefree restoredc restproc rlnew rpreview rptaddcolumn rptaddgroup rptbegin rptend savedc say3d scan screentoclient scrollwindow selectobject selectpalette sendbinary sendmessage serverip set3dlook setactivewindow setbkcolor "+;
                 //"setbkmode setblackpen setbrushorg setcapture setcaretpos setclassword setclipboarddata setclpdata setcommstate setcurdrive setcursor setdate setdeskwallpaper setdropinfo setfocus setftime setgridsize sethandlecount setidleaction setmapmode setmenu setminmax setmultiple setparent setpixel setpolyfillmode setprop setresources setsockopt settextalign settextcolor settextjustification settime settimer setvieworg setviewportext setwhitepen setwin95look setwindowtext setwnddefault shellabout shellexecute showcaret showcursor showwindow sndplayres sndplaysound socket socketselect spoolfile startdoc startmonitor startpage startplayback startrecord stopplayback stoprecord strbyte strcapfirst strchar strcpy strtoken symname symstat symtblat symtbllen sysrefresh systime syswait tabctrladd tabspaint tcbrwscrol tcdrawcell terminateapp textout thisstruct time timercount timerevent trackpopupmenu treebegin treeend tvinsertitem uchartoval uloadstruct unescape unzipfile updatewindow uvalblank virtualrdd waitrun wbrwline wbrwpane wbrwscroll wbrwselbox windowfrompoint winexec winhelp winuser wndadjbottom wndadjcliente wndadjleft wndadjright wndadjtop wndbitmap wndbottom wndbox wndboxin wndboxraised wndbrush wndcenter wndcopy wndhasscrolls wndheight wndhlineraised wndhraised wndinset wndleft wndmain wndprint wndraised wndsetsize wndtop wndvlineraised wndvraised wndwidth wnetaddconnection wnetbrowse wnetconnectdialog wnetdisconnectdialog wneterror wnetgeterrortext wnetgetuser worksheet writecomm writepprostring wrtieprofstring wsaasyncselect "+;
                 //"wsacleanup wsagetlasterror wsastartup wsay wsayrect wscroll xpadc xpadl xpadr zipblock zipfile zipmsg zipname zipsize ziptype "                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      */
/*
   SendMessage( ::hWnd,SCI_SETKEYWORDS, 0, cSintax )

   SendMessage( ::hWnd,SCI_STYLESETFORE, SCE_HJ_KEYWORD, rgb(255,0,0))
   SendMessage( ::hWnd,SCI_STYLESETBACK, SCE_HJ_KEYWORD, rgb(255,255,255))
*/

return ""



*********************************************************************************************************************************
   METHOD Save() CLASS TScintilla
*********************************************************************************************************************************
local hMani
local cFile

if empty( ::cFileName ) .or. !file( ::cFileName )
   cFile := cGetFile( , "Salvar", 0, hb_CurDrive() + ":\" + CurDir(), .t., .t.)
   ::cFileName := cFile
endif

hMani := Fcreate( ::cFileName )
fwrite( hMani, ::GetText() )
fclose( hMani )
::cTitle := "Med - [" + ::cFileName + "]"


return nil

METHOD OpenFile( cFileName ) CLASS TScintilla

   local cStr := MemoRead( cFileName )

   ::SetText( cStr )
   ::cFilename = cFileName

   if AScan( ::aMrus, cFileName ) == 0
      AAdd( ::aMrus, cFileName )
   endif

   // AddFile( cFileName )

return nil //SCI_OpenFile( ::hWnd, cFileName )
/*

*********************************************************************************************************************************
      METHOD GetTextRange( nLin0, nCol0, nLin1, nCol1  ) CLASS TScintilla
*********************************************************************************************************************************
DEFAULT nLin0 := 1
DEFAULT nCol0 := 1
DEFAULT nLin1 := -1
DEFAULT nCol1 := -1

return ::SC_GetTextRange( ::hWnd, nLin0, nCol0, nLin1, nCol1 )
*/

#define CFACENAME 14
#define ALTURA    1
#define BOLD      5
#define ITALIC    6
#define UNDERLINE 7

*********************************************************************************************************************************
  METHOD OptionSetFont() CLASS TScintilla
*********************************************************************************************************************************
local oFont
LOCAL aFont

DEFINE FONT oFont FROM USER


if abs(oFont:nInpHeight ) < 5
   MsgStop( "Operación cancelada" )
   return nil
endif

::StyleSetFont      (::GetCurrentStyle(), oFont:cFaceName )
::StyleSetSize      (::GetCurrentStyle(), abs(oFont:nSize) )
::StyleSetBold      (::GetCurrentStyle(), oFont:lBold  )
::StyleSetItalic    (::GetCurrentStyle(), oFont:lItalic )
::StyleSetUnderline (::GetCurrentStyle(), oFont:lUnderline )

oFont:End()

return nil

*********************************************************************************************************************************
   METHOD GetCurrentStyle() CLASS TScintilla
*********************************************************************************************************************************
local nPos := ::SendEditor(SCI_GETCURRENTPOS, 0, 0)

return ::SendEditor(SCI_GETSTYLEAT, nPos, 0)

**********************************************************************************************
 METHOD StyleSetFont( nStyle, cFontName ) CLASS TScintilla
**********************************************************************************************

return ::SendEditor( SCI_STYLESETFONT, nStyle, cFontName)

**********************************************************************************************
 METHOD StyleSetFore( nStyle, fore) CLASS TScintilla
**********************************************************************************************
return ::SendEditor( SCI_STYLESETFORE, nStyle, fore)

**********************************************************************************************

METHOD StyleSetBold( nStyle, bold ) CLASS TScintilla

return ::SendEditor( SCI_STYLESETBOLD, nStyle, bold )

**********************************************************************************************

METHOD StyleSetItalic( nStyle, italic ) CLASS TScintilla

return ::SendEditor( SCI_STYLESETITALIC, nStyle, italic )

**********************************************************************************************

METHOD StyleSetSize( nStyle, nSizePoints ) CLASS TScintilla

return ::SendEditor( SCI_STYLESETSIZE, nStyle, nSizePoints )

**********************************************************************************************

METHOD StyleSetUnderline( nStyle, underline ) CLASS TScintilla

return ::SendEditor( SCI_STYLESETUNDERLINE, nStyle, underline )

**********************************************************************************************

METHOD SetFixedFont() CLASS TScintilla

   ::StyleSetFont( ::GetCurrentStyle(), "Courier New" )
   ::StyleSetSize( ::GetCurrentStyle(), 12 )
   ::StyleSetBold( ::GetCurrentStyle(), .F.  )
   ::StyleSetItalic( ::GetCurrentStyle(), .F. )
   ::StyleSetUnderline( ::GetCurrentStyle(), .F. )

return nil

**********************************************************************************************
 METHOD GetModify() CLASS TScintilla
**********************************************************************************************

return ::SendEditor( SCI_GETMODIFY, 0, 0) != 0


**********************************************************************************************
METHOD Print() CLASS TScintilla
**********************************************************************************************

     LOCAL nRecno, oFont
     local o := self

     DEFINE FONT oFont NAME "Courier New" SIZE 0,-12
            // Font sizes for PRINTING are given in "points" not pixels.
            // (Pixels are used for font width and height for SCREENS only.)
            // By using a "0" for width and a "-" in front of the "height" #
            // we tell FiveWin that we're using points instead of pixels.

            // Thus -12 means "12 point," which is used for "10 pitch"
            // non-proportionally spaced Courier type that prints at
            // 6 lines/inch.

            // -10 means a 10 point font printing at 7 lines/inch.

            // Use -9 for a "12 pitch" equal-spaced Courier font printing
            // at 8 lines per inch.


            // Note that in creating the report object, we are leaving out
            // any mention of title or header specs. because those are
            // already included in our .TXT file.
     REPORT oReport ;
          FONT oFont ;
          PREVIEW ;
          CAPTION "Text File Printout"
          //;          TO PRINTER


     COLUMN DATA " " SIZE 76  // * Trick "Data" - we're fooling Mother
                              // Nature here. The memo will go into the " ". *

     END REPORT

             // All title lines, page numbers and headings already exist in
             // our text file, so the next two code statements make sure that
             // FiveWin won't add its own title lines.
     oReport:nTitleUpLine := RPT_NOLINE
     oReport:nTitleDnLine := RPT_NOLINE
     oReport:Margin(.15,RPT_LEFT,RPT_INCHES)
     oReport:Margin(.25,RPT_TOP,RPT_INCHES)
     oReport:Margin(.25,RPT_BOTTOM,RPT_INCHES)
     // I know the top/bottom margins shown here should mathematically cause
     // more than the desired 60 lines per page to print. However, in actual
     // practice with my Panasonic KXP 4450 laser printer emulating the
     // HP LaserJet Plus, this is what I had to use to get 60 lines.  Why?
     // Inscrutible printer driver!  Maybe your printer driver functions in
     // a more mathematically logical fashion.  If so, adjust accordingly.
     // The left margin is set so small here because a margin is already
     // built into the text file itself (in this particular case).

     ACTIVATE REPORT oReport ON INIT o:SayMemo()

     oFont:End()

RETURN NIL

*------------------------

 METHOD SayMemo() CLASS TScintilla

     LOCAL cText, cLine
     LOCAL nFor, nLines, nPageln
     cText := ::GetText()
     nLines := ::GetLineCount()
     nPageln := 0
*     oReport:BackLine(1)     // Not needed here. If used, will cause printing
                              // of subsequent pages to get out of synch by
                              // pushing the start of printing down 1 line
                              // per page.

     FOR nFor := 1 TO nLines

          cLine := ::GetLine( nFor )
          cLine := substr( cLine, 1, len( cLine ) -2 )
          cLine := strtran( cLine, chr(9),"   " )
          cLine := strtran(str(nFor,5)," ","0") + "  " + cLine

          oReport:StartLine()
          oReport:Say(1,cLine)
          oReport:EndLine()

             // The following section checks to see if we've reached the
             // bottom of the page (60 lines). If so, it then calls
             // GetTop() to eliminate empty spaces in the text file between
             // the bottom of the outgoing page and the top line of the
             // next page.  The intent of this code is to get rid of the
             // empty lines that most report generators insert between pages
             // when output is to a text file -- otherwise our page printing
             // would get out of synch with the formating of the original
             // report. This approach only works where printing (including the
             // page number and other page heading data) is supposed to appear
             // at the same place at the top of every page.
          nPageln := nPageln + 1
          IF nPageln = 60
             nFor := GetTop(cText,nFor,nLines)
             nPageln := 0
          ENDIF

     NEXT

*    oReport:Newline()  // Only activate this line if you need to have the
                        // program eject another page upon completing printing.

RETURN NIL

*----------------------

STATIC FUNCTION GetTop(cText,nFor,nLines)
LOCAL Test := .T.,cLine
DO WHILE Test = .T. .AND. nFor <= nLines
   nFor := nFor + 1
   cLine := MemoLine(cText, 76, nFor)
   TEST := EMPTY(cLine)
ENDDO
nFor := nFor - 1
SysRefresh()   // Inserted to allow Windows to catch up with housekeeping
               // that was held up during the "DO WHILE."
RETURN nFor
*----------------------

function SetLastFind( c )
cLastFind := c
return c


****************************************************************************************************
  METHOD DlgFindText( ) CLASS TScintilla
****************************************************************************************************

local oDlg, oGet
local cText := ::GetSelText()
local oClp

if empty( cText )

    DEFINE CLIPBOARD oClp OF Self FORMAT TEXT

    if oClp:Open()
       cText := oClp:GetText()
    endif
    oClp:End()

    if empty( cText )
       cText := if( empty(cLastFind),space(1), cLastFind )
    endif

endif

if mlcount( cText ) > 1
   cText := trim(memoline(cText,,1))
endif


@ 2, 2 GET oGet VAR cText SIZE 100, 25
oGet:Hide()

oDlg := DlgFindText( cText,oGet, {|cText| .t. }, Self )

return nil


#define VK_CTRL_F 6
#define VK_CTRL_K 11
#define VK_CTRL_DOT 190

****************************************************************************************************
METHOD KeyChar( nKey, nFlags ) CLASS TScintilla
****************************************************************************************************

::cTitle := "keychar" +str(nKey)
do case
   case nKey == VK_CTRL_F
        ::DlgFindText()
        return 1
endcase

return super:KeyChar( nKey, nFlags )


****************************************************************************************************
METHOD KeyDown( nKey, nFlags ) CLASS TScintilla
****************************************************************************************************
local lControl := GetKeyState( VK_CONTROL )
local lShift := GetKeyState( VK_SHIFT )
local n

::cTitle := "keydown" +str(nKey)

do case
   case nKey == VK_CTRL_DOT
        ::DlgFindText()
        return 1

   case nKey == VK_UP .and. lControl

        ::cLineBuffer := ::GetLine( ::nLine() )

        return 1

      case nKey == VK_DOWN .and. lControl

        if !empty( ::cLineBuffer )
           n := ::GetCurrentPos()
           ::SendEditor(SCI_HOME,0,0)
           ::InsertText(::GetCurrentPos(),::cLineBuffer)
           ::SetSel(n,n)
           ::GoLeft()
           ::GoRight()
        endif

        return 1

    case nKey == VK_NEXT

         ::PageDown()
         return 1

    case nKey == VK_PRIOR

         ::PageUp()
         return 1

endcase

return super:KeyDown( nKey, nFlags )
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Scintilla
Posted: Tue Feb 28, 2012 12:42 PM
scintila.prg (parte 2)
Code (fw): Select all Collapse
*****************************************************************************************************
   METHOD SendAsEmail( lAttach ) CLASS TScintilla
*****************************************************************************************************

   local oMail
   DEFAULT lAttach := .f.

   if lAttach
      DEFINE MAIL oMail ;
         SUBJECT "Envio de fichero" ;
         TEXT ::cFileName ;
         FILES ::cFileName,::cFileName ;
         FROM USER ;
         RECEIPT
   else
      DEFINE MAIL oMail ;
         SUBJECT "Envio de fichero" ;
         TEXT ::GetText() ;
         FROM USER ;
         RECEIPT
   endif
   ACTIVATE MAIL oMail



return nil











METHOD SetAStyle( style, fore, back, size, face ) CLASS TScintilla

DEFAULT size := 0
DEFAULT face := ""
DEFAULT back := CLR_WHITE


    ::SendEditor( SCI_STYLESETFORE, style, fore )
    ::SendEditor( SCI_STYLESETBACK, style, back )
    if size >= 1
        ::SendEditor( SCI_STYLESETSIZE, style, size )
    endif
    if !empty( face )
        ::SendEditor( SCI_STYLESETFONT, style, face )
    endif

return nil


METHOD Prueba() CLASS TScintilla


local htmlKeyWords
local c1 := "aadd abrwposrec2 abs achoice aclone3 acopy addfontresource adel adir adrives aeval afields afill afindfile agetworkareas ains alert "    +;
    "alias alltrim altd amididevices ansilower ansitooem ansiupper aodata appendmenu arc aread arg array asave asc asend asize asort at "    +;
    "atail atcbrwposrec atreebmps auxgetcaps auxgetdev auxgetvol auxsetvol b2bin baradjust barinvert barpaint beginpaint bin2d bin2i bin2l "    +;
    "bin2w bindtoport bitblt blobdirectget blobdirectimport blobdirectput blobexport blobget blobimport blobrootget blobrootlock "    +;
    "blobrootput blobrootunlock bof break bringwindo browse btndisable btnpaint buildcommdcb calldll calldll32 callwindowproc cargv "    +;
    "cchr2data cctrl2chr cdlg2chr cdow cfiledisk cfileext cfilemask cfilename cfilenoext cfilepath cfilesubdir cfreadline cgetdir cgetdir32 "    +;
    "cgetexpression cgetfile cgetfile32 cgetnewalias changeproc checkmenu childwindo choosecolor choosefont chord chr classcreat clientip "    +;
    "clienttoscreen closeclipboard closecomm closemetafile closesocket closewindow closezipfile cmdistruct cmimedec cmimeenc cmonth "    +;
    "cnewfilename cntxkey col colorselect colorsqty cputype createcare createcdc createdc createdlgindirect createfont createhatch "
local c2 := "createmenu createoleobject createpattern createpen createpopupmenu createsolidbrush createwindow crestostr cstrword ctempfile ctl3dlook "    +;
    "ctod ctrldrawfo curdir curdrive cursor cursorarrow cursorcatch cursorhand cursoribeam cursorns cursorsize cursorwait cursorwe "    +;
    "cvaltochar d2bin date day dbappend dbclearfilter dbclearindex dbclearrelation dbcloseall dbclosearea dbcommit dbcommitall dbcreate "  +;
    "dbcreateindex dbcretein dbdelete dbedit dbeval dbf dbfcdx dbfcdxax dbfieldinfo dbfileget dbfileput dbfilter dbfntx dbgobottom dbgoto "    +;
    "dbgotop dbinfo dborderinfo dbpack dbpx dbrecall dbrecordinfo dbreindex dbrelation dbrlock dbrlocklist dbrselect dbrunlock dbseek "+;
    "dbselectarea dbsetdefa dbsetdriver dbsetfilter dbsetindex dbsetorder dbsetrelation dbskip dbstruct dbunlock dbunlockall dbusearea "+;
    "dbzap ddeaccessdata ddeack ddeclientt ddecmpstri ddecommand ddeconnect ddedisconn ddefreestr ddegetcommand ddegetdata ddeinitial "+;
    "ddequeryst ddeterminate ddeuniniti decrypt defwindowp deldbfmdx deleted deletedc deletemeta deleteobject delinientr delinisect "+;
    "delresource delwndbrus descend destroycursor destroyico destroymenu destroywindow devmode devout devoutpict devpos dialogboxindirect "
local c3 := "dibdraw dibfrombitmap dibheight dibpalette dibread dibwidth dibwrite dirchange directory dirmake dirremove diskchange diskname "    +;
    "diskspace dispbegin dispbox dispend dispout ditbackgrd dlgfindtext doserror dotsadjust dow dptolp draftmode dragaccept dragfinish "    +;
    "dragquerypoint drawbitmap drawfocusr drawgrayed drawgrid drawicon drawmasked drawmenuba drawmsgitem drawtext dtoc dtos duprecord "    +;
    "editcell ellipse empty emptyclipboard enablecomm enablemenu enablewindow encrypt enddialog enddoc endmonitor endpage endpaint "    +;
    "enumfontfa eof errorblock errorlevel escape escapecomm eval existwnd exitwindowsexec exp extfloodfi extracticon exttextout fattrib "    +;
    "fclose fcount fcreate ferase ferror ffmimedec ffmimeenc fieldblock fieldget fieldpos fieldput fieldtype fieldwblock file fillevent "    +;
    "fillrect findexecut findresource findtext findwindow fklabel fkmax flock floodfill flushcomm fmimedec fmimeenc foldpaint fopen found "    +;
    "fread freadstr freelib32 freelibrary frename fseek fsize fwbitmap fwbrushes fwrite gellipse getactive getactivewindow getapplykey "    +;
    "getasynckey getbkcolor getcapture getcaretpos getclassname getclientrect getclpdata getcommerror getcoors getcpu getctrlid getcurdir "    +;
    "getcursorpos getdatas getdc getdesktopwindow getdevicecaps getdialogbaseunits getdlgbase getdlgitem getdosetkey getdrawite getdrawmenu "    +;
    "getdropinfo getenv getfirstinzip getfocus getfontinfo getframeproc getfreefil getfreespace getftime getgridsize gethelpfile gethelptopic "
local c4 := "gethostbyname gethostname gethwnd32 getinstance getip getkeystat getkeytoggle getlocal getmapmode getmdichlp getmeaitem getmenustate "    +;
    "getmetabit getmetafile getmitemid getmodulefilename getnextinzip getnumtask getordnames getparam getparent getpeername getpixel "    +;
    "getport getpostvalidate getprevalidate getprinter getproc32 getprocaddress getprofint getprofstr getprop getpvpprofstring getquery "    +;
    "getreader getresources getscrollpos getservbyname getstockobject getsubmenu getsyscolor getsysdir getsysmetrics getsystemmenu gettasks "    +;
    "gettextalign gettextcolor gettextheight gettextwidth gettickcount getversion getwindir getwindowword getwinflags getwintxtlength "    +;
    "getwndapp getwndframe getwndrect getwndtask gfnterase gfntload gfntset gframe ggetpixel gline globaladdatom globalalloc globalcompact "    +;
    "globaldata globalfree globalgeta globallock globalrealloc globalsize gmode gpolygon gputpixel grect gsetclip gsetexcl gsetpal gwriteat "    +;
    "hardcr hasresources header helpindex helppopup helpsearch helptopic hextodec hidecaret hilimenuitem htons i2bin if iif indexext indexkey "    +;
    "indexord inet_address inkey inporbyte insertmenu int interruptunregister invalidaterect invertrect isalpha isansi isansilower isansiupper "
local c5 := "iscdrom ischild iscolor isdefbutton isdigit isdiskette isiconic islower ismenu isoem isoverwnd isprinter isupper iswin95 iswindowvisible "    +;
    "iswinnt iszip iszoomed joygetdevcaps joygetnumdevs joygetthreshold joysetcapture joysetthre keyfast keytoggle killtimer l2bin land "    +;
    "largefonts lastmenu lastrec lbxdrawitem lbxgetitem lbxgetselitems lbxmeasure lchdir lclose lcreat left len lfn2sfn lgettextline lineto "    +;
    "lisdir listen llfnmkdir llfnrmdir lmdiiexist lmidioutopen lmkdir loadaccelerators loadbitmap loadcursor loadicon loadlib32 loadlibrary "    +;
    "loadmenu loadresource loadstring loadvalue localshrink log logevent logfile logstatics lopen lower lptodp lrmdir lsaveobject ltrim "    +;
    "lwrunning lxor lzcopyfile makewin max maxcol maxrow mcigeterrorstring mcisendcommand mcisendstring mcol mdblclk mdictrladjust mdirecedit         "    +;
    "measureitem memoedit memoline memoread memory memosetsuper memotran memowrit memstat memvarblock menubegin menudrawitem menuend                  "    +;
    "menumeasureitem menumodal messagebox meterpaint mgetcreate mgetline mgetreplace mhide midinoteon min mlcount mlctopos mleftdown mlpos            "    +;
    "mod modifymenu month moreheap moveget moveto movewindow mpostolc mpresent mreststate mrightdown mrow msavestate msetbounds msetclip              "    +;
    "msetcursor msetpos msgabout msgalert msgbeep msgdate msgget msginfo msglist msglogo msgmeter msgnoyes msgpaint msgretrycancel msgrun             "
local c6 := "msgsound msgstop msgtoolbar msgwait msgyesno mshow mstate nand nargc nbmpheight ncolorton ndbl2flt nddesharesetinfo ndlgbox nextdlgtabitem       "    +;
    "nextmem nfilecrc ngetbackrgb ngetforergb nhex nicons nmciopen nmciplay nmciwindow nmididevices nmsgbox nnot nor nrandom nrgb nrgbblue            "    +;
    "nrgbgreen nrgbred nseriala nserialhd nstrcrc nstrhash ntcwrow ntxpos ntxtlines nwindows nwndchrheight nwrow nwrows nxor oclone oemtoansi         "    +;
    "openclipboard opencomm oread osend outportbyte outpudebugstring paint3d palbmpdraw palbmpload palbmpread palbtnpain paramcount pbmpcolors        "    +;
    "pbmpheigh pbmpwidth peekbyte peekmessage peekword pie playmetafile pokebyte pokeword polypolygon postmessage postquitmessage printeresc          "    +;
    "printerini printersetup prnbinsource prngetdriver prngetname prngetorientation prngetport prngetsize prnlandscape prnoffset prnportrait          "    +;
    "prnsetcopies prnsetpage prnsetsize raconst radial raenumconnections raenumentries ragetconst rageterror rahangup ras_dialentry readbitmap        "    +;
    "readcomm readeven readvar realizepalette rectangle rectdotted recv regclosekey regcreatekey regdeletekey regenumkey registerclass                "
local c7 := "regopenkey regqueryvalue regsetvalue releasecapture releasedc removefont removemenu removeprop report resetdc resourcefree restoredc             "    +;
    "restproc rlnew rpreview rptaddcolumn rptaddgroup rptbegin rptend savedc say3d scan screentoclient scrollwindow selectobject selectpalette        "    +;
    "sendbinary sendmessage serverip set3dlook setactivewindow setbkcolor setbkmode setblackpen setbrushorg setcapture setcaretpos                    "    +;
    "setclassword setclipboarddata setclpdata setcommstate setcurdrive setcursor setdate setdeskwallpaper setdropinfo setfocus setftime               "    +;
    "setgridsize sethandlecount setidleaction setmapmode setmenu setminmax setmultiple setparent setpixel setpolyfillmode setprop setresources        "    +;
    "setsockopt settextalign settextcolor settextjustification settime settimer setvieworg setviewportext setwhitepen setwin95look setwindowtext      "    +;
    "setwnddefault shellabout shellexecute showcaret showcursor showwindow sndplayres sndplaysound socket socketselect spoolfile startdoc             "    +;
    "startmonitor startpage startplayback startrecord stopplayback stoprecord strbyte strcapfirst strchar strcpy strtoken symname symstat             "
local c8 := "symtblat symtbllen sysrefresh systime syswait tabctrladd tabspaint tcbrwscrol tcdrawcell terminateapp textout thisstruct time timercount         "    +;
    "timerevent trackpopupmenu treebegin treeend tvinsertitem uchartoval uloadstruct unescape unzipfile updatewindow uvalblank virtualrdd             "    +;
    "waitrun wbrwline wbrwpane wbrwscroll wbrwselbox windowfrompoint winexec winhelp winuser wndadjbottom wndadjcliente wndadjleft wndadjright        "    +;
    "wndadjtop wndbitmap wndbottom wndbox wndboxin wndboxraised wndbrush wndcenter wndcopy wndhasscrolls wndheight wndhlineraised wndhraised          "    +;
    "wndinset wndleft wndmain wndprint wndraised wndsetsize wndtop wndvlineraised wndvraised wndwidth wnetaddconnection wnetbrowse wnetconnectdialog  "    +;
    "wnetdisconnectdialog wneterror wnetgeterrortext wnetgetuser worksheet writecomm writepprostring wrtieprofstring wsaasyncselect wsacleanup        "    +;
    "wsagetlasterror wsastartup wsay wsayrect wscroll xpadc xpadl xpadr zipblock zipfile zipmsg zipname zipsize ziptype method class from data classdata                             "

local jsKeyWords := ;
    "if else endif do while enddo case endcase otherwise"



local red, offWhite, darkGreen, darkBlue, lightBlue
local bstyle  := SCE_HB_DEFAULT
local bastyle := SCE_HBA_DEFAULT
local n
local jstyle  := SCE_HJ_DEFAULT
local jastyle := SCE_HJA_DEFAULT
local black   := CLR_BLACK
local white   := CLR_WHITE

htmlKeyWords := c1 + c2 + c3 + c4 + c5 + c6 + c7 + c8


    //::SendEditor(SCI_SETLEXER, SCLEX_FLAGSHIP )
//  ::SendEditor(SCI_SETSTYLEBITS, 7)

    ::SendEditor(SCI_SETKEYWORDS, 0, htmlKeyWords)
    ::SendEditor(SCI_SETKEYWORDS, 1, jsKeyWords)

    ::SetAStyle(SCE_FS_KEYWORD, CLR_HRED)
//  ::SendEditor( SCI_STYLESETBOLD, SCE_FS_KEYWORD, 1)


    ::SetAStyle( SCE_FS_COMMENTLINE, CLR_GREEN)
    ::SetAStyle( SCE_FS_OPERATOR, CLR_HBLUE)
    ::SetAStyle( SCE_FS_STRING, CLR_CYAN)
    ::SetAStyle( SCE_FS_PREPROCESSOR, RGB(92,92,92) )
    ::SendEditor( SCI_STYLESETBACK, SCE_FS_PREPROCESSOR, RGB(255,255,192))
    ::SendEditor( SCI_STYLESETFONT, SCE_FS_PREPROCESSOR, "Courier New")

        ::StyleSetFont      (SCE_FS_KEYWORD, "Courier New" )//"Fixedsys" )
        ::StyleSetSize      (SCE_FS_KEYWORD, 10 )
        ::StyleSetBold      (SCE_FS_KEYWORD, .t.  )
        ::StyleSetItalic    (SCE_FS_KEYWORD, .f. )
        ::StyleSetUnderline (SCE_FS_KEYWORD, .f. )


/*
    // Set up the global default style. These attributes are used wherever no explicit choices are made.
    ::SetAStyle(STYLE_DEFAULT, black, white, 10, "Verdana")
    //::SendEditor(SCI_STYLECLEARALL)   // Copies global style to all other

    red       := RGB(0xFF, 0, 0)
    offWhite  := RGB(0xFF, 0xFB, 0xF0)
    darkGreen := RGB(0, 0x80, 0)
    darkBlue  := RGB(0, 0, 0x80)

    // Hypertext default is used for all the document's text
    //::SetAStyle(SCE_H_DEFAULT, CLR_BLACK, CLR_WHITE, 11, "Times New Roman")
/*
# Lexical states for SCLEX_FLAGSHIP (clipper)
lex FlagShip=SCLEX_FLAGSHIP SCE_B_
val SCE_FS_DEFAULT=0
val SCE_FS_COMMENT=1
val SCE_FS_COMMENTLINE=2
val SCE_FS_COMMENTDOC=3
val SCE_FS_COMMENTLINEDOC=4
val SCE_FS_COMMENTDOCKEYWORD=5
val SCE_FS_COMMENTDOCKEYWORDERROR=6
val SCE_FS_KEYWORD=7
val SCE_FS_KEYWORD2=8
val SCE_FS_KEYWORD3=9
val SCE_FS_KEYWORD4=10
val SCE_FS_NUMBER=11
val SCE_FS_STRING=12
val SCE_FS_PREPROCESSOR=13
val SCE_FS_OPERATOR=14
val SCE_FS_IDENTIFIER=15
val SCE_FS_DATE=16
val SCE_FS_STRINGEOL=17
val SCE_FS_CONSTANT=18
val SCE_FS_ASM=19
val SCE_FS_LABEL=20
val SCE_FS_ERROR=21
val SCE_FS_HEXNUMBER=22
val SCE_FS_BINNUMBER=23

::SetAStyle( SCE_FS_STRING, CLR_YELLOW, CLR_BLUE )


    // Unknown tags and attributes are highlighed in red.
    // If a tag is actually OK, it should be added in lower case to the htmlKeyWords string.
    ::SetAStyle(SCE_H_TAG, darkBlue)
    ::SetAStyle(SCE_H_TAGUNKNOWN, red)
    ::SetAStyle(SCE_H_ATTRIBUTE, darkBlue)
    ::SetAStyle(SCE_H_ATTRIBUTEUNKNOWN, red)
    ::SetAStyle(SCE_H_NUMBER, RGB(0x80,0,0x80))
    ::SetAStyle(SCE_H_DOUBLESTRING, RGB(0,0x80,0))
    ::SetAStyle(SCE_H_SINGLESTRING, RGB(0,0x80,0))
    ::SetAStyle(SCE_H_OTHER, RGB(0x80,0,0x80))
    ::SetAStyle(SCE_H_COMMENT, RGB(0x80,0x80,0))
    ::SetAStyle(SCE_H_ENTITY, RGB(0x80,0,0x80))

    ::SetAStyle(SCE_H_TAGEND, darkBlue)
    ::SetAStyle(SCE_H_XMLSTART, darkBlue)   // <
    ::SetAStyle(SCE_H_XMLEND, darkBlue)     // ?>
    ::SetAStyle(SCE_H_SCRIPT, darkBlue)     // <scrip
    ::SetAStyle(SCE_H_ASP, RGB(0x4F, 0x4F, 0), RGB(0xFF, 0xFF, 0))  // <% ... %
    ::SetAStyle(SCE_H_ASPAT, RGB(0x4F, 0x4F, 0), RGB(0xFF, 0xFF, 0))    // <%@ ... %>

    ::SetAStyle(SCE_HB_DEFAULT, black)
    ::SetAStyle(SCE_HB_COMMENTLINE, darkGreen)
    ::SetAStyle(SCE_HB_NUMBER, RGB(0,0x80,0x80))
    ::SetAStyle(SCE_HB_WORD, darkBlue)
    ::SendEditor(SCI_STYLESETBOLD, SCE_HB_WORD, 1)
    ::SetAStyle(SCE_HB_STRING, RGB(0x80,0,0x80))
    ::SetAStyle(SCE_HB_IDENTIFIER, black)

    // This light blue is found in the windows system palette so is safe to use even in 256 colour modes.
    lightBlue := RGB(0xA6, 0xCA, 0xF0)
    // Show the whole section of VBScript with light blue background
    for n = bstyle to  SCE_HB_STRINGEOL

        ::SendEditor(SCI_STYLESETFONT, n,"Georgia")
        ::SendEditor(SCI_STYLESETBACK, n, lightBlue)
        // This call extends the backround colour of the last style on the line to the edge of the window
        ::SendEditor(SCI_STYLESETEOLFILLED, n, 1)
    next

    ::SendEditor(SCI_STYLESETBACK, SCE_HB_STRINGEOL, RGB(0x7F,0x7F,0xFF))
    ::SendEditor(SCI_STYLESETFONT, SCE_HB_COMMENTLINE,"Comic Sans MS")

    ::SetAStyle(SCE_HBA_DEFAULT, black)
    ::SetAStyle(SCE_HBA_COMMENTLINE, darkGreen)
    ::SetAStyle(SCE_HBA_NUMBER, RGB(0,0x80,0x80))
    ::SetAStyle(SCE_HBA_WORD, darkBlue)
    ::SendEditor(SCI_STYLESETBOLD, SCE_HBA_WORD, 1)
    ::SetAStyle(SCE_HBA_STRING, RGB(0x80,0,0x80))
    ::SetAStyle(SCE_HBA_IDENTIFIER, black)

    // Show the whole section of ASP VBScript with bright yellow background
    for n = bastyle to SCE_HBA_STRINGEOL
        ::SendEditor(SCI_STYLESETFONT, n,"Georgia")
        ::SendEditor(SCI_STYLESETBACK, n, RGB(0xFF, 0xFF, 0))
        // This call extends the backround colour of the last style on the line to the edge of the window
        ::SendEditor(SCI_STYLESETEOLFILLED, n, 1)
    next
    ::SendEditor(SCI_STYLESETBACK, SCE_HBA_STRINGEOL, RGB(0xCF,0xCF,0x7F))
    ::SendEditor(SCI_STYLESETFONT, SCE_HBA_COMMENTLINE,"Comic Sans MS")

    // If there is no need to support embedded Javascript, the following code can be dropped.
    // Javascript will still be correctly processed but will be displayed in just the default style.

    ::SetAStyle(SCE_HJ_START, RGB(0x80,0x80,0))
    ::SetAStyle(SCE_HJ_DEFAULT, black)
    ::SetAStyle(SCE_HJ_COMMENT, darkGreen)
    ::SetAStyle(SCE_HJ_COMMENTLINE, darkGreen)
    ::SetAStyle(SCE_HJ_COMMENTDOC, darkGreen)
    ::SetAStyle(SCE_HJ_NUMBER, RGB(0,0x80,0x80))
    ::SetAStyle(SCE_HJ_WORD, black)
    ::SetAStyle(SCE_HJ_KEYWORD, darkBlue)
    ::SetAStyle(SCE_HJ_DOUBLESTRING, RGB(0x80,0,0x80))
    ::SetAStyle(SCE_HJ_SINGLESTRING, RGB(0x80,0,0x80))
    ::SetAStyle(SCE_HJ_SYMBOLS, black)

    ::SetAStyle(SCE_HJA_START, RGB(0x80,0x80,0))
    ::SetAStyle(SCE_HJA_DEFAULT, black)
    ::SetAStyle(SCE_HJA_COMMENT, darkGreen)
    ::SetAStyle(SCE_HJA_COMMENTLINE, darkGreen)
    ::SetAStyle(SCE_HJA_COMMENTDOC, darkGreen)
    ::SetAStyle(SCE_HJA_NUMBER, RGB(0,0x80,0x80))
    ::SetAStyle(SCE_HJA_WORD, black)
    ::SetAStyle(SCE_HJA_KEYWORD, darkBlue)
    ::SetAStyle(SCE_HJA_DOUBLESTRING, RGB(0x80,0,0x80))
    ::SetAStyle(SCE_HJA_SINGLESTRING, RGB(0x80,0,0x80))
    ::SetAStyle(SCE_HJA_SYMBOLS, black)

    // Show the whole section of Javascript with off white background
    for n := jstyle to SCE_HJ_SYMBOLS

        ::SendEditor(SCI_STYLESETFONT, jstyle,"Lucida Sans Unicode")
        ::SendEditor(SCI_STYLESETBACK, jstyle, offWhite)
        ::SendEditor(SCI_STYLESETEOLFILLED, jstyle, 1)
    next
    ::SendEditor(SCI_STYLESETBACK, SCE_HJ_STRINGEOL, RGB(0xDF, 0xDF, 0x7F))
    ::SendEditor(SCI_STYLESETEOLFILLED, SCE_HJ_STRINGEOL, 1)

    // Show the whole section of Javascript with brown background
    for n := jastyle  to SCE_HJA_SYMBOLS
        ::SendEditor(SCI_STYLESETFONT, jastyle,"Lucida Sans Unicode")
        ::SendEditor(SCI_STYLESETBACK, jastyle, RGB(0xDF, 0xDF, 0x7F))
        ::SendEditor(SCI_STYLESETEOLFILLED, jastyle, 1)
    next
    ::SendEditor(SCI_STYLESETBACK, SCE_HJA_STRINGEOL, RGB(0x0,0xAF,0x5F))
    ::SendEditor(SCI_STYLESETEOLFILLED, SCE_HJA_STRINGEOL, 1)
*/
return nil

**********************************************************************************************
  METHOD Notify( nIdCtrl, nPtrNMHDR ) CLASS TScintilla
**********************************************************************************************

   local nCode := GetNMHDRCode( nPtrNMHDR )
   local line_number, position

   if nCode == SCN_MARGINCLICK
      position :=  GetPosHdr( nPtrNMHDR )
      line_number := ::SendEditor(SCI_LINEFROMPOSITION, position, 0)
      ::MarkerAdd( line_number, 1)

   endif

return nil











*****************************************************************************************************
*****************************************************************************************************
*****************************************************************************************************
*****************************************************************************************************
*****************************************************************************************************
*****************************************************************************************************
*****************************************************************************************************
*****************************************************************************************************
*****************************************************************************************************
*****************************************************************************************************
*****************************************************************************************************

#pragma BEGINDUMP

#include <windows.h>
#include <hbapi.h>
#include <commctrl.h>
#include "..\include\scintila.h"

int GetHdr( LPARAM lParam )
{
   struct SCNotification *pMsg =
       (struct SCNotification*)lParam;
    return (pMsg->position);
}

HB_FUNC( GETPOSHDR )
{
   hb_retni( GetHdr( hb_parnl( 1 ) ));
}

BOOL SearchForward( HWND hWnd, LPSTR szText, int nSearchFlags ) //@parm text to search
{
   long lPos;
   TEXTTOFIND tf;
   if (szText == NULL)
      return FALSE;
   lPos = SendMessage(hWnd, SCI_GETCURRENTPOS, 0, 0);
   tf.lpstrText = szText;
   tf.chrg.cpMin = lPos+1;
   tf.chrg.cpMax = SendMessage( hWnd, SCI_GETLENGTH, 0, 0);
   lPos = SendMessage( hWnd, SCI_FINDTEXT, (int) nSearchFlags, (long)&tf);
   if (lPos >= 0)
   {
      SetFocus( hWnd );
      SendMessage( hWnd, SCI_GOTOPOS, lPos, 0);
      SendMessage( hWnd, SCI_SETSEL, tf.chrgText.cpMin, tf.chrgText.cpMax);
      SendMessage( hWnd, SCI_FINDTEXT, (int) nSearchFlags, (long)&tf);
      return TRUE;
   }
   return FALSE;
}
/////////////////////////////////////
// @mfunc Search backward for a given string and select it if found. You may use regular expressions on the text.
// @rvalue BOOL | TRUE if text is ffound else FALSE
//
BOOL SearchBackward( HWND hWnd, LPSTR szText, int nSearchFlags ) //@parm text to search
{
   int lPos;
   int lMinSel;
   TEXTTOFIND tf;
   if (szText == NULL)
      return FALSE;
   lPos = SendMessage(hWnd, SCI_GETCURRENTPOS, 0, 0);
   lMinSel = SendMessage(hWnd,SCI_GETSELECTIONSTART, 0, 0);
   tf.lpstrText = szText;
   if (lMinSel >= 0)
      tf.chrg.cpMin = lMinSel-1;
   else
      tf.chrg.cpMin = lPos-1;
   tf.chrg.cpMax = 0;
   lPos = SendMessage( hWnd, SCI_FINDTEXT, (int) nSearchFlags, (long)&tf);
   if (lPos >= 0)
   {
      SetFocus(hWnd);
      SendMessage( hWnd, SCI_GOTOPOS, lPos, 0);
      SendMessage( hWnd, SCI_SETSEL, tf.chrgText.cpMin, tf.chrgText.cpMax);
      SendMessage( hWnd, SCI_FINDTEXT, (int) nSearchFlags, (long)&tf);
      return TRUE;
   }
   return FALSE;
}

HB_FUNC( SC_ADDTEXT )
{
    SendMessage( (HWND) hb_parnl( 1 ) , SCI_ADDTEXT, hb_parclen( 2 ), (LPARAM) hb_parc( 2 )) ;
    hb_ret();
}

HB_FUNC( SCI_OPENFILE )
{
   HWND hWnd = ( HWND ) hb_parnl( 1 );
   char * fileName = ( char * ) hb_parc( 2 );
   char data[ 131072 ];
   FILE * fp;
   int lenFile;

   SendMessage( hWnd, SCI_CLEARALL,0,0);
        SendMessage( hWnd, EM_EMPTYUNDOBUFFER, 0, 0);
        SendMessage( hWnd, SCI_SETSAVEPOINT, 0, 0);
        SendMessage( hWnd, SCI_CANCEL, 0, 0);
        SendMessage( hWnd, SCI_SETUNDOCOLLECTION, 0, 0);

        fp = fopen(fileName, "rb");
        if (fp) {
                lenFile = fread(data, 1, sizeof(data), fp);
                while (lenFile > 0) {
                        SendMessage( hWnd, SCI_ADDTEXT, lenFile, (LPARAM) data );
                        lenFile = fread(data, 1, sizeof(data), fp);
                }
                fclose(fp);
        } else {
                MessageBox(0, "No puedo abrir el fichero", "Atención", MB_OK);
        }
        SendMessage( hWnd, SCI_SETUNDOCOLLECTION, 1, 0);
        SetFocus( hWnd );
        SendMessage( hWnd, EM_EMPTYUNDOBUFFER, 0, 0);
        SendMessage( hWnd, SCI_SETSAVEPOINT, 0, 0 );
        SendMessage( hWnd, SCI_GOTOPOS, 0, 0);
   hb_ret();
}

HB_FUNC( SC_GETTEXT )
{
   HWND hWnd = ( HWND ) hb_parnl( 1 );
   int wLen;
   BYTE * pbyBuffer;
   wLen = SendMessage( hWnd, SCI_GETLENGTH, 0, 0 );
   pbyBuffer = ( char * ) hb_xgrab( wLen+1 );

   SendMessage( hWnd, SCI_GETTEXT, wLen+1, (LPARAM) pbyBuffer );

   hb_retclen( ( char * ) pbyBuffer, wLen+1 );
   hb_xfree( pbyBuffer );
}

HB_FUNC( SC_GETLINE )
{
   HWND hWnd = ( HWND ) hb_parnl( 1 );
   int nLine = hb_parni( 2 )-1;
   int wLen;
   BYTE * pbyBuffer;
   wLen = SendMessage( hWnd, SCI_LINELENGTH, nLine, 0 );
   if( wLen )
   {
      pbyBuffer = ( char * ) hb_xgrab( wLen+1 );
      SendMessage( hWnd, SCI_GETLINE, nLine, (LPARAM) pbyBuffer );
      hb_retclen( ( char * ) pbyBuffer, wLen );
      hb_xfree( pbyBuffer );
   }
   else
      hb_retc("");
}

HB_FUNC( SC_ISREADONLY )
{
    hb_retl( SendMessage( (HWND) hb_parnl( 1 ), SCI_GETREADONLY, 0, 0 ) );
}

HB_FUNC( SEARCHFORWARD )
{
   hb_retl( SearchForward( ( HWND ) hb_parnl( 1 ), ( char * ) hb_parc( 2 ), hb_parni( 3 ) ) );
}

HB_FUNC( SEARCHBACKWARD )
{
    hb_retl(SearchBackward( ( HWND ) hb_parnl( 1 ), ( char * ) hb_parc( 2 ), hb_parni( 3 ) ) );
}

HB_FUNC ( C5GETSELTEXT )
{
   HWND hWnd = (HWND) hb_parnl( 1 );
   int wSize = hb_parni( 2 );
   LPSTR cBuff = ( char * ) hb_xgrab( wSize + 1 );

   SendMessage( hWnd, SCI_GETSELTEXT, (WPARAM)0, (LPARAM)cBuff );

   hb_retclen( cBuff, wSize );
   hb_xfree( cBuff );
}

#pragma ENDDUMP


scintilla.h
Code (fw): Select all Collapse
#ifndef SCINTILLA_CH
#define SCINTILLA_CH

#define INVALID_POSITION -1
#define SCI_START 2000
#define SCI_OPTIONAL_START 3000
#define SCI_LEXER_START 4000
#define SCI_ADDTEXT 2001
#define SCI_ADDSTYLEDTEXT 2002
#define SCI_INSERTTEXT 2003
#define SCI_CLEARALL 2004
#define SCI_CLEARDOCUMENTSTYLE 2005
#define SCI_GETLENGTH 2006
#define SCI_GETCHARAT 2007
#define SCI_GETCURRENTPOS 2008
#define SCI_GETANCHOR 2009
#define SCI_GETSTYLEAT 2010
#define SCI_REDO 2011
#define SCI_SETUNDOCOLLECTION 2012
#define SCI_SELECTALL 2013
#define SCI_SETSAVEPOINT 2014
#define SCI_GETSTYLEDTEXT 2015
#define SCI_CANREDO 2016
#define SCI_MARKERLINEFROMHANDLE 2017
#define SCI_MARKERDELETEHANDLE 2018
#define SCI_GETUNDOCOLLECTION 2019
#define SCWS_INVISIBLE 0
#define SCWS_VISIBLEALWAYS 1
#define SCWS_VISIBLEAFTERINDENT 2
#define SCI_GETVIEWWS 2020
#define SCI_SETVIEWWS 2021
#define SCI_POSITIONFROMPOINT 2022
#define SCI_POSITIONFROMPOINTCLOSE 2023
#define SCI_GOTOLINE 2024
#define SCI_GOTOPOS 2025
#define SCI_SETANCHOR 2026
#define SCI_GETCURLINE 2027
#define SCI_GETENDSTYLED 2028
#define SC_EOL_CRLF 0
#define SC_EOL_CR 1
#define SC_EOL_LF 2
#define SCI_CONVERTEOLS 2029
#define SCI_GETEOLMODE 2030
#define SCI_SETEOLMODE 2031
#define SCI_STARTSTYLING 2032
#define SCI_SETSTYLING 2033
#define SCI_GETBUFFEREDDRAW 2034
#define SCI_SETBUFFEREDDRAW 2035
#define SCI_SETTABWIDTH 2036
#define SCI_GETTABWIDTH 2121
#define SC_CP_UTF8 65001
#define SC_CP_DBCS 1
#define SCI_SETCODEPAGE 2037
#define SCI_SETUSEPALETTE 2039
#define MARKER_MAX 31
#define SC_MARK_CIRCLE 0
#define SC_MARK_ROUNDRECT 1
#define SC_MARK_ARROW 2
#define SC_MARK_SMALLRECT 3
#define SC_MARK_SHORTARROW 4
#define SC_MARK_EMPTY 5
#define SC_MARK_ARROWDOWN 6
#define SC_MARK_MINUS 7
#define SC_MARK_PLUS 8
#define SC_MARK_VLINE 9
#define SC_MARK_LCORNER 10
#define SC_MARK_TCORNER 11
#define SC_MARK_BOXPLUS 12
#define SC_MARK_BOXPLUSCONNECTED 13
#define SC_MARK_BOXMINUS 14
#define SC_MARK_BOXMINUSCONNECTED 15
#define SC_MARK_LCORNERCURVE 16
#define SC_MARK_TCORNERCURVE 17
#define SC_MARK_CIRCLEPLUS 18
#define SC_MARK_CIRCLEPLUSCONNECTED 19
#define SC_MARK_CIRCLEMINUS 20
#define SC_MARK_CIRCLEMINUSCONNECTED 21
#define SC_MARK_BACKGROUND 22
#define SC_MARK_DOTDOTDOT 23
#define SC_MARK_ARROWS 24
#define SC_MARK_PIXMAP 25
#define SC_MARK_CHARACTER 10000
#define SC_MARKNUM_FOLDEREND 25
#define SC_MARKNUM_FOLDEROPENMID 26
#define SC_MARKNUM_FOLDERMIDTAIL 27
#define SC_MARKNUM_FOLDERTAIL 28
#define SC_MARKNUM_FOLDERSUB 29
#define SC_MARKNUM_FOLDER 30
#define SC_MARKNUM_FOLDEROPEN 31
#define SC_MASK_FOLDERS 0xFE000000
#define SCI_MARKERDEFINE 2040
#define SCI_MARKERSETFORE 2041
#define SCI_MARKERSETBACK 2042
#define SCI_MARKERADD 2043
#define SCI_MARKERDELETE 2044
#define SCI_MARKERDELETEALL 2045
#define SCI_MARKERGET 2046
#define SCI_MARKERNEXT 2047
#define SCI_MARKERPREVIOUS 2048
#define SCI_MARKERDEFINEPIXMAP 2049
#define SC_MARGIN_SYMBOL 0
#define SC_MARGIN_NUMBER 1
#define SCI_SETMARGINTYPEN 2240
#define SCI_GETMARGINTYPEN 2241
#define SCI_SETMARGINWIDTHN 2242
#define SCI_GETMARGINWIDTHN 2243
#define SCI_SETMARGINMASKN 2244
#define SCI_GETMARGINMASKN 2245
#define SCI_SETMARGINSENSITIVEN 2246
#define SCI_GETMARGINSENSITIVEN 2247
#define STYLE_DEFAULT 32
#define STYLE_LINENUMBER 33
#define STYLE_BRACELIGHT 34
#define STYLE_BRACEBAD 35
#define STYLE_CONTROLCHAR 36
#define STYLE_INDENTGUIDE 37
#define STYLE_LASTPREDEFINED 39
#define STYLE_MAX 127
#define SC_CHARSET_ANSI 0
#define SC_CHARSET_DEFAULT 1
#define SC_CHARSET_BALTIC 186
#define SC_CHARSET_CHINESEBIG5 136
#define SC_CHARSET_EASTEUROPE 238
#define SC_CHARSET_GB2312 134
#define SC_CHARSET_GREEK 161
#define SC_CHARSET_HANGUL 129
#define SC_CHARSET_MAC 77
#define SC_CHARSET_OEM 255
#define SC_CHARSET_RUSSIAN 204
#define SC_CHARSET_SHIFTJIS 128
#define SC_CHARSET_SYMBOL 2
#define SC_CHARSET_TURKISH 162
#define SC_CHARSET_JOHAB 130
#define SC_CHARSET_HEBREW 177
#define SC_CHARSET_ARABIC 178
#define SC_CHARSET_VIETNAMESE 163
#define SC_CHARSET_THAI 222
#define SCI_STYLECLEARALL 2050
#define SCI_STYLESETFORE 2051
#define SCI_STYLESETBACK 2052
#define SCI_STYLESETBOLD 2053
#define SCI_STYLESETITALIC 2054
#define SCI_STYLESETSIZE 2055
#define SCI_STYLESETFONT 2056
#define SCI_STYLESETEOLFILLED 2057
#define SCI_STYLERESETDEFAULT 2058
#define SCI_STYLESETUNDERLINE 2059
#define SC_CASE_MIXED 0
#define SC_CASE_UPPER 1
#define SC_CASE_LOWER 2
#define SCI_STYLESETCASE 2060
#define SCI_STYLESETCHARACTERSET 2066
#define SCI_STYLESETHOTSPOT 2409
#define SCI_SETSELFORE 2067
#define SCI_SETSELBACK 2068
#define SCI_SETCARETFORE 2069
#define SCI_ASSIGNCMDKEY 2070
#define SCI_CLEARCMDKEY 2071
#define SCI_CLEARALLCMDKEYS 2072
#define SCI_SETSTYLINGEX 2073
#define SCI_STYLESETVISIBLE 2074
#define SCI_GETCARETPERIOD 2075
#define SCI_SETCARETPERIOD 2076
#define SCI_SETWORDCHARS 2077
#define SCI_BEGINUNDOACTION 2078
#define SCI_ENDUNDOACTION 2079
#define INDIC_MAX 7
#define INDIC_PLAIN 0
#define INDIC_SQUIGGLE 1
#define INDIC_TT 2
#define INDIC_DIAGONAL 3
#define INDIC_STRIKE 4
#define INDIC_HIDDEN 5
#define INDIC_BOX 6
#define INDIC0_MASK 0x20
#define INDIC1_MASK 0x40
#define INDIC2_MASK 0x80
#define INDICS_MASK 0xE0
#define SCI_INDICSETSTYLE 2080
#define SCI_INDICGETSTYLE 2081
#define SCI_INDICSETFORE 2082
#define SCI_INDICGETFORE 2083
#define SCI_SETWHITESPACEFORE 2084
#define SCI_SETWHITESPACEBACK 2085
#define SCI_SETSTYLEBITS 2090
#define SCI_GETSTYLEBITS 2091
#define SCI_SETLINESTATE 2092
#define SCI_GETLINESTATE 2093
#define SCI_GETMAXLINESTATE 2094
#define SCI_GETCARETLINEVISIBLE 2095
#define SCI_SETCARETLINEVISIBLE 2096
#define SCI_GETCARETLINEBACK 2097
#define SCI_SETCARETLINEBACK 2098
#define SCI_STYLESETCHANGEABLE 2099
#define SCI_AUTOCSHOW 2100
#define SCI_AUTOCCANCEL 2101
#define SCI_AUTOCACTIVE 2102
#define SCI_AUTOCPOSSTART 2103
#define SCI_AUTOCCOMPLETE 2104
#define SCI_AUTOCSTOPS 2105
#define SCI_AUTOCSETSEPARATOR 2106
#define SCI_AUTOCGETSEPARATOR 2107
#define SCI_AUTOCSELECT 2108
#define SCI_AUTOCSETCANCELATSTART 2110
#define SCI_AUTOCGETCANCELATSTART 2111
#define SCI_AUTOCSETFILLUPS 2112
#define SCI_AUTOCSETCHOOSESINGLE 2113
#define SCI_AUTOCGETCHOOSESINGLE 2114
#define SCI_AUTOCSETIGNORECASE 2115
#define SCI_AUTOCGETIGNORECASE 2116
#define SCI_USERLISTSHOW 2117
#define SCI_AUTOCSETAUTOHIDE 2118
#define SCI_AUTOCGETAUTOHIDE 2119
#define SCI_AUTOCSETDROPRESTOFWORD 2270
#define SCI_AUTOCGETDROPRESTOFWORD 2271
#define SCI_REGISTERIMAGE 2405
#define SCI_CLEARREGISTEREDIMAGES 2408
#define SCI_AUTOCGETTYPESEPARATOR 2285
#define SCI_AUTOCSETTYPESEPARATOR 2286
#define SCI_SETINDENT 2122
#define SCI_GETINDENT 2123
#define SCI_SETUSETABS 2124
#define SCI_GETUSETABS 2125
#define SCI_SETLINEINDENTATION 2126
#define SCI_GETLINEINDENTATION 2127
#define SCI_GETLINEINDENTPOSITION 2128
#define SCI_GETCOLUMN 2129
#define SCI_SETHSCROLLBAR 2130
#define SCI_GETHSCROLLBAR 2131
#define SCI_SETINDENTATIONGUIDES 2132
#define SCI_GETINDENTATIONGUIDES 2133
#define SCI_SETHIGHLIGHTGUIDE 2134
#define SCI_GETHIGHLIGHTGUIDE 2135
#define SCI_GETLINEENDPOSITION 2136
#define SCI_GETCODEPAGE 2137
#define SCI_GETCARETFORE 2138
#define SCI_GETUSEPALETTE 2139
#define SCI_GETREADONLY 2140
#define SCI_SETCURRENTPOS 2141
#define SCI_SETSELECTIONSTART 2142
#define SCI_GETSELECTIONSTART 2143
#define SCI_SETSELECTIONEND 2144
#define SCI_GETSELECTIONEND 2145
#define SCI_SETPRINTMAGNIFICATION 2146
#define SCI_GETPRINTMAGNIFICATION 2147
#define SC_PRINT_NORMAL 0
#define SC_PRINT_INVERTLIGHT 1
#define SC_PRINT_BLACKONWHITE 2
#define SC_PRINT_COLOURONWHITE 3
#define SC_PRINT_COLOURONWHITEDEFAULTBG 4
#define SCI_SETPRINTCOLOURMODE 2148
#define SCI_GETPRINTCOLOURMODE 2149
#define SCFIND_WHOLEWORD 2
#define SCFIND_MATCHCASE 4
#define SCFIND_WORDSTART 0x00100000
#define SCFIND_REGEXP 0x00200000
#define SCFIND_POSIX 0x00400000
#define SCI_FINDTEXT 2150
#define SCI_FORMATRANGE 2151
#define SCI_GETFIRSTVISIBLELINE 2152
#define SCI_GETLINE 2153
#define SCI_GETLINECOUNT 2154
#define SCI_SETMARGINLEFT 2155
#define SCI_GETMARGINLEFT 2156
#define SCI_SETMARGINRIGHT 2157
#define SCI_GETMARGINRIGHT 2158
#define SCI_GETMODIFY 2159
#define SCI_SETSEL 2160
#define SCI_GETSELTEXT 2161
#define SCI_GETTEXTRANGE 2162
#define SCI_HIDESELECTION 2163
#define SCI_POINTXFROMPOSITION 2164
#define SCI_POINTYFROMPOSITION 2165
#define SCI_LINEFROMPOSITION 2166
#define SCI_POSITIONFROMLINE 2167
#define SCI_LINESCROLL 2168
#define SCI_SCROLLCARET 2169
#define SCI_REPLACESEL 2170
#define SCI_SETREADONLY 2171
#define SCI_NULL 2172
#define SCI_CANPASTE 2173
#define SCI_CANUNDO 2174
#define SCI_EMPTYUNDOBUFFER 2175
#define SCI_UNDO 2176
#define SCI_CUT 2177
#define SCI_COPY 2178
#define SCI_PASTE 2179
#define SCI_CLEAR 2180
#define SCI_SETTEXT 2181
#define SCI_GETTEXT 2182
#define SCI_GETTEXTLENGTH 2183
#define SCI_GETDIRECTFUNCTION 2184
#define SCI_GETDIRECTPOINTER 2185
#define SCI_SETOVERTYPE 2186
#define SCI_GETOVERTYPE 2187
#define SCI_SETCARETWIDTH 2188
#define SCI_GETCARETWIDTH 2189
#define SCI_SETTARGETSTART 2190
#define SCI_GETTARGETSTART 2191
#define SCI_SETTARGETEND 2192
#define SCI_GETTARGETEND 2193
#define SCI_REPLACETARGET 2194
#define SCI_REPLACETARGETRE 2195
#define SCI_SEARCHINTARGET 2197
#define SCI_SETSEARCHFLAGS 2198
#define SCI_GETSEARCHFLAGS 2199
#define SCI_CALLTIPSHOW 2200
#define SCI_CALLTIPCANCEL 2201
#define SCI_CALLTIPACTIVE 2202
#define SCI_CALLTIPPOSSTART 2203
#define SCI_CALLTIPSETHLT 2204
#define SCI_CALLTIPSETBACK 2205
#define SCI_CALLTIPSETFORE 2206
#define SCI_CALLTIPSETFOREHLT 2207
#define SCI_VISIBLEFROMDOCLINE 2220
#define SCI_DOCLINEFROMVISIBLE 2221
#define SC_FOLDLEVELBASE 0x400
#define SC_FOLDLEVELWHITEFLAG 0x1000
#define SC_FOLDLEVELHEADERFLAG 0x2000
#define SC_FOLDLEVELBOXHEADERFLAG 0x4000
#define SC_FOLDLEVELBOXFOOTERFLAG 0x8000
#define SC_FOLDLEVELCONTRACTED 0x10000
#define SC_FOLDLEVELUNINDENT 0x20000
#define SC_FOLDLEVELNUMBERMASK 0x0FFF
#define SCI_SETFOLDLEVEL 2222
#define SCI_GETFOLDLEVEL 2223
#define SCI_GETLASTCHILD 2224
#define SCI_GETFOLDPARENT 2225
#define SCI_SHOWLINES 2226
#define SCI_HIDELINES 2227
#define SCI_GETLINEVISIBLE 2228
#define SCI_SETFOLDEXPANDED 2229
#define SCI_GETFOLDEXPANDED 2230
#define SCI_TOGGLEFOLD 2231
#define SCI_ENSUREVISIBLE 2232
#define SC_FOLDFLAG_LINEBEFORE_EXPANDED 0x0002
#define SC_FOLDFLAG_LINEBEFORE_CONTRACTED 0x0004
#define SC_FOLDFLAG_LINEAFTER_EXPANDED 0x0008
#define SC_FOLDFLAG_LINEAFTER_CONTRACTED 0x0010
#define SC_FOLDFLAG_LEVELNUMBERS 0x0040
#define SC_FOLDFLAG_BOX 0x0001
#define SCI_SETFOLDFLAGS 2233
#define SCI_ENSUREVISIBLEENFORCEPOLICY 2234
#define SCI_SETTABINDENTS 2260
#define SCI_GETTABINDENTS 2261
#define SCI_SETBACKSPACEUNINDENTS 2262
#define SCI_GETBACKSPACEUNINDENTS 2263
#define SC_TIME_FOREVER 10000000
#define SCI_SETMOUSEDWELLTIME 2264
#define SCI_GETMOUSEDWELLTIME 2265
#define SCI_WORDSTARTPOSITION 2266
#define SCI_WORDENDPOSITION 2267
#define SC_WRAP_NONE 0
#define SC_WRAP_WORD 1
#define SCI_SETWRAPMODE 2268
#define SCI_GETWRAPMODE 2269
#define SC_WRAPVISUALFLAG_NONE 0x0000
#define SC_WRAPVISUALFLAG_END 0x0001
#define SC_WRAPVISUALFLAG_START 0x0002
#define SCI_SETWRAPVISUALFLAGS 2460
#define SCI_GETWRAPVISUALFLAGS 2461
#define SC_WRAPVISUALFLAGLOC_DEFAULT 0x0000
#define SC_WRAPVISUALFLAGLOC_END_BY_TEXT 0x0001
#define SC_WRAPVISUALFLAGLOC_START_BY_TEXT 0x0002
#define SCI_SETWRAPVISUALFLAGSLOCATION 2462
#define SCI_GETWRAPVISUALFLAGSLOCATION 2463
#define SCI_SETWRAPSTARTINDENT 2464
#define SCI_GETWRAPSTARTINDENT 2465
#define SC_CACHE_NONE 0
#define SC_CACHE_CARET 1
#define SC_CACHE_PAGE 2
#define SC_CACHE_DOCUMENT 3
#define SCI_SETLAYOUTCACHE 2272
#define SCI_GETLAYOUTCACHE 2273
#define SCI_SETSCROLLWIDTH 2274
#define SCI_GETSCROLLWIDTH 2275
#define SCI_TEXTWIDTH 2276
#define SCI_SETENDATLASTLINE 2277
#define SCI_GETENDATLASTLINE 2278
#define SCI_TEXTHEIGHT 2279
#define SCI_SETVSCROLLBAR 2280
#define SCI_GETVSCROLLBAR 2281
#define SCI_APPENDTEXT 2282
#define SCI_GETTWOPHASEDRAW 2283
#define SCI_SETTWOPHASEDRAW 2284
#define SCI_TARGETFROMSELECTION 2287
#define SCI_LINESJOIN 2288
#define SCI_LINESSPLIT 2289
#define SCI_SETFOLDMARGINCOLOUR 2290
#define SCI_SETFOLDMARGINHICOLOUR 2291
#define SCI_LINEDOWN 2300
#define SCI_LINEDOWNEXTEND 2301
#define SCI_LINEUP 2302
#define SCI_LINEUPEXTEND 2303
#define SCI_CHARLEFT 2304
#define SCI_CHARLEFTEXTEND 2305
#define SCI_CHARRIGHT 2306
#define SCI_CHARRIGHTEXTEND 2307
#define SCI_WORDLEFT 2308
#define SCI_WORDLEFTEXTEND 2309
#define SCI_WORDRIGHT 2310
#define SCI_WORDRIGHTEXTEND 2311
#define SCI_HOME 2312
#define SCI_HOMEEXTEND 2313
#define SCI_LINEEND 2314
#define SCI_LINEENDEXTEND 2315
#define SCI_DOCUMENTSTART 2316
#define SCI_DOCUMENTSTARTEXTEND 2317
#define SCI_DOCUMENTEND 2318
#define SCI_DOCUMENTENDEXTEND 2319
#define SCI_PAGEUP 2320
#define SCI_PAGEUPEXTEND 2321
#define SCI_PAGEDOWN 2322
#define SCI_PAGEDOWNEXTEND 2323
#define SCI_EDITTOGGLEOVERTYPE 2324
#define SCI_CANCEL 2325
#define SCI_DELETEBACK 2326
#define SCI_TAB 2327
#define SCI_BACKTAB 2328
#define SCI_NEWLINE 2329
#define SCI_FORMFEED 2330
#define SCI_VCHOME 2331
#define SCI_VCHOMEEXTEND 2332
#define SCI_ZOOMIN 2333
#define SCI_ZOOMOUT 2334
#define SCI_DELWORDLEFT 2335
#define SCI_DELWORDRIGHT 2336
#define SCI_LINECUT 2337
#define SCI_LINEDELETE 2338
#define SCI_LINETRANSPOSE 2339
#define SCI_LINEDUPLICATE 2404
#define SCI_LOWERCASE 2340
#define SCI_UPPERCASE 2341
#define SCI_LINESCROLLDOWN 2342
#define SCI_LINESCROLLUP 2343
#define SCI_DELETEBACKNOTLINE 2344
#define SCI_HOMEDISPLAY 2345
#define SCI_HOMEDISPLAYEXTEND 2346
#define SCI_LINEENDDISPLAY 2347
#define SCI_LINEENDDISPLAYEXTEND 2348
#define SCI_HOMEWRAP 2349
#define SCI_HOMEWRAPEXTEND 2450
#define SCI_LINEENDWRAP 2451
#define SCI_LINEENDWRAPEXTEND 2452
#define SCI_VCHOMEWRAP 2453
#define SCI_VCHOMEWRAPEXTEND 2454
#define SCI_LINECOPY 2455
#define SCI_MOVECARETINSIDEVIEW 2401
#define SCI_LINELENGTH 2350
#define SCI_BRACEHIGHLIGHT 2351
#define SCI_BRACEBADLIGHT 2352
#define SCI_BRACEMATCH 2353
#define SCI_GETVIEWEOL 2355
#define SCI_SETVIEWEOL 2356
#define SCI_GETDOCPOINTER 2357
#define SCI_SETDOCPOINTER 2358
#define SCI_SETMODEVENTMASK 2359
#define EDGE_NONE 0
#define EDGE_LINE 1
#define EDGE_BACKGROUND 2
#define SCI_GETEDGECOLUMN 2360
#define SCI_SETEDGECOLUMN 2361
#define SCI_GETEDGEMODE 2362
#define SCI_SETEDGEMODE 2363
#define SCI_GETEDGECOLOUR 2364
#define SCI_SETEDGECOLOUR 2365
#define SCI_SEARCHANCHOR 2366
#define SCI_SEARCHNEXT 2367
#define SCI_SEARCHPREV 2368
#define SCI_LINESONSCREEN 2370
#define SCI_USEPOPUP 2371
#define SCI_SELECTIONISRECTANGLE 2372
#define SCI_SETZOOM 2373
#define SCI_GETZOOM 2374
#define SCI_CREATEDOCUMENT 2375
#define SCI_ADDREFDOCUMENT 2376
#define SCI_RELEASEDOCUMENT 2377
#define SCI_GETMODEVENTMASK 2378
#define SCI_SETFOCUS 2380
#define SCI_GETFOCUS 2381
#define SCI_SETSTATUS 2382
#define SCI_GETSTATUS 2383
#define SCI_SETMOUSEDOWNCAPTURES 2384
#define SCI_GETMOUSEDOWNCAPTURES 2385
#define SC_CURSORNORMAL -1
#define SC_CURSORWAIT 4
#define SCI_SETCURSOR 2386
#define SCI_GETCURSOR 2387
#define SCI_SETCONTROLCHARSYMBOL 2388
#define SCI_GETCONTROLCHARSYMBOL 2389
#define SCI_WORDPARTLEFT 2390
#define SCI_WORDPARTLEFTEXTEND 2391
#define SCI_WORDPARTRIGHT 2392
#define SCI_WORDPARTRIGHTEXTEND 2393
#define VISIBLE_SLOP 0x01
#define VISIBLE_STRICT 0x04
#define SCI_SETVISIBLEPOLICY 2394
#define SCI_DELLINELEFT 2395
#define SCI_DELLINERIGHT 2396
#define SCI_SETXOFFSET 2397
#define SCI_GETXOFFSET 2398
#define SCI_CHOOSECARETX 2399
#define SCI_GRABFOCUS 2400
#define CARET_SLOP 0x01
#define CARET_STRICT 0x04
#define CARET_JUMPS 0x10
#define CARET_EVEN 0x08
#define SCI_SETXCARETPOLICY 2402
#define SCI_SETYCARETPOLICY 2403
#define SCI_SETPRINTWRAPMODE 2406
#define SCI_GETPRINTWRAPMODE 2407
#define SCI_SETHOTSPOTACTIVEFORE 2410
#define SCI_SETHOTSPOTACTIVEBACK 2411
#define SCI_SETHOTSPOTACTIVEUNDERLINE 2412
#define SCI_SETHOTSPOTSINGLELINE 2421
#define SCI_PARADOWN 2413
#define SCI_PARADOWNEXTEND 2414
#define SCI_PARAUP 2415
#define SCI_PARAUPEXTEND 2416
#define SCI_POSITIONBEFORE 2417
#define SCI_POSITIONAFTER 2418
#define SCI_COPYRANGE 2419
#define SCI_COPYTEXT 2420
#define SC_SEL_STREAM 0
#define SC_SEL_RECTANGLE 1
#define SC_SEL_LINES 2
#define SCI_SETSELECTIONMODE 2422
#define SCI_GETSELECTIONMODE 2423
#define SCI_GETLINESELSTARTPOSITION 2424
#define SCI_GETLINESELENDPOSITION 2425
#define SCI_LINEDOWNRECTEXTEND 2426
#define SCI_LINEUPRECTEXTEND 2427
#define SCI_CHARLEFTRECTEXTEND 2428
#define SCI_CHARRIGHTRECTEXTEND 2429
#define SCI_HOMERECTEXTEND 2430
#define SCI_VCHOMERECTEXTEND 2431
#define SCI_LINEENDRECTEXTEND 2432
#define SCI_PAGEUPRECTEXTEND 2433
#define SCI_PAGEDOWNRECTEXTEND 2434
#define SCI_STUTTEREDPAGEUP 2435
#define SCI_STUTTEREDPAGEUPEXTEND 2436
#define SCI_STUTTEREDPAGEDOWN 2437
#define SCI_STUTTEREDPAGEDOWNEXTEND 2438
#define SCI_WORDLEFTEND 2439
#define SCI_WORDLEFTENDEXTEND 2440
#define SCI_WORDRIGHTEND 2441
#define SCI_WORDRIGHTENDEXTEND 2442
#define SCI_SETWHITESPACECHARS 2443
#define SCI_SETCHARSDEFAULT 2444
#define SCI_AUTOCGETCURRENT 2445
#define SCI_ALLOCATE 2446
#define SCI_TARGETASUTF8 2447
#define SCI_SETLENGTHFORENCODE 2448
#define SCI_ENCODEDFROMUTF8 2449
#define SCI_FINDCOLUMN 2456
#define SCI_STARTRECORD 3001
#define SCI_STOPRECORD 3002
#define SCI_SETLEXER 4001
#define SCI_GETLEXER 4002
#define SCI_COLOURISE 4003
#define SCI_SETPROPERTY 4004
#define KEYWORDSET_MAX 8
#define SCI_SETKEYWORDS 4005
#define SCI_SETLEXERLANGUAGE 4006
#define SCI_LOADLEXERLIBRARY 4007
#define SC_MOD_INSERTTEXT 0x1
#define SC_MOD_DELETETEXT 0x2
#define SC_MOD_CHANGESTYLE 0x4
#define SC_MOD_CHANGEFOLD 0x8
#define SC_PERFORMED_USER 0x10
#define SC_PERFORMED_UNDO 0x20
#define SC_PERFORMED_REDO 0x40
#define SC_LASTSTEPINUNDOREDO 0x100
#define SC_MOD_CHANGEMARKER 0x200
#define SC_MOD_BEFOREINSERT 0x400
#define SC_MOD_BEFOREDELETE 0x800
#define SC_MODEVENTMASKALL 0xF77
#define SCEN_CHANGE 768
#define SCEN_SETFOCUS 512
#define SCEN_KILLFOCUS 256
#define SCK_DOWN 300
#define SCK_UP 301
#define SCK_LEFT 302
#define SCK_RIGHT 303
#define SCK_HOME 304
#define SCK_END 305
#define SCK_PRIOR 306
#define SCK_NEXT 307
#define SCK_DELETE 308
#define SCK_INSERT 309
#define SCK_ESCAPE 7
#define SCK_BACK 8
#define SCK_TAB 9
#define SCK_RETURN 13
#define SCK_ADD 310
#define SCK_SUBTRACT 311
#define SCK_DIVIDE 312
#define SCMOD_SHIFT 1
#define SCMOD_CTRL 2
#define SCMOD_ALT 4
#define SCN_STYLENEEDED 2000
#define SCN_CHARADDED 2001
#define SCN_SAVEPOINTREACHED 2002
#define SCN_SAVEPOINTLEFT 2003
#define SCN_MODIFYATTEMPTRO 2004
#define SCN_KEY 2005
#define SCN_DOUBLECLICK 2006
#define SCN_UPDATEUI 2007
#define SCN_MODIFIED 2008
#define SCN_MACRORECORD 2009
#define SCN_MARGINCLICK 2010
#define SCN_NEEDSHOWN 2011
#define SCN_PAINTED 2013
#define SCN_USERLISTSELECTION 2014
#define SCN_URIDROPPED 2015
#define SCN_DWELLSTART 2016
#define SCN_DWELLEND 2017
#define SCN_ZOOM 2018
#define SCN_HOTSPOTCLICK 2019
#define SCN_HOTSPOTDOUBLECLICK 2020
#define SCN_CALLTIPCLICK 2021

// To enable these features define INCLUDE_DEPRECATED_FEATURES

#ifdef INCLUDE_DEPRECATED_FEATURES

#define SCI_SETCARETPOLICY 2369
#define CARET_CENTER 0x02
#define CARET_XEVEN 0x08
#define CARET_XJUMPS 0x10

#define SCN_POSCHANGED 2012
#define SCN_CHECKBRACE 2007

#endif

#endif

#define EM_LINEFROMCHAR            201
#define EM_LINEINDEX               187
#define EM_EMPTYUNDOBUFFER         205
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1283
Joined: Fri Feb 10, 2006 02:34 PM
Re: Scintilla
Posted: Tue Feb 28, 2012 12:44 PM

Gracias Antonio, Gracias Paco...

Voy a probar...

Salutacions, saludos, regards

"...programar es fácil, hacer programas es difícil..."

UT Page -> https://carles9000.github.io/
Forum UT -> https://discord.gg/bq8a9yGMWh
HIX -> https://github.com/carles9000/hix
Posts: 1283
Joined: Fri Feb 10, 2006 02:34 PM
Re: Scintilla
Posted: Tue Feb 28, 2012 12:51 PM

scintilla.ch ? :D

Salutacions, saludos, regards

"...programar es fácil, hacer programas es difícil..."

UT Page -> https://carles9000.github.io/
Forum UT -> https://discord.gg/bq8a9yGMWh
HIX -> https://github.com/carles9000/hix
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Scintilla
Posted: Tue Feb 28, 2012 12:52 PM
Ejemplo de uso de Scintilla, implementado por Paco García de Canal Five:

sciedit.prg
Code (fw): Select all Collapse
#include "fivewin.ch"
#include "splitter.ch"
#include "scintilla.ch"

function Main()

   local oWnd, oCode, oBar

   DEFINE WINDOW oWnd  TITLE "Scintilla editor - Noname"

   DEFINE BUTTONBAR oBar SIZE 40, 40 OF oWnd 2007

   DEFINE BUTTON OF oBar NOBORDER NAME "open" ACTION OpenCode(, oCode )

   oCode = TScintilla():New( 0, 0, 1, 1, oWnd )
   oCode:SetFocus()

   oWnd:oClient = oCode

   ACTIVATE WINDOW oWnd MAXIMIZED

return oCode

function OpenCode( cFileName, oCode )

   local lGetFile := Empty( cFileName )

   if lGetFile
      cFileName = cGetFile( "*.prg", "Seleccione fichero prg" )
   
      if ! File( cFileName )
         return .F.
      endif
   endif

   oCode:OpenFile( cFileName )

return oCode
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Scintilla
Posted: Tue Feb 28, 2012 12:57 PM
Todos los ficheros, ejemplo y DLLs :-)

http://code.google.com/p/fivewin-contributions/downloads/detail?name=scintilla.zip&can=2&q=

Implementado por Paco García de Canal Five.

Gracias Paco! :-)
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1283
Joined: Fri Feb 10, 2006 02:34 PM
Re: Scintilla
Posted: Tue Feb 28, 2012 01:12 PM

Antonio ,

Falta scilexer.h

Salutacions, saludos, regards

"...programar es fácil, hacer programas es difícil..."

UT Page -> https://carles9000.github.io/
Forum UT -> https://discord.gg/bq8a9yGMWh
HIX -> https://github.com/carles9000/hix
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Scintilla
Posted: Tue Feb 28, 2012 01:39 PM
scilexer.h

Code (fw): Select all Collapse
// Scintilla source code edit control
/** @file SciLexer.h
 ** Interface to the added lexer functions in the SciLexer version of the edit control.
 **/
// Copyright 1998-2002 by Neil Hodgson <neilh@scintilla.org>
// The License.txt file describes the conditions under which this software may be distributed.

// Most of this file is automatically generated from the Scintilla.iface interface definition
// file which contains any comments about the definitions. HFacer.py does the generation.

#ifndef SCILEXER_H
#define SCILEXER_H

// SciLexer features - not in standard Scintilla

//++Autogenerated -- start of section automatically generated from Scintilla.iface
#define SCLEX_CONTAINER 0
#define SCLEX_NULL 1
#define SCLEX_PYTHON 2
#define SCLEX_CPP 3
#define SCLEX_HTML 4
#define SCLEX_XML 5
#define SCLEX_PERL 6
#define SCLEX_SQL 7
#define SCLEX_VB 8
#define SCLEX_PROPERTIES 9
#define SCLEX_ERRORLIST 10
#define SCLEX_MAKEFILE 11
#define SCLEX_BATCH 12
#define SCLEX_XCODE 13
#define SCLEX_LATEX 14
#define SCLEX_LUA 15
#define SCLEX_DIFF 16
#define SCLEX_CONF 17
#define SCLEX_PASCAL 18
#define SCLEX_AVE 19
#define SCLEX_ADA 20
#define SCLEX_LISP 21
#define SCLEX_RUBY 22
#define SCLEX_EIFFEL 23
#define SCLEX_EIFFELKW 24
#define SCLEX_TCL 25
#define SCLEX_NNCRONTAB 26
#define SCLEX_BULLANT 27
#define SCLEX_VBSCRIPT 28
#define SCLEX_BAAN 31
#define SCLEX_MATLAB 32
#define SCLEX_SCRIPTOL 33
#define SCLEX_ASM 34
#define SCLEX_CPPNOCASE 35
#define SCLEX_FORTRAN 36
#define SCLEX_F77 37
#define SCLEX_CSS 38
#define SCLEX_POV 39
#define SCLEX_LOUT 40
#define SCLEX_ESCRIPT 41
#define SCLEX_PS 42
#define SCLEX_NSIS 43
#define SCLEX_MMIXAL 44
#define SCLEX_CLW 45
#define SCLEX_CLWNOCASE 46
#define SCLEX_LOT 47
#define SCLEX_YAML 48
#define SCLEX_TEX 49
#define SCLEX_METAPOST 50
#define SCLEX_POWERBASIC 51
#define SCLEX_FORTH 52
#define SCLEX_ERLANG 53
#define SCLEX_OCTAVE 54
#define SCLEX_MSSQL 55
#define SCLEX_VERILOG 56
#define SCLEX_KIX 57
#define SCLEX_GUI4CLI 58
#define SCLEX_SPECMAN 59
#define SCLEX_AU3 60
#define SCLEX_APDL 61
#define SCLEX_BASH 62
#define SCLEX_ASN1 63
#define SCLEX_VHDL 64
#define SCLEX_CAML 65
#define SCLEX_BLITZBASIC 66
#define SCLEX_PUREBASIC 67
#define SCLEX_HASKELL 68
#define SCLEX_PHPSCRIPT 69
#define SCLEX_TADS3 70
#define SCLEX_REBOL 71
#define SCLEX_SMALLTALK 72
#define SCLEX_FLAGSHIP 73
#define SCLEX_CSOUND 74
#define SCLEX_FREEBASIC 75
#define SCLEX_AUTOMATIC 1000
#define SCE_P_DEFAULT 0
#define SCE_P_COMMENTLINE 1
#define SCE_P_NUMBER 2
#define SCE_P_STRING 3
#define SCE_P_CHARACTER 4
#define SCE_P_WORD 5
#define SCE_P_TRIPLE 6
#define SCE_P_TRIPLEDOUBLE 7
#define SCE_P_CLASSNAME 8
#define SCE_P_DEFNAME 9
#define SCE_P_OPERATOR 10
#define SCE_P_IDENTIFIER 11
#define SCE_P_COMMENTBLOCK 12
#define SCE_P_STRINGEOL 13
#define SCE_C_DEFAULT 0
#define SCE_C_COMMENT 1
#define SCE_C_COMMENTLINE 2
#define SCE_C_COMMENTDOC 3
#define SCE_C_NUMBER 4
#define SCE_C_WORD 5
#define SCE_C_STRING 6
#define SCE_C_CHARACTER 7
#define SCE_C_UUID 8
#define SCE_C_PREPROCESSOR 9
#define SCE_C_OPERATOR 10
#define SCE_C_IDENTIFIER 11
#define SCE_C_STRINGEOL 12
#define SCE_C_VERBATIM 13
#define SCE_C_REGEX 14
#define SCE_C_COMMENTLINEDOC 15
#define SCE_C_WORD2 16
#define SCE_C_COMMENTDOCKEYWORD 17
#define SCE_C_COMMENTDOCKEYWORDERROR 18
#define SCE_C_GLOBALCLASS 19
#define SCE_H_DEFAULT 0
#define SCE_H_TAG 1
#define SCE_H_TAGUNKNOWN 2
#define SCE_H_ATTRIBUTE 3
#define SCE_H_ATTRIBUTEUNKNOWN 4
#define SCE_H_NUMBER 5
#define SCE_H_DOUBLESTRING 6
#define SCE_H_SINGLESTRING 7
#define SCE_H_OTHER 8
#define SCE_H_COMMENT 9
#define SCE_H_ENTITY 10
#define SCE_H_TAGEND 11
#define SCE_H_XMLSTART 12
#define SCE_H_XMLEND 13
#define SCE_H_SCRIPT 14
#define SCE_H_ASP 15
#define SCE_H_ASPAT 16
#define SCE_H_CDATA 17
#define SCE_H_QUESTION 18
#define SCE_H_VALUE 19
#define SCE_H_XCCOMMENT 20
#define SCE_H_SGML_DEFAULT 21
#define SCE_H_SGML_COMMAND 22
#define SCE_H_SGML_1ST_PARAM 23
#define SCE_H_SGML_DOUBLESTRING 24
#define SCE_H_SGML_SIMPLESTRING 25
#define SCE_H_SGML_ERROR 26
#define SCE_H_SGML_SPECIAL 27
#define SCE_H_SGML_ENTITY 28
#define SCE_H_SGML_COMMENT 29
#define SCE_H_SGML_1ST_PARAM_COMMENT 30
#define SCE_H_SGML_BLOCK_DEFAULT 31
#define SCE_HJ_START 40
#define SCE_HJ_DEFAULT 41
#define SCE_HJ_COMMENT 42
#define SCE_HJ_COMMENTLINE 43
#define SCE_HJ_COMMENTDOC 44
#define SCE_HJ_NUMBER 45
#define SCE_HJ_WORD 46
#define SCE_HJ_KEYWORD 47
#define SCE_HJ_DOUBLESTRING 48
#define SCE_HJ_SINGLESTRING 49
#define SCE_HJ_SYMBOLS 50
#define SCE_HJ_STRINGEOL 51
#define SCE_HJ_REGEX 52
#define SCE_HJA_START 55
#define SCE_HJA_DEFAULT 56
#define SCE_HJA_COMMENT 57
#define SCE_HJA_COMMENTLINE 58
#define SCE_HJA_COMMENTDOC 59
#define SCE_HJA_NUMBER 60
#define SCE_HJA_WORD 61
#define SCE_HJA_KEYWORD 62
#define SCE_HJA_DOUBLESTRING 63
#define SCE_HJA_SINGLESTRING 64
#define SCE_HJA_SYMBOLS 65
#define SCE_HJA_STRINGEOL 66
#define SCE_HJA_REGEX 67
#define SCE_HB_START 70
#define SCE_HB_DEFAULT 71
#define SCE_HB_COMMENTLINE 72
#define SCE_HB_NUMBER 73
#define SCE_HB_WORD 74
#define SCE_HB_STRING 75
#define SCE_HB_IDENTIFIER 76
#define SCE_HB_STRINGEOL 77
#define SCE_HBA_START 80
#define SCE_HBA_DEFAULT 81
#define SCE_HBA_COMMENTLINE 82
#define SCE_HBA_NUMBER 83
#define SCE_HBA_WORD 84
#define SCE_HBA_STRING 85
#define SCE_HBA_IDENTIFIER 86
#define SCE_HBA_STRINGEOL 87
#define SCE_HP_START 90
#define SCE_HP_DEFAULT 91
#define SCE_HP_COMMENTLINE 92
#define SCE_HP_NUMBER 93
#define SCE_HP_STRING 94
#define SCE_HP_CHARACTER 95
#define SCE_HP_WORD 96
#define SCE_HP_TRIPLE 97
#define SCE_HP_TRIPLEDOUBLE 98
#define SCE_HP_CLASSNAME 99
#define SCE_HP_DEFNAME 100
#define SCE_HP_OPERATOR 101
#define SCE_HP_IDENTIFIER 102
#define SCE_HPHP_COMPLEX_VARIABLE 104
#define SCE_HPA_START 105
#define SCE_HPA_DEFAULT 106
#define SCE_HPA_COMMENTLINE 107
#define SCE_HPA_NUMBER 108
#define SCE_HPA_STRING 109
#define SCE_HPA_CHARACTER 110
#define SCE_HPA_WORD 111
#define SCE_HPA_TRIPLE 112
#define SCE_HPA_TRIPLEDOUBLE 113
#define SCE_HPA_CLASSNAME 114
#define SCE_HPA_DEFNAME 115
#define SCE_HPA_OPERATOR 116
#define SCE_HPA_IDENTIFIER 117
#define SCE_HPHP_DEFAULT 118
#define SCE_HPHP_HSTRING 119
#define SCE_HPHP_SIMPLESTRING 120
#define SCE_HPHP_WORD 121
#define SCE_HPHP_NUMBER 122
#define SCE_HPHP_VARIABLE 123
#define SCE_HPHP_COMMENT 124
#define SCE_HPHP_COMMENTLINE 125
#define SCE_HPHP_HSTRING_VARIABLE 126
#define SCE_HPHP_OPERATOR 127
#define SCE_PL_DEFAULT 0
#define SCE_PL_ERROR 1
#define SCE_PL_COMMENTLINE 2
#define SCE_PL_POD 3
#define SCE_PL_NUMBER 4
#define SCE_PL_WORD 5
#define SCE_PL_STRING 6
#define SCE_PL_CHARACTER 7
#define SCE_PL_PUNCTUATION 8
#define SCE_PL_PREPROCESSOR 9
#define SCE_PL_OPERATOR 10
#define SCE_PL_IDENTIFIER 11
#define SCE_PL_SCALAR 12
#define SCE_PL_ARRAY 13
#define SCE_PL_HASH 14
#define SCE_PL_SYMBOLTABLE 15
#define SCE_PL_VARIABLE_INDEXER 16
#define SCE_PL_REGEX 17
#define SCE_PL_REGSUBST 18
#define SCE_PL_LONGQUOTE 19
#define SCE_PL_BACKTICKS 20
#define SCE_PL_DATASECTION 21
#define SCE_PL_HERE_DELIM 22
#define SCE_PL_HERE_Q 23
#define SCE_PL_HERE_QQ 24
#define SCE_PL_HERE_QX 25
#define SCE_PL_STRING_Q 26
#define SCE_PL_STRING_QQ 27
#define SCE_PL_STRING_QX 28
#define SCE_PL_STRING_QR 29
#define SCE_PL_STRING_QW 30
#define SCE_PL_POD_VERB 31
#define SCE_RB_DEFAULT 0
#define SCE_RB_ERROR 1
#define SCE_RB_COMMENTLINE 2
#define SCE_RB_POD 3
#define SCE_RB_NUMBER 4
#define SCE_RB_WORD 5
#define SCE_RB_STRING 6
#define SCE_RB_CHARACTER 7
#define SCE_RB_CLASSNAME 8
#define SCE_RB_DEFNAME 9
#define SCE_RB_OPERATOR 10
#define SCE_RB_IDENTIFIER 11
#define SCE_RB_REGEX 12
#define SCE_RB_GLOBAL 13
#define SCE_RB_SYMBOL 14
#define SCE_RB_MODULE_NAME 15
#define SCE_RB_INSTANCE_VAR 16
#define SCE_RB_CLASS_VAR 17
#define SCE_RB_BACKTICKS 18
#define SCE_RB_DATASECTION 19
#define SCE_RB_HERE_DELIM 20
#define SCE_RB_HERE_Q 21
#define SCE_RB_HERE_QQ 22
#define SCE_RB_HERE_QX 23
#define SCE_RB_STRING_Q 24
#define SCE_RB_STRING_QQ 25
#define SCE_RB_STRING_QX 26
#define SCE_RB_STRING_QR 27
#define SCE_RB_STRING_QW 28
#define SCE_RB_WORD_DEMOTED 29
#define SCE_RB_STDIN 30
#define SCE_RB_STDOUT 31
#define SCE_RB_STDERR 40
#define SCE_RB_UPPER_BOUND 41
#define SCE_B_DEFAULT 0
#define SCE_B_COMMENT 1
#define SCE_B_NUMBER 2
#define SCE_B_KEYWORD 3
#define SCE_B_STRING 4
#define SCE_B_PREPROCESSOR 5
#define SCE_B_OPERATOR 6
#define SCE_B_IDENTIFIER 7
#define SCE_B_DATE 8
#define SCE_B_STRINGEOL 9
#define SCE_B_KEYWORD2 10
#define SCE_B_KEYWORD3 11
#define SCE_B_KEYWORD4 12
#define SCE_B_CONSTANT 13
#define SCE_B_ASM 14
#define SCE_B_LABEL 15
#define SCE_B_ERROR 16
#define SCE_B_HEXNUMBER 17
#define SCE_B_BINNUMBER 18
#define SCE_PROPS_DEFAULT 0
#define SCE_PROPS_COMMENT 1
#define SCE_PROPS_SECTION 2
#define SCE_PROPS_ASSIGNMENT 3
#define SCE_PROPS_DEFVAL 4
#define SCE_L_DEFAULT 0
#define SCE_L_COMMAND 1
#define SCE_L_TAG 2
#define SCE_L_MATH 3
#define SCE_L_COMMENT 4
#define SCE_LUA_DEFAULT 0
#define SCE_LUA_COMMENT 1
#define SCE_LUA_COMMENTLINE 2
#define SCE_LUA_COMMENTDOC 3
#define SCE_LUA_NUMBER 4
#define SCE_LUA_WORD 5
#define SCE_LUA_STRING 6
#define SCE_LUA_CHARACTER 7
#define SCE_LUA_LITERALSTRING 8
#define SCE_LUA_PREPROCESSOR 9
#define SCE_LUA_OPERATOR 10
#define SCE_LUA_IDENTIFIER 11
#define SCE_LUA_STRINGEOL 12
#define SCE_LUA_WORD2 13
#define SCE_LUA_WORD3 14
#define SCE_LUA_WORD4 15
#define SCE_LUA_WORD5 16
#define SCE_LUA_WORD6 17
#define SCE_LUA_WORD7 18
#define SCE_LUA_WORD8 19
#define SCE_ERR_DEFAULT 0
#define SCE_ERR_PYTHON 1
#define SCE_ERR_GCC 2
#define SCE_ERR_MS 3
#define SCE_ERR_CMD 4
#define SCE_ERR_BORLAND 5
#define SCE_ERR_PERL 6
#define SCE_ERR_NET 7
#define SCE_ERR_LUA 8
#define SCE_ERR_CTAG 9
#define SCE_ERR_DIFF_CHANGED 10
#define SCE_ERR_DIFF_ADDITION 11
#define SCE_ERR_DIFF_DELETION 12
#define SCE_ERR_DIFF_MESSAGE 13
#define SCE_ERR_PHP 14
#define SCE_ERR_ELF 15
#define SCE_ERR_IFC 16
#define SCE_ERR_IFORT 17
#define SCE_ERR_ABSF 18
#define SCE_ERR_TIDY 19
#define SCE_ERR_JAVA_STACK 20
#define SCE_BAT_DEFAULT 0
#define SCE_BAT_COMMENT 1
#define SCE_BAT_WORD 2
#define SCE_BAT_LABEL 3
#define SCE_BAT_HIDE 4
#define SCE_BAT_COMMAND 5
#define SCE_BAT_IDENTIFIER 6
#define SCE_BAT_OPERATOR 7
#define SCE_MAKE_DEFAULT 0
#define SCE_MAKE_COMMENT 1
#define SCE_MAKE_PREPROCESSOR 2
#define SCE_MAKE_IDENTIFIER 3
#define SCE_MAKE_OPERATOR 4
#define SCE_MAKE_TARGET 5
#define SCE_MAKE_IDEOL 9
#define SCE_DIFF_DEFAULT 0
#define SCE_DIFF_COMMENT 1
#define SCE_DIFF_COMMAND 2
#define SCE_DIFF_HEADER 3
#define SCE_DIFF_POSITION 4
#define SCE_DIFF_DELETED 5
#define SCE_DIFF_ADDED 6
#define SCE_CONF_DEFAULT 0
#define SCE_CONF_COMMENT 1
#define SCE_CONF_NUMBER 2
#define SCE_CONF_IDENTIFIER 3
#define SCE_CONF_EXTENSION 4
#define SCE_CONF_PARAMETER 5
#define SCE_CONF_STRING 6
#define SCE_CONF_OPERATOR 7
#define SCE_CONF_IP 8
#define SCE_CONF_DIRECTIVE 9
#define SCE_AVE_DEFAULT 0
#define SCE_AVE_COMMENT 1
#define SCE_AVE_NUMBER 2
#define SCE_AVE_WORD 3
#define SCE_AVE_STRING 6
#define SCE_AVE_ENUM 7
#define SCE_AVE_STRINGEOL 8
#define SCE_AVE_IDENTIFIER 9
#define SCE_AVE_OPERATOR 10
#define SCE_AVE_WORD1 11
#define SCE_AVE_WORD2 12
#define SCE_AVE_WORD3 13
#define SCE_AVE_WORD4 14
#define SCE_AVE_WORD5 15
#define SCE_AVE_WORD6 16
#define SCE_ADA_DEFAULT 0
#define SCE_ADA_WORD 1
#define SCE_ADA_IDENTIFIER 2
#define SCE_ADA_NUMBER 3
#define SCE_ADA_DELIMITER 4
#define SCE_ADA_CHARACTER 5
#define SCE_ADA_CHARACTEREOL 6
#define SCE_ADA_STRING 7
#define SCE_ADA_STRINGEOL 8
#define SCE_ADA_LABEL 9
#define SCE_ADA_COMMENTLINE 10
#define SCE_ADA_ILLEGAL 11
#define SCE_BAAN_DEFAULT 0
#define SCE_BAAN_COMMENT 1
#define SCE_BAAN_COMMENTDOC 2
#define SCE_BAAN_NUMBER 3
#define SCE_BAAN_WORD 4
#define SCE_BAAN_STRING 5
#define SCE_BAAN_PREPROCESSOR 6
#define SCE_BAAN_OPERATOR 7
#define SCE_BAAN_IDENTIFIER 8
#define SCE_BAAN_STRINGEOL 9
#define SCE_BAAN_WORD2 10
#define SCE_LISP_DEFAULT 0
#define SCE_LISP_COMMENT 1
#define SCE_LISP_NUMBER 2
#define SCE_LISP_KEYWORD 3
#define SCE_LISP_KEYWORD_KW 4
#define SCE_LISP_SYMBOL 5
#define SCE_LISP_STRING 6
#define SCE_LISP_STRINGEOL 8
#define SCE_LISP_IDENTIFIER 9
#define SCE_LISP_OPERATOR 10
#define SCE_LISP_SPECIAL 11
#define SCE_LISP_MULTI_COMMENT 12
#define SCE_EIFFEL_DEFAULT 0
#define SCE_EIFFEL_COMMENTLINE 1
#define SCE_EIFFEL_NUMBER 2
#define SCE_EIFFEL_WORD 3
#define SCE_EIFFEL_STRING 4
#define SCE_EIFFEL_CHARACTER 5
#define SCE_EIFFEL_OPERATOR 6
#define SCE_EIFFEL_IDENTIFIER 7
#define SCE_EIFFEL_STRINGEOL 8
#define SCE_NNCRONTAB_DEFAULT 0
#define SCE_NNCRONTAB_COMMENT 1
#define SCE_NNCRONTAB_TASK 2
#define SCE_NNCRONTAB_SECTION 3
#define SCE_NNCRONTAB_KEYWORD 4
#define SCE_NNCRONTAB_MODIFIER 5
#define SCE_NNCRONTAB_ASTERISK 6
#define SCE_NNCRONTAB_NUMBER 7
#define SCE_NNCRONTAB_STRING 8
#define SCE_NNCRONTAB_ENVIRONMENT 9
#define SCE_NNCRONTAB_IDENTIFIER 10
#define SCE_FORTH_DEFAULT 0
#define SCE_FORTH_COMMENT 1
#define SCE_FORTH_COMMENT_ML 2
#define SCE_FORTH_IDENTIFIER 3
#define SCE_FORTH_CONTROL 4
#define SCE_FORTH_KEYWORD 5
#define SCE_FORTH_DEFWORD 6
#define SCE_FORTH_PREWORD1 7
#define SCE_FORTH_PREWORD2 8
#define SCE_FORTH_NUMBER 9
#define SCE_FORTH_STRING 10
#define SCE_FORTH_LOCALE 11
#define SCE_MATLAB_DEFAULT 0
#define SCE_MATLAB_COMMENT 1
#define SCE_MATLAB_COMMAND 2
#define SCE_MATLAB_NUMBER 3
#define SCE_MATLAB_KEYWORD 4
#define SCE_MATLAB_STRING 5
#define SCE_MATLAB_OPERATOR 6
#define SCE_MATLAB_IDENTIFIER 7
#define SCE_MATLAB_DOUBLEQUOTESTRING 8
#define SCE_SCRIPTOL_DEFAULT 0
#define SCE_SCRIPTOL_WHITE 1
#define SCE_SCRIPTOL_COMMENTLINE 2
#define SCE_SCRIPTOL_PERSISTENT 3
#define SCE_SCRIPTOL_CSTYLE 4
#define SCE_SCRIPTOL_COMMENTBLOCK 5
#define SCE_SCRIPTOL_NUMBER 6
#define SCE_SCRIPTOL_STRING 7
#define SCE_SCRIPTOL_CHARACTER 8
#define SCE_SCRIPTOL_STRINGEOL 9
#define SCE_SCRIPTOL_KEYWORD 10
#define SCE_SCRIPTOL_OPERATOR 11
#define SCE_SCRIPTOL_IDENTIFIER 12
#define SCE_SCRIPTOL_TRIPLE 13
#define SCE_SCRIPTOL_CLASSNAME 14
#define SCE_SCRIPTOL_PREPROCESSOR 15
#define SCE_ASM_DEFAULT 0
#define SCE_ASM_COMMENT 1
#define SCE_ASM_NUMBER 2
#define SCE_ASM_STRING 3
#define SCE_ASM_OPERATOR 4
#define SCE_ASM_IDENTIFIER 5
#define SCE_ASM_CPUINSTRUCTION 6
#define SCE_ASM_MATHINSTRUCTION 7
#define SCE_ASM_REGISTER 8
#define SCE_ASM_DIRECTIVE 9
#define SCE_ASM_DIRECTIVEOPERAND 10
#define SCE_ASM_COMMENTBLOCK 11
#define SCE_ASM_CHARACTER 12
#define SCE_ASM_STRINGEOL 13
#define SCE_ASM_EXTINSTRUCTION 14
#define SCE_F_DEFAULT 0
#define SCE_F_COMMENT 1
#define SCE_F_NUMBER 2
#define SCE_F_STRING1 3
#define SCE_F_STRING2 4
#define SCE_F_STRINGEOL 5
#define SCE_F_OPERATOR 6
#define SCE_F_IDENTIFIER 7
#define SCE_F_WORD 8
#define SCE_F_WORD2 9
#define SCE_F_WORD3 10
#define SCE_F_PREPROCESSOR 11
#define SCE_F_OPERATOR2 12
#define SCE_F_LABEL 13
#define SCE_F_CONTINUATION 14
#define SCE_CSS_DEFAULT 0
#define SCE_CSS_TAG 1
#define SCE_CSS_CLASS 2
#define SCE_CSS_PSEUDOCLASS 3
#define SCE_CSS_UNKNOWN_PSEUDOCLASS 4
#define SCE_CSS_OPERATOR 5
#define SCE_CSS_IDENTIFIER 6
#define SCE_CSS_UNKNOWN_IDENTIFIER 7
#define SCE_CSS_VALUE 8
#define SCE_CSS_COMMENT 9
#define SCE_CSS_ID 10
#define SCE_CSS_IMPORTANT 11
#define SCE_CSS_DIRECTIVE 12
#define SCE_CSS_DOUBLESTRING 13
#define SCE_CSS_SINGLESTRING 14
#define SCE_CSS_IDENTIFIER2 15
#define SCE_CSS_ATTRIBUTE 16
#define SCE_POV_DEFAULT 0
#define SCE_POV_COMMENT 1
#define SCE_POV_COMMENTLINE 2
#define SCE_POV_NUMBER 3
#define SCE_POV_OPERATOR 4
#define SCE_POV_IDENTIFIER 5
#define SCE_POV_STRING 6
#define SCE_POV_STRINGEOL 7
#define SCE_POV_DIRECTIVE 8
#define SCE_POV_BADDIRECTIVE 9
#define SCE_POV_WORD2 10
#define SCE_POV_WORD3 11
#define SCE_POV_WORD4 12
#define SCE_POV_WORD5 13
#define SCE_POV_WORD6 14
#define SCE_POV_WORD7 15
#define SCE_POV_WORD8 16
#define SCE_LOUT_DEFAULT 0
#define SCE_LOUT_COMMENT 1
#define SCE_LOUT_NUMBER 2
#define SCE_LOUT_WORD 3
#define SCE_LOUT_WORD2 4
#define SCE_LOUT_WORD3 5
#define SCE_LOUT_WORD4 6
#define SCE_LOUT_STRING 7
#define SCE_LOUT_OPERATOR 8
#define SCE_LOUT_IDENTIFIER 9
#define SCE_LOUT_STRINGEOL 10
#define SCE_ESCRIPT_DEFAULT 0
#define SCE_ESCRIPT_COMMENT 1
#define SCE_ESCRIPT_COMMENTLINE 2
#define SCE_ESCRIPT_COMMENTDOC 3
#define SCE_ESCRIPT_NUMBER 4
#define SCE_ESCRIPT_WORD 5
#define SCE_ESCRIPT_STRING 6
#define SCE_ESCRIPT_OPERATOR 7
#define SCE_ESCRIPT_IDENTIFIER 8
#define SCE_ESCRIPT_BRACE 9
#define SCE_ESCRIPT_WORD2 10
#define SCE_ESCRIPT_WORD3 11
#define SCE_PS_DEFAULT 0
#define SCE_PS_COMMENT 1
#define SCE_PS_DSC_COMMENT 2
#define SCE_PS_DSC_VALUE 3
#define SCE_PS_NUMBER 4
#define SCE_PS_NAME 5
#define SCE_PS_KEYWORD 6
#define SCE_PS_LITERAL 7
#define SCE_PS_IMMEVAL 8
#define SCE_PS_PAREN_ARRAY 9
#define SCE_PS_PAREN_DICT 10
#define SCE_PS_PAREN_PROC 11
#define SCE_PS_TEXT 12
#define SCE_PS_HEXSTRING 13
#define SCE_PS_BASE85STRING 14
#define SCE_PS_BADSTRINGCHAR 15
#define SCE_NSIS_DEFAULT 0
#define SCE_NSIS_COMMENT 1
#define SCE_NSIS_STRINGDQ 2
#define SCE_NSIS_STRINGLQ 3
#define SCE_NSIS_STRINGRQ 4
#define SCE_NSIS_FUNCTION 5
#define SCE_NSIS_VARIABLE 6
#define SCE_NSIS_LABEL 7
#define SCE_NSIS_USERDEFINED 8
#define SCE_NSIS_SECTIONDEF 9
#define SCE_NSIS_SUBSECTIONDEF 10
#define SCE_NSIS_IFDEFINEDEF 11
#define SCE_NSIS_MACRODEF 12
#define SCE_NSIS_STRINGVAR 13
#define SCE_NSIS_NUMBER 14
#define SCE_NSIS_SECTIONGROUP 15
#define SCE_NSIS_PAGEEX 16
#define SCE_NSIS_FUNCTIONDEF 17
#define SCE_NSIS_COMMENTBOX 18
#define SCE_MMIXAL_LEADWS 0
#define SCE_MMIXAL_COMMENT 1
#define SCE_MMIXAL_LABEL 2
#define SCE_MMIXAL_OPCODE 3
#define SCE_MMIXAL_OPCODE_PRE 4
#define SCE_MMIXAL_OPCODE_VALID 5
#define SCE_MMIXAL_OPCODE_UNKNOWN 6
#define SCE_MMIXAL_OPCODE_POST 7
#define SCE_MMIXAL_OPERANDS 8
#define SCE_MMIXAL_NUMBER 9
#define SCE_MMIXAL_REF 10
#define SCE_MMIXAL_CHAR 11
#define SCE_MMIXAL_STRING 12
#define SCE_MMIXAL_REGISTER 13
#define SCE_MMIXAL_HEX 14
#define SCE_MMIXAL_OPERATOR 15
#define SCE_MMIXAL_SYMBOL 16
#define SCE_MMIXAL_INCLUDE 17
#define SCE_CLW_DEFAULT 0
#define SCE_CLW_LABEL 1
#define SCE_CLW_COMMENT 2
#define SCE_CLW_STRING 3
#define SCE_CLW_USER_IDENTIFIER 4
#define SCE_CLW_INTEGER_CONSTANT 5
#define SCE_CLW_REAL_CONSTANT 6
#define SCE_CLW_PICTURE_STRING 7
#define SCE_CLW_KEYWORD 8
#define SCE_CLW_COMPILER_DIRECTIVE 9
#define SCE_CLW_RUNTIME_EXPRESSIONS 10
#define SCE_CLW_BUILTIN_PROCEDURES_FUNCTION 11
#define SCE_CLW_STRUCTURE_DATA_TYPE 12
#define SCE_CLW_ATTRIBUTE 13
#define SCE_CLW_STANDARD_EQUATE 14
#define SCE_CLW_ERROR 15
#define SCE_CLW_DEPRECATED 16
#define SCE_LOT_DEFAULT 0
#define SCE_LOT_HEADER 1
#define SCE_LOT_BREAK 2
#define SCE_LOT_SET 3
#define SCE_LOT_PASS 4
#define SCE_LOT_FAIL 5
#define SCE_LOT_ABORT 6
#define SCE_YAML_DEFAULT 0
#define SCE_YAML_COMMENT 1
#define SCE_YAML_IDENTIFIER 2
#define SCE_YAML_KEYWORD 3
#define SCE_YAML_NUMBER 4
#define SCE_YAML_REFERENCE 5
#define SCE_YAML_DOCUMENT 6
#define SCE_YAML_TEXT 7
#define SCE_YAML_ERROR 8
#define SCE_TEX_DEFAULT 0
#define SCE_TEX_SPECIAL 1
#define SCE_TEX_GROUP 2
#define SCE_TEX_SYMBOL 3
#define SCE_TEX_COMMAND 4
#define SCE_TEX_TEXT 5
#define SCE_METAPOST_DEFAULT 0
#define SCE_METAPOST_SPECIAL 1
#define SCE_METAPOST_GROUP 2
#define SCE_METAPOST_SYMBOL 3
#define SCE_METAPOST_COMMAND 4
#define SCE_METAPOST_TEXT 5
#define SCE_METAPOST_EXTRA 6
#define SCE_ERLANG_DEFAULT 0
#define SCE_ERLANG_COMMENT 1
#define SCE_ERLANG_VARIABLE 2
#define SCE_ERLANG_NUMBER 3
#define SCE_ERLANG_KEYWORD 4
#define SCE_ERLANG_STRING 5
#define SCE_ERLANG_OPERATOR 6
#define SCE_ERLANG_ATOM 7
#define SCE_ERLANG_FUNCTION_NAME 8
#define SCE_ERLANG_CHARACTER 9
#define SCE_ERLANG_MACRO 10
#define SCE_ERLANG_RECORD 11
#define SCE_ERLANG_SEPARATOR 12
#define SCE_ERLANG_NODE_NAME 13
#define SCE_ERLANG_UNKNOWN 31
#define SCE_MSSQL_DEFAULT 0
#define SCE_MSSQL_COMMENT 1
#define SCE_MSSQL_LINE_COMMENT 2
#define SCE_MSSQL_NUMBER 3
#define SCE_MSSQL_STRING 4
#define SCE_MSSQL_OPERATOR 5
#define SCE_MSSQL_IDENTIFIER 6
#define SCE_MSSQL_VARIABLE 7
#define SCE_MSSQL_COLUMN_NAME 8
#define SCE_MSSQL_STATEMENT 9
#define SCE_MSSQL_DATATYPE 10
#define SCE_MSSQL_SYSTABLE 11
#define SCE_MSSQL_GLOBAL_VARIABLE 12
#define SCE_MSSQL_FUNCTION 13
#define SCE_MSSQL_STORED_PROCEDURE 14
#define SCE_MSSQL_DEFAULT_PREF_DATATYPE 15
#define SCE_MSSQL_COLUMN_NAME_2 16
#define SCE_V_DEFAULT 0
#define SCE_V_COMMENT 1
#define SCE_V_COMMENTLINE 2
#define SCE_V_COMMENTLINEBANG 3
#define SCE_V_NUMBER 4
#define SCE_V_WORD 5
#define SCE_V_STRING 6
#define SCE_V_WORD2 7
#define SCE_V_WORD3 8
#define SCE_V_PREPROCESSOR 9
#define SCE_V_OPERATOR 10
#define SCE_V_IDENTIFIER 11
#define SCE_V_STRINGEOL 12
#define SCE_V_USER 19
#define SCE_KIX_DEFAULT 0
#define SCE_KIX_COMMENT 1
#define SCE_KIX_STRING1 2
#define SCE_KIX_STRING2 3
#define SCE_KIX_NUMBER 4
#define SCE_KIX_VAR 5
#define SCE_KIX_MACRO 6
#define SCE_KIX_KEYWORD 7
#define SCE_KIX_FUNCTIONS 8
#define SCE_KIX_OPERATOR 9
#define SCE_KIX_IDENTIFIER 31
#define SCE_GC_DEFAULT 0
#define SCE_GC_COMMENTLINE 1
#define SCE_GC_COMMENTBLOCK 2
#define SCE_GC_GLOBAL 3
#define SCE_GC_EVENT 4
#define SCE_GC_ATTRIBUTE 5
#define SCE_GC_CONTROL 6
#define SCE_GC_COMMAND 7
#define SCE_GC_STRING 8
#define SCE_GC_OPERATOR 9
#define SCE_SN_DEFAULT 0
#define SCE_SN_CODE 1
#define SCE_SN_COMMENTLINE 2
#define SCE_SN_COMMENTLINEBANG 3
#define SCE_SN_NUMBER 4
#define SCE_SN_WORD 5
#define SCE_SN_STRING 6
#define SCE_SN_WORD2 7
#define SCE_SN_WORD3 8
#define SCE_SN_PREPROCESSOR 9
#define SCE_SN_OPERATOR 10
#define SCE_SN_IDENTIFIER 11
#define SCE_SN_STRINGEOL 12
#define SCE_SN_REGEXTAG 13
#define SCE_SN_SIGNAL 14
#define SCE_SN_USER 19
#define SCE_AU3_DEFAULT 0
#define SCE_AU3_COMMENT 1
#define SCE_AU3_COMMENTBLOCK 2
#define SCE_AU3_NUMBER 3
#define SCE_AU3_FUNCTION 4
#define SCE_AU3_KEYWORD 5
#define SCE_AU3_MACRO 6
#define SCE_AU3_STRING 7
#define SCE_AU3_OPERATOR 8
#define SCE_AU3_VARIABLE 9
#define SCE_AU3_SENT 10
#define SCE_AU3_PREPROCESSOR 11
#define SCE_AU3_SPECIAL 12
#define SCE_AU3_EXPAND 13
#define SCE_AU3_COMOBJ 14
#define SCE_APDL_DEFAULT 0
#define SCE_APDL_COMMENT 1
#define SCE_APDL_COMMENTBLOCK 2
#define SCE_APDL_NUMBER 3
#define SCE_APDL_STRING 4
#define SCE_APDL_OPERATOR 5
#define SCE_APDL_WORD 6
#define SCE_APDL_PROCESSOR 7
#define SCE_APDL_COMMAND 8
#define SCE_APDL_SLASHCOMMAND 9
#define SCE_APDL_STARCOMMAND 10
#define SCE_APDL_ARGUMENT 11
#define SCE_APDL_FUNCTION 12
#define SCE_SH_DEFAULT 0
#define SCE_SH_ERROR 1
#define SCE_SH_COMMENTLINE 2
#define SCE_SH_NUMBER 3
#define SCE_SH_WORD 4
#define SCE_SH_STRING 5
#define SCE_SH_CHARACTER 6
#define SCE_SH_OPERATOR 7
#define SCE_SH_IDENTIFIER 8
#define SCE_SH_SCALAR 9
#define SCE_SH_PARAM 10
#define SCE_SH_BACKTICKS 11
#define SCE_SH_HERE_DELIM 12
#define SCE_SH_HERE_Q 13
#define SCE_ASN1_DEFAULT 0
#define SCE_ASN1_COMMENT 1
#define SCE_ASN1_IDENTIFIER 2
#define SCE_ASN1_STRING 3
#define SCE_ASN1_OID 4
#define SCE_ASN1_SCALAR 5
#define SCE_ASN1_KEYWORD 6
#define SCE_ASN1_ATTRIBUTE 7
#define SCE_ASN1_DESCRIPTOR 8
#define SCE_ASN1_TYPE 9
#define SCE_ASN1_OPERATOR 10
#define SCE_VHDL_DEFAULT 0
#define SCE_VHDL_COMMENT 1
#define SCE_VHDL_COMMENTLINEBANG 2
#define SCE_VHDL_NUMBER 3
#define SCE_VHDL_STRING 4
#define SCE_VHDL_OPERATOR 5
#define SCE_VHDL_IDENTIFIER 6
#define SCE_VHDL_STRINGEOL 7
#define SCE_VHDL_KEYWORD 8
#define SCE_VHDL_STDOPERATOR 9
#define SCE_VHDL_ATTRIBUTE 10
#define SCE_VHDL_STDFUNCTION 11
#define SCE_VHDL_STDPACKAGE 12
#define SCE_VHDL_STDTYPE 13
#define SCE_VHDL_USERWORD 14
#define SCE_CAML_DEFAULT 0
#define SCE_CAML_IDENTIFIER 1
#define SCE_CAML_TAGNAME 2
#define SCE_CAML_KEYWORD 3
#define SCE_CAML_KEYWORD2 4
#define SCE_CAML_LINENUM 5
#define SCE_CAML_OPERATOR 6
#define SCE_CAML_NUMBER 7
#define SCE_CAML_CHAR 8
#define SCE_CAML_STRING 9
#define SCE_CAML_COMMENT 10
#define SCE_CAML_COMMENT1 11
#define SCE_CAML_COMMENT2 12
#define SCE_CAML_COMMENT3 13
#define SCE_HA_DEFAULT 0
#define SCE_HA_IDENTIFIER 1
#define SCE_HA_KEYWORD 2
#define SCE_HA_NUMBER 3
#define SCE_HA_STRING 4
#define SCE_HA_CHARACTER 5
#define SCE_HA_CLASS 6
#define SCE_HA_MODULE 7
#define SCE_HA_CAPITAL 8
#define SCE_HA_DATA 9
#define SCE_HA_IMPORT 10
#define SCE_HA_OPERATOR 11
#define SCE_HA_INSTANCE 12
#define SCE_HA_COMMENTLINE 13
#define SCE_HA_COMMENTBLOCK 14
#define SCE_HA_COMMENTBLOCK2 15
#define SCE_HA_COMMENTBLOCK3 16
#define SCE_T3_DEFAULT 0
#define SCE_T3_X_DEFAULT 1
#define SCE_T3_PREPROCESSOR 2
#define SCE_T3_BLOCK_COMMENT 3
#define SCE_T3_LINE_COMMENT 4
#define SCE_T3_OPERATOR 5
#define SCE_T3_KEYWORD 6
#define SCE_T3_NUMBER 7
#define SCE_T3_IDENTIFIER 8
#define SCE_T3_S_STRING 9
#define SCE_T3_D_STRING 10
#define SCE_T3_X_STRING 11
#define SCE_T3_LIB_DIRECTIVE 12
#define SCE_T3_MSG_PARAM 13
#define SCE_T3_HTML_TAG 14
#define SCE_T3_HTML_DEFAULT 15
#define SCE_T3_HTML_STRING 16
#define SCE_T3_USER1 17
#define SCE_T3_USER2 18
#define SCE_T3_USER3 19
#define SCE_REBOL_DEFAULT 0
#define SCE_REBOL_COMMENTLINE 1
#define SCE_REBOL_COMMENTBLOCK 2
#define SCE_REBOL_PREFACE 3
#define SCE_REBOL_OPERATOR 4
#define SCE_REBOL_CHARACTER 5
#define SCE_REBOL_QUOTEDSTRING 6
#define SCE_REBOL_BRACEDSTRING 7
#define SCE_REBOL_NUMBER 8
#define SCE_REBOL_PAIR 9
#define SCE_REBOL_TUPLE 10
#define SCE_REBOL_BINARY 11
#define SCE_REBOL_MONEY 12
#define SCE_REBOL_ISSUE 13
#define SCE_REBOL_TAG 14
#define SCE_REBOL_FILE 15
#define SCE_REBOL_EMAIL 16
#define SCE_REBOL_URL 17
#define SCE_REBOL_DATE 18
#define SCE_REBOL_TIME 19
#define SCE_REBOL_IDENTIFIER 20
#define SCE_REBOL_WORD 21
#define SCE_REBOL_WORD2 22
#define SCE_REBOL_WORD3 23
#define SCE_REBOL_WORD4 24
#define SCE_REBOL_WORD5 25
#define SCE_REBOL_WORD6 26
#define SCE_REBOL_WORD7 27
#define SCE_REBOL_WORD8 28
#define SCE_SQL_DEFAULT 0
#define SCE_SQL_COMMENT 1
#define SCE_SQL_COMMENTLINE 2
#define SCE_SQL_COMMENTDOC 3
#define SCE_SQL_NUMBER 4
#define SCE_SQL_WORD 5
#define SCE_SQL_STRING 6
#define SCE_SQL_CHARACTER 7
#define SCE_SQL_SQLPLUS 8
#define SCE_SQL_SQLPLUS_PROMPT 9
#define SCE_SQL_OPERATOR 10
#define SCE_SQL_IDENTIFIER 11
#define SCE_SQL_SQLPLUS_COMMENT 13
#define SCE_SQL_COMMENTLINEDOC 15
#define SCE_SQL_WORD2 16
#define SCE_SQL_COMMENTDOCKEYWORD 17
#define SCE_SQL_COMMENTDOCKEYWORDERROR 18
#define SCE_SQL_USER1 19
#define SCE_SQL_USER2 20
#define SCE_SQL_USER3 21
#define SCE_SQL_USER4 22
#define SCE_ST_DEFAULT 0
#define SCE_ST_STRING 1
#define SCE_ST_NUMBER 2
#define SCE_ST_COMMENT 3
#define SCE_ST_SYMBOL 4
#define SCE_ST_BINARY 5
#define SCE_ST_BOOL 6
#define SCE_ST_SELF 7
#define SCE_ST_SUPER 8
#define SCE_ST_NIL 9
#define SCE_ST_GLOBAL 10
#define SCE_ST_RETURN 11
#define SCE_ST_SPECIAL 12
#define SCE_ST_KWSEND 13
#define SCE_ST_ASSIGN 14
#define SCE_ST_CHARACTER 15
#define SCE_ST_SPEC_SEL 16
#define SCE_FS_DEFAULT 0
#define SCE_FS_COMMENT 1
#define SCE_FS_COMMENTLINE 2
#define SCE_FS_COMMENTDOC 3
#define SCE_FS_COMMENTLINEDOC 4
#define SCE_FS_COMMENTDOCKEYWORD 5
#define SCE_FS_COMMENTDOCKEYWORDERROR 6
#define SCE_FS_KEYWORD 7
#define SCE_FS_KEYWORD2 8
#define SCE_FS_KEYWORD3 9
#define SCE_FS_KEYWORD4 10
#define SCE_FS_NUMBER 11
#define SCE_FS_STRING 12
#define SCE_FS_PREPROCESSOR 13
#define SCE_FS_OPERATOR 14
#define SCE_FS_IDENTIFIER 15
#define SCE_FS_DATE 16
#define SCE_FS_STRINGEOL 17
#define SCE_FS_CONSTANT 18
#define SCE_FS_ASM 19
#define SCE_FS_LABEL 20
#define SCE_FS_ERROR 21
#define SCE_FS_HEXNUMBER 22
#define SCE_FS_BINNUMBER 23
#define SCE_CSOUND_DEFAULT 0
#define SCE_CSOUND_COMMENT 1
#define SCE_CSOUND_NUMBER 2
#define SCE_CSOUND_OPERATOR 3
#define SCE_CSOUND_INSTR 4
#define SCE_CSOUND_IDENTIFIER 5
#define SCE_CSOUND_OPCODE 6
#define SCE_CSOUND_HEADERSTMT 7
#define SCE_CSOUND_USERKEYWORD 8
#define SCE_CSOUND_COMMENTBLOCK 9
#define SCE_CSOUND_PARAM 10
#define SCE_CSOUND_ARATE_VAR 11
#define SCE_CSOUND_KRATE_VAR 12
#define SCE_CSOUND_IRATE_VAR 13
#define SCE_CSOUND_GLOBAL_VAR 14
#define SCE_CSOUND_STRINGEOL 15
#define SCLEX_ASP 29
#define SCLEX_PHP 30
//--Autogenerated -- end of section automatically generated from Scintilla.iface

#endif
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Scintilla
Posted: Tue Mar 06, 2012 10:01 AM
regards, saludos

Antonio Linares
www.fivetechsoft.com

Continue the discussion