
            include  L:\AsmEdit\include\Windows.inc
            include  user32.inc
            include  kernel32.inc
            include  gdi32.inc
            include  comctl32.inc
            include  comdlg32.inc
            include  imagehlp.inc
            include  shell32.inc
            include  advapi32.inc

            include  L:\AsmEdit\include\DSPMACRO.asm

         includelib  user32.lib
         includelib  kernel32.lib
         includelib  gdi32.lib
         includelib  comctl32.lib
         includelib  comdlg32.lib
         includelib  imagehlp.lib
         includelib  shell32.lib
         includelib  advapi32.lib

;===================================================
; PROTO, MACRO, and Data section
;===================================================
WinMain         PROTO  :DWORD, :DWORD, :DWORD, :DWORD
CreateTab       PROTO  :DWORD
ChgBmpColor     PROTO  :DWORD
Find            PROTO  :DWORD, :DWORD, :DWORD, :DWORD, :DWORD
FindReplace     PROTO  :DWORD, :DWORD, :DWORD, :DWORD
RichEditProc    PROTO  :DWORD, :DWORD, :DWORD, :DWORD
WorkEditProc    PROTO  :DWORD, :DWORD, :DWORD, :DWORD
BuildEditProc   PROTO  :DWORD, :DWORD, :DWORD, :DWORD
ChgColor        PROTO  :DWORD, :DWORD, :DWORD, :DWORD
SetPreferences  PROTO  :DWORD, :DWORD, :DWORD, :DWORD
SetCodeHelper    PROTO  :DWORD, :DWORD, :DWORD, :DWORD
GotoLineProc    PROTO  :DWORD, :DWORD, :DWORD, :DWORD
Translate       PROTO  :DWORD, :DWORD, :DWORD, :DWORD
CopyFiles       PROTO  :DWORD, :DWORD, :DWORD, :DWORD
ProjectMaint    PROTO  :DWORD, :DWORD, :DWORD, :DWORD
CreateProject   PROTO  :DWORD, :DWORD, :DWORD, :DWORD
KeywordMaint    PROTO  :DWORD, :DWORD, :DWORD, :DWORD
DrawButt        PROTO  :DWORD
HiliteSelection PROTO  :DWORD
CenterSel       PROTO  :DWORD
ProcessMRUFiles PROTO  :DWORD, :DWORD, :DWORD, :DWORD, :DWORD, :DWORD
GetRegPath      PROTO  :DWORD, :DWORD
FillBuffer      PROTO  :DWORD, :DWORD, :BYTE, :DWORD
WriteReadMem    PROTO  :DWORD, :DWORD
DrawList        PROTO  :DWORD
DoMenus         PROTO  :DWORD, :DWORD
FindRep         PROTO  :DWORD, :DWORD, :DWORD

FindDlgProc     PROTO  :DWORD, :DWORD, :DWORD, :DWORD
FindIt          PROTO  :DWORD
ConvTabs        PROTO  :DWORD, :DWORD, :DWORD, :DWORD
AsciiBase       PROTO  :DWORD, :DWORD, :DWORD
BaseAscii       PROTO  :DWORD, :DWORD, :DWORD, :DWORD, :DWORD, :DWORD, :DWORD
StripFileExt    PROTO  :DWORD
StripFileName   PROTO  :DWORD
LoadTreeView    PROTO  :DWORD, :DWORD
ReadTheFile     PROTO  :DWORD
ChkDelProj      PROTO  :DWORD, :DWORD, :DWORD, :DWORD
DelProj         PROTO  :DWORD, :DWORD
SplitBarProc    PROTO  :DWORD, :DWORD, :DWORD, :DWORD
Snippets        PROTO  :DWORD, :DWORD, :DWORD, :DWORD
BuildHex        PROTO  :DWORD, :DWORD, :DWORD, :DWORD
GetSysInfo      PROTO  :DWORD, :DWORD, :DWORD, :DWORD
CodeHelper      PROTO  :DWORD, :DWORD, :DWORD
SetValues       PROTO  :DWORD, :DWORD, :DWORD
ShiftLine       PROTO  :DWORD, :DWORD
ChkSplitter     PROTO  :DWORD, :DWORD
QuickCode       PROTO  :DWORD, :DWORD
RegQuerySZ      PROTO  :DWORD, :DWORD
RegQuery        PROTO  :DWORD, :DWORD
RegSetSZ        PROTO  :DWORD, :DWORD

TBSep    MACRO hTool
           mov     tbb.iBitmap, 0
           mov     tbb.idCommand, 0
           mov     tbb.fsState, TBSTATE_ENABLED
           mov     tbb.fsStyle, TBSTYLE_SEP
        INVOKE     SendMessage, hTool, TB_ADDBUTTONS, 1, addr tbb
          ENDM

TBButt   MACRO hTool, BmpID, CmdID, Text
           mov     tbb.iBitmap, BmpID    ; Button image number
           mov     tbb.idCommand, CmdID  ; Command ID number
           mov     tbb.fsState, TBSTATE_ENABLED
           mov     tbb.fsStyle, TBSTYLE_BUTTON
           mov     tbb.dwData, 0
           mov     tbb.iString, Text
        INVOKE     SendMessage, hTool, TB_ADDBUTTONS, 1, addr tbb
          ENDM

MOVmb    MACRO Var1, Var2
        pushad 
           lea     esi, Var2
           lea     edi, Var1
           mov     al, [esi]
           mov     [edi], al
         popad
          ENDM

MOVmd    MACRO Var1, Var2
          push     Var2
           pop     Var1
          ENDM

.const

; File
IDM_NEW                 equ 6001
IDM_OPEN                equ 6002
IDM_OPENHEX             equ 6003
IDM_SAVE                equ 6004
IDM_SAVEAS              equ 6005
IDM_SAVEHEXAS           equ 6006
IDM_SAVEUNIAS           equ 6007
IDM_SAVEALL             equ 6008
IDM_CLOSETAB            equ 6009
IDM_CLOSEALL            equ 6010
IDM_PAGESETUP           equ 6011
IDM_PRINT               equ 6012
IDM_EXIT                equ 6013

;Edit
IDM_CUT                 equ 6021
IDM_COPY                equ 6022
IDM_PASTE               equ 6023
IDM_DELETE              equ 6024
IDM_UNDO                equ 6025
IDM_REDO                equ 6026
IDM_UNDOREDO            equ 6027
IDM_CLRCLIP             equ 6028
IDM_FINDTEXT            equ 6029
IDM_FINDNEXT            equ 6030
IDM_FINDPREV            equ 6031
IDM_REPLACETEXT         equ 6032
IDM_COMMENT             equ 6033
IDM_UNCOMMENT           equ 6034
IDM_SHIFTR              equ 6035
IDM_SHIFTL              equ 6036
IDM_SHIFTTO             equ 6037
IDM_GOTO                equ 6038
IDM_SELALL              equ 6039

;Format
IDM_EDITF               equ 6051
IDM_LINEF               equ 6052
IDM_TREEF               equ 6053
IDM_PRINTF              equ 6054
IDM_COLOR               equ 6055
IDM_ITALIC              equ 6056
IDM_HILITEBW            equ 6057
IDM_INDENT              equ 6058
IDM_CONSTR              equ 6059
IDM_COLUMN              equ 6060
IDM_CONVTAB             equ 6061

; Bookmark

; View
IDM_PROJECTS            equ 6081
IDM_DRIVES              equ 6082
IDM_QUICKC              equ 6083
IDM_USERC               equ 6084
IDM_AUTOR               equ 6085
IDM_FUNCT               equ 6086

; Options
IDM_PREF                equ 6091
IDM_CODEHELPER          equ 6092
IDM_FILTERDEF           equ 6093
IDM_FILTER01            equ 6094
IDM_FILTER02            equ 6095
IDM_FILTERMAINT         equ 6096
IDM_EDITMENU            equ 6097
IDM_EDITUSER            equ 6098
IDM_TOGLINES            equ 6099
IDM_LEADING             equ 6100
IDM_HILITEOFF           equ 6101
IDM_HILITE01            equ 6102
IDM_HILITE02            equ 6103
IDM_HILITE03            equ 6104
IDM_HILITE04            equ 6105
IDM_HILITE05            equ 6106
IDM_HILITECLRA          equ 6107
IDM_EXPORT              equ 6108
IDM_IMPORT              equ 6109
IDM_DISPLY              equ 6110
IDM_ROOT                equ 6111
IDM_BIN                 equ 6112
IDM_PGM                 equ 6113
IDM_INC                 equ 6114
IDM_USER01              equ 6115
IDM_USER02              equ 6116
IDM_BACKUP              equ 6117
IDM_SETUP               equ 6118

; Projects
IDM_PROJECTDEF          equ 6121
IDM_PROJECT01           equ 6122
IDM_PROJECT02           equ 6123
IDM_PROJECT03           equ 6124
IDM_PROJECT04           equ 6125
IDM_PROJECT05           equ 6126
IDM_PROJECTMAINT        equ 6127
IDM_PROJECTWITH         equ 6128
IDM_PROJECTWITHOUT      equ 6129
IDM_POINTER             equ 6130
IDM_PROJECTDLL          equ 6131

; Copy
IDM_COPYF               equ 6135

; Window
IDM_SPLIT               equ 6141

; Build
IDM_COMPILE             equ 6151
IDM_ASSEMBLE            equ 6152
IDM_LINK                equ 6153
IDM_BUILD               equ 6154
IDM_CLOSEBUILD          equ 6155

; Addin
IDM_ADDIN               equ 6171

; Tools
IDM_RESOPEN             equ 6181
IDM_RESCLOSE            equ 6182
IDM_CTRLOPEN            equ 6183
IDM_CTRLCLOSE           equ 6184
IDM_BUTTBUILD           equ 6185
IDM_TABBUILD            equ 6186
IDM_TOOLBUILD           equ 6187
IDM_MDIEDIT             equ 6188
IDM_EDITSAMP            equ 6189
IDM_MDINOEDIT           equ 6190
IDM_NOEDITSAMP          equ 6191
IDM_SNIP                equ 6192
IDM_ASCII               equ 6193
IDM_CALC                equ 6194

; Help
IDM_HELP                equ 6211
IDM_WHELP               equ 6212
IDM_VERSION             equ 6213
IDM_SYSINFO             equ 6214

; Toolbar thats not in menu
IDM_CODEH               equ 6221
IDM_WORK                equ 6222
IDM_MULT                equ 6223
IDM_RUN                 equ 6224
IDM_DOS                 equ 6225
IDM_SYNTAX              equ 6226

; Misc
IDM_TABSW               equ 6231
IDM_STEPBYSTEP          equ 2001

; Resources
IDR_ACCEL               equ 7001
IDR_MENU3               equ 7002

; Dialogs
IDD_INCLIB              equ 7027
IDD_SCROLLDATA          equ 7026
IDD_USERTEMP            equ 7025
IDD_CREATE              equ 7024
IDD_CREATEFOLDER        equ 7023
IDD_CUSTMENU            equ 7011
IDD_USERNAME            equ 7021
IDD_SNIP                equ 7022
IDD_PRTHEAD             equ 7028
IDD_SYSINFO             equ 7029
IDD_VERSION             equ 7030
IDD_KWMAINT             equ 7031
IDD_GROUPS              equ 7032
IDD_APIDATA             equ 7033

ID_TIMER1               equ 5000

UM_BASE                 equ  WM_USER+4000
UM_SUBCLASSCTRL         equ  UM_BASE+00  ; wParam=0, lParam=lpWndProc
UM_SETHANDLES           equ  UM_BASE+01  ; wParam=0, lParam=lpHandles
UM_SETSYNTAXWORDS       equ  UM_BASE+02  ; wParam=Color, lParam=lpszWords
UM_SETFONTS             equ  UM_BASE+03  ; wParam=0, lParam=lpFONT
UM_GETFONTS             equ  UM_BASE+04  ; wParam=0, lParam=lpFONT          ; NO
UM_SETCOLORS            equ  UM_BASE+05  ; wParam=0, lParam=lpCOLOR
UM_GETCOLORS            equ  UM_BASE+06  ; wParam=0, lParam=lpCOLOR         ; NO
UM_SELBARWIDTH          equ  UM_BASE+07  ; wParam=Width, lParam=0           ; NO
UM_LINENUMWIDTH         equ  UM_BASE+08  ; wParam=Width, lParam=0
UM_MOUSEWHEEL           equ  UM_BASE+09  ; wParam=Lines, lParam=0
UM_TABWIDTH             equ  UM_BASE+10  ; wParam=Chars, lParam=0
UM_SMOOTHSCROLL         equ  UM_BASE+11  ; wParam=0, lParam=TRUE/FALSE
UM_HILIGHT              equ  UM_BASE+12  ; wParam=NoHiLite, lParam=0
UM_ITALIC               equ  UM_BASE+13  ; wParam=TRUE/FALSE, lParam=0
UM_BLACKWHITE           equ  UM_BASE+14  ; wParam=BlackWhite, lParam=0
UM_AUTOINDENT           equ  UM_BASE+15  ; wParam=TRUE/FALSE, lParam=0
UM_LEADINGZEROS         equ  UM_BASE+16  ; wParam=0, lParam=0
UM_SETSCROLLSPEED       equ  UM_BASE+17  ; wParam=0, lParam=ScrollSpeed
UM_GETSCROLLSPEED       equ  UM_BASE+18  ; wParam=0, lParam=0
UM_SETHILITELINE        equ  UM_BASE+19  ; wParam=Line, lParam=Color
UM_GETHILITELINE        equ  UM_BASE+20  ; wParam=Line, lParam=0            ; NO
UM_CLEARHILIGHTS        equ  UM_BASE+21  ; wParam=HiLite, lParam=0
UM_SETCONSTRAIN         equ  UM_BASE+22  ; wParam=0, lParam=TRUE/FALSE
UM_GETCONSTRAIN         equ  UM_BASE+23  ; wParam=0, lParam=0
UM_SETCOLUMNBLK         equ  UM_BASE+24  ; wParam=0, lParam=TRUE/FALSE
UM_SETALLBOOKMARKS      equ  UM_BASE+25  ; wParam=BookArray, lParam=0
UM_GETALLBOOKMARKS      equ  UM_BASE+26  ; wParam=BookArray, lParam=0
UM_SETBOOKMARK          equ  UM_BASE+27  ; wParam=Line, lParam=TypeBook
UM_GETBOOKMARK          equ  UM_BASE+28  ; wParam=Line, lParam=0
UM_NEXTBOOKMARK         equ  UM_BASE+29  ; wParam=Line, lParam=TypeBook
UM_PREVBOOKMARK         equ  UM_BASE+30  ; wParam=Line, lParam=TypeBook
UM_FINDBOOKMARK         equ  UM_BASE+31  ; wParam=BookID, lParam=0
UM_GETCURBOOKMARK       equ  UM_BASE+32  ; wParam=0, lParam=0
UM_CLRBOOKMARKS         equ  UM_BASE+33  ; wParam=0, lParam=TypeBook
UM_REDRAW               equ  UM_BASE+34  ; wParam=0, lParam=TRUE/FALSE (Update Now)
UM_REPAINT              equ  UM_BASE+35  ; wParam=0, lParam=TRUE/FALSE (Update Now)
UM_SHOWLINES            equ  UM_BASE+36  ; wParam=0, lParam=0
UM_CHECKLINES           equ  UM_BASE+37  ; wParam=0, lParam=0
UM_SHOWSPLIT            equ  UM_BASE+38  ; wParam=0, lParam=0
UM_GETLONGESTLINE       equ  UM_BASE+39  ; wParam=0, lParam=0 (Set Hor Scrollbar)
UM_GETHSCROLLHANDLE     equ  UM_BASE+40  ; wParam=0, lParam=0
UM_CENTERSEL            equ  UM_BASE+41  ; wParam=0, lParam=0               ; NO
UM_BMCALLBACK           equ  UM_BASE+42  ; wParam=0, lParam=lpBmProc        ; NO
UM_GETUNICODE           equ  UM_BASE+60  ; wParam=0, lParam=0
UM_GETSELECT            equ  UM_BASE+61  ; wParam=0, lParam=0
UM_HTML                 equ  UM_BASE+62  ; wParam=Html, lParam=0
UM_HTMLCOLOR            equ  UM_BASE+63  ; wParam=0, lParam=lpCOLOR
UM_NOHORZSCROLL         equ  UM_BASE+64  ; wParam=0, lParam=TRUE/FALSE

STATE_NOHILITE          equ  0020h       ; No color hilighting
STATE_BLACKWHITE        equ  0040h       ; Black and white
STATE_HTML              equ  0080h       ; Html file
STATE_HILITE1           equ  1           ; Hilite #1
STATE_HILITE2           equ  2           ; Hilite #2
STATE_HILITE3           equ  3           ; Hilite #3
STATE_HILITE4           equ  4           ; Hilite #4
STATE_HILITE5           equ  5           ; Error selection
STATE_HILITE6           equ  6           ; Build selection
STATE_HILITE9           equ  9           ; Clear all selections

IDM_GETDWORDS           equ  WM_USER+50
IDM_GETPROC             equ  WM_USER+51
IDM_GETDATA             equ  WM_USER+52

MAXWORDMEM              equ  32*1024

.data
szTestDel      db  'L:\AsmEdit\Projects\BBBB',0

AppName        db  'AsmEdit V5.0 - ',0
ClassName      db  'AsmEdit V5.0',0

RichEdDLL      db  'RichEdit44.dll',0
RichEdit       db  'RichEdit44',0

RichEdDLLMS    db  'RICHED20.DLL',0
RichEditMS     db  'RichEdit20A',0

;TypeAhead      db  'TypeAhead.dll',0

LibNameR       db  'ResEdit.dll',0
FunctNameR     db  'FunctionEntry',0
LibNameCB      db  'CtrlBuild.dll',0
FunctNameCB    db  'FunctionEntry',0
FuncNameWC     db  'CloseIt',0
LibNameSB      db  'StepByStep.dll',0
FuncNameSB     db  'StepByStep',0
;FuncNameTAL    db  'LoadLookUp',0
;FuncNameTA     db  'TypeAhead',0

ToolClass      db  'ToolbarWindow32',0
StatClass      db  'msctls_statusbar32',0
TabClass       db  'SysTabControl32',0
TreeClass      db  'SysTreeView32',0
ListViewClass  db  'SysListView32',0
ListBoxClass   db  'listbox',0
ComboClass     db  'combobox',0
StaticClass    db  'static',0
ButtonClass    db  'button',0
WorkClass      db  'WorkArea',0
BuildClass     db  'Build',0
KeyWordClass   db  'KeyWord',0

szUntitled     db  '(Untitled 0)',0
szResEdit      db  '* ResEdit *',0
szCtrlBuild    db  '* CtrlBuild *',0

;HKEY_CURRENT_USER\Software\EW Software\AsmEdit V5\[Drive Path]
;HKEY_CURRENT_USER\Software\EW Software\AsmEdit V5\Pref Drive On

szREGSZ        db  'REG_SZ',0
szRedit        db  'Software\EW Software\AsmEdit V5\',0
szRegAsmEdit   db  'RegAsmEdit.reg',0
szRegBuildMenu db  'RegBuildMenu.reg',0
szRegAddinMenu db  'RegAddinMenu.reg',0
szRegToolsMenu db  'RegToolsMenu.reg',0
szRegHelpMenu  db  'RegHelpMenu.reg',0
szExpAsmEdit1  db  'regedit.exe /e ',0
szRegistryDir  db  'Registry\',0
szExpAsmEdit2  db  ' "HKEY_CURRENT_USER\Software\EW Software\AsmEdit V5"',0
szImpAsmEdit1  db  'regedit.exe /s ',0

rDEFr          db  '[Default Root Dir]',0
rDEFb          db  '[Default Bin Dir.]',0
rDEFp          db  '[Default Proj Dir]',0
rDEFi          db  '[Default Inc Dir.]',0
rDEFs          db  '[Default Back Dir]',0
rDEFu1         db  '[Default Use1 Dir]',0
rDEFu2         db  '[Default Use2 Dir]',0
rDEFh          db  '[Win32 Help Dir..]',0
rDEFl          db  '[Default load Dir]',0

szFilterGroup  db  'Filter Group',0
szProjGroup    db  'Project Group',0
szProjN        db  'szProject Name',0
szProjN01      db  'szProject Name01',0
szProjN02      db  'szProject Name02',0
szProjN03      db  'szProject Name03',0
szProjN04      db  'szProject Name04',0
szProjN05      db  'szProject Name05',0
ProjNArray     dd  szProjN,szProjN01,szProjN02,szProjN03,szProjN04,szProjN05
DrivePath      db  '[Drive Path]',0

szColor        db  'Colors Misc',0
szColor01      db  'Colors Syntax',0
szCustClrs     db  'Colors Cust',0

szKeywU01      db  'Keyw User01',0
szKeywU02      db  'Keyw User02',0
szFiltU01      db  'Filter User01',0
szFiltU02      db  'Filter User02',0

szAuto         db  'Pref AutoSave On',0
szCloseOn      db  'Pref Close On',0
szFilterOn     db  'Pref Filter On',0
szFontZoomOn   db  'Pref FontZoom On',0
szItalicOn     db  'Pref Italic On',0
szLeadingOn    db  'Pref Leading On',0
szIndentOn     db  'Pref Indent On',0
szAutoRefOn    db  'Pref AutoRef On',0
szMaxWin       db  'Pref Max Win on',0
szNoHiLiteBW   db  'Pref NoHiLiteBW On',0
szProjWnd      db  'Pref Project On',0
szDrvWnd       db  'Pref Drive On',0
szSmoothOn     db  'Pref Smooth On',0
szSyntaxOn     db  'Pref Syntax On',0
szCodeHelper   db  'Pref CodeHelper On',0
szBeepOn       db  'Pref Beeper On',0
szSpaceAfter   db  'Pref SpaceAfter On',0
szRightAlign   db  'Pref RightAlign On',0
szMinMatch     db  'Pref MinMatch Val',0
szIndent       db  'Pref Indent Val',0
szOutdent      db  'Pref Outdent Val',0
szQuick        db  'Pref QuickC On',0
szUser         db  'Pref UserC On',0

szWndPos       db  'Pos Window',0
szSplitterH    db  'Pos SplitH',0
szSplitterV    db  'Pos SplitV',0

szLineWth      db  'Set Line Width',0
szShiftT       db  'Set Shift To',0
szSpaceN       db  'Set Space Num',0
szSpeed        db  'Set Scroll Speed',0
szTabWth       db  'Set Tab Width',0
szWheelNum     db  'Set Wheel Num',0

FontNameCN     db  'Courier New',0
FontMS         db  'MS Sans Serif',0
FontQT         db  'QuickType',0
FontQTC        db  'QuickType Condensed',0
FontTah        db  'Tahoma',0
PopupMenu      db  'PopupMenu',0
szWorkArea     db  'Work Area',0
szWorkAreaS    db  'Snippets Work Area',0
szBuild        db  'Build',0

szHelp         db  'AsmEdit.HLP',0

szLines        db  'Lines',0
szButtTxt1     db  'Goto',0
szButtTxt2     db  'Build',0
szButtTxt3     db  'Projects',0
szButtTxt4     db  'Filter On    ',0
szButtTxt5     db  'Filter Off',0
szUK01         db  ' User Keywords 01',0
szUK02         db  ' User Keywords 02',0
szUF01         db  ' User File Filters 01',0
szUF02         db  ' User File Filters 02',0
szFiltMaint    db  'User File Filter Maintence',0

szShowI        db  '&Auto Indent On      Ctrl+F1',0
szHideI        db  '&Auto Indent Off     Ctrl+F1',0
szShowL        db  'Line Leading &Zeros On',0
szHideL        db  'Line Leading &Zeros Off',0
szShowC        db  '&Constrain Cursor On',0
szHideC        db  '&Constrain Cursor Off',0
szShowS        db  'Column &Select On',0
szHideS        db  'Column &Select Off',0
szShowP        db  'Show &Project Tree',0
szHideP        db  'Hide &Project Tree',0
szShowD        db  'Show &Drive Tree',0
szHideD        db  'Hide &Drive Tree',0
szShowQ        db  'Show &Quick Code',0
szHideQ        db  'Hide &Quick Code',0
szShowU        db  'Show &User Code',0
szHideU        db  'Hide &User Code',0
szShowF        db  'Show &Properties List',0
szHideF        db  'Hide &Properties List',0

DatePict       db  "MM'-'dd'-'yyyy",0
TimePict       db  "hh':'mm':'ss tt",0 

szIND          db  'Ind',0
szCUR          db  'Cur',0
szCOL          db  'Col',0
szREF          db  'Ref',0

MenuName       db  'MainMenu',0
szAddins       db  'Addins\',0
szProjects     db  'Projects\',0
szPointer      db  'Pointers\',0
szTemplates    db  'Templates\',0
szHelpFiles    db  'HelpFiles\',0
szLangCode     db  'LangCode.txt',0
szUserCode     db  'Res\UserCode.wrd',0
szButBuild     db  'Programs\ButBuild\ButBuild.exe',0
szTabBuild     db  'Programs\TabBuild\TabBuild.exe',0
szToolBuild    db  'Programs\ToolBuild\ToolBuild.exe',0
szCalculator   db  'Programs\Calculator\EWCalc.exe',0
szAddinTemp    db  'Addins\AddinTemp\AddinTemp.asm',0
szIncInc1      db  '            include  ',0
szIncLib1      db  '         includelib  ',0
szIncInc2      db  'include\',0
szIncLib2      db  'lib\',0

szRegClass     db  'RegClass.gen',0
szOpenFile     db  'OpenFile.gen',0
szSaveFile     db  'SaveFile.gen',0
szCreateFileR  db  'CreateFileR.gen',0
szCreateFileW  db  'CreateFileW.gen',0
szChooseFont   db  'ChooseFont.gen',0
szChooseColor  db  'ChooseColor.gen',0
szFindRep      db  'FindReplace.gen',0
szPageSetup    db  'PageSetupDlg.gen',0
szPrint        db  'PrintDlg.gen',0
szAllCommon    db  'Working example of all the above.gen',0
szAllComExe    db  'CommonDlgs.exe',0
szMDIEdit      db  'MDIEdit.gen',0
szMDINoEdit    db  'MDINoEdit.gen',0
szMDIwEexe     db  'MDIwE.exe',0
szMDInEexe     db  'MDInE.exe',0
szTemplatesC   db  'Templates\Common\',0
szTemplatesM   db  'Templates\MDI\',0
szTemplatesU   db  'Templates\User\',0
szSnippets     db  'Templates\Snippets\',0

szSetup        db  'Setup.exe',0
szAsmEdit      db  'AsmEdit.exe',0
szDos          db  '\COMMAND.COM',0
szBackUp       db  'BackUp\',0
szIncr         db  '[0]',0
szByteCode     db  ' ',0

szOpen         db  'open',0

szUserC        db  'UserCode',0
szUser0140     db  '1u',0

szPtrS         db  'SaveBuild',0
szR1           db  'R1',0
szA1           db  'A1',0
szL1           db  'L1',0
szL2           db  'L2',0

szPointUser    db  'PointUser\',0
szPointers     db  'Pointers\',0
szPointers01   db  'Pointers01\',0
szPointers02   db  'Pointers02\',0
szPointers03   db  'Pointers03\',0
szPointers04   db  'Pointers04\',0
szPointers05   db  'Pointers05\',0
PtrArray       dd  szPointers,szPointers01,szPointers02,szPointers03,szPointers04,szPointers05

szBookMarks    db  'BookMarks',0
szBookFill     db  '00000000,',0

szPROC         db  ' PROC',0
szPATHR        db  'PATHR',0
szXXXX         db  'xxxx',0
szAsmEditDir   db  '\AsmEditDir\',0
szHutchDir     db  '\HutchDir\',0

szPgm01        db  'Pgm01',0
szPgm02        db  'Pgm02',0
szPgm03        db  'Pgm03',0
szPgm04        db  'Pgm04',0
szPgm05        db  'Pgm05',0
szPgm06        db  'Pgm06',0
szPgm07        db  'Pgm07',0
szPgm08        db  'Pgm08',0
szPgm10        db  'Pgm10',0
szPgm11        db  'Pgm11',0
szEWCallDLL    db  'EWCallDLL',0
szCallDLLb     db  'EWCallDLL.bat',0

szError1       db  'The RichEdit44.DLL was not found!',0
szError2       db  'The file has been modified.',0dh,0ah
               db  'Do you wish to save it?',0
szError3       db  'You must display a Project file first.',0
szError4       db  'You need to run the Setup.exe program',0dh,0ah
               db  'to do anything meaningful.',0dh,0ah,0dh,0ah
               db  'Would you like to run it now?',0
szError5       db  'Could not find the above DLL.',0
szError6       db  'You Must Enter A Project Name.',0
szError7       db  'Are you sure you want to DELETE the above Project.',0
szError8       db  'The Program file(s) are not in the Project Directory.',0dh,0ah,0dh,0ah
               db  'Are you sure you want to DELETE the above Project?',0
szError9       db  'There was a problem trying to delete the Project.',0
szError10      db  'There was a problem trying to delete the Folder.',0
szError11      db  'The Project Pointer File Already Exists.',0
szError12      db  'There Was A Problem Creating The Projects Folder.',0
szError13      db  'The Contents Of The Templates Folder Is Corrupted.',0
szError14      db  'You Must Make A Selection To Use Return.',0
szError15      db  'You Must Make A Group Selection First.',0
szError16      db  'You Must Enter A Path Name.',0
szError17      db  'The Project Pointer File Does Not Exists.',0
szError18      db  'The Project Name Does Not Match The Selected Name.',0
szError20      db  'The above path for the tree was not found!',0
szAccess       db  'This program is in use.',0dh,0ah
               db  'Would you like to open it as read only ?',0

szFileError    db  'Could not create or open requested file',0
szNoSel        db  'No item was selected.',0
szMultSel      db  'Only select one item.',0
szSeparate     db  'Would you like this code placed', 0Dh,0Ah
               db  '       in a separate Window?',0
AboutMsg			db  'AsmEdit Assembler Editor version 5.0.0.1',13,10,'Ewayne (C) 2003-2004',0

szOpenTitle    db  'Open File',0
szSaveTitle    db  'Save File As',0
szFilter       db  'All Files',0,'*.*',0,0

WndPos         dd  0, 0, 0, 0
SplitH         dd  0, 188, 144, 190
SplitV         dd  144, 0, 146, 442

szNULL         db  0,0
szHT           db  09h,0
szCR           db  0dh,0
szCRLF         db  0dh,0ah,0
sz0x           db  '0x',0
szX            db  'X',0
szSlashB       db  '\',0
szPer          db  '.',0
szCom          db  ',',0
szAll          db  '*.*',0
szSpace2       db  '   ',0

szFR           db  'Find And Replace',0
FindEnd        db  'There Are No More Matches.'
               db  0Dh,0Ah
               db  'Would You Like To Restart From The'
TopBot         db  ' Top?    '
               db  0
Top            db  ' Top?    '
Bot            db  ' Bottom? '

szOpened       db  'File opened size: = ',0
szSize         db  'File size: = ',0
szSaved        db  'File saved size: = ',0
szStart        db  'start:',0
szCtrl         db  ' Ctrl+',0
szAlt          db  ' Alt+',0
szBook         db  'Book'
BookNum        db  8 dup(?),0

LineData       db  ' Row: '
cnt1           db  '000001' ;6 dup(?)
               db  '  of  '
cnt2           db  '000001' ;6 dup(?)
               db  '    Col: '
cnt3           db  '0001' ;4 dup(?)
               db  '  of  '
cnt4           db  '0001',0 ;4 dup(?),0

szLine         db  'Line: '
SLNum          db  6 dup(?)

keyw01         db  'eax,ah,al,ax,es,ebx,bh,bl,bx,bp,ecx,ch,cl,cx,cs,edx,dh,dl,dx,ds,di,esi,edi,ebp,esp,'
               db  'cr0,cr2,cr3,dr0,dr1,dr2,dr3,dr6,dr7,fs,gs,mm0,mm1,mm2,mm3,mm4,mm5,mm6,mm7,si,sp,ss,st,'
               db  'tr3,tr4,tr5,tr6,tr7,xmm0,xmm1,xmm2,xmm3,',0
keyw02         db  'invoke,call,covoke',0
keyw03         db  'addr,offset,lengthof,sizeof,ptr,uses,',0
keyw04         db  'db,dw,dd,dq,df,dt,d,byte,sbyte,tbyte,word,sword,dword,sdword,fword,qword,real4,real8,real10,',0
keyw05         db  '.if,.elseif,.else,.endif,.while,.break,.endw,.continue,.repeat,.until,.untilcxz,while,else,elseif,endif,forc,'
               db  'repeat,loope,loopz,loopne,loopnz,loop,local,style,exstyle,caption,font,struct,ends,',0
keyw06         db  'add,adc,aaa,aad,aam,aas,sub,sbb,mul,imul,div,idiv,daa,das,shrd,shld,shr,shl,rol,ror,and,or,xor,not,neg,'
               db  'inc,dec,xadd,xchg,xlat,xlatb,toolbar,menu,stringtable,accelerators,dialog,dialogex,',0
keyw07         db  'stc,std,sti,clc,cld,cli,clts,cmc,cmov,repne,repe,repnz,repz,rep,scas,scasb,scasd,scasw,cmps,cmpsb,cmpsd,cmpsw,'
               db  'cmpxchg,cmpxchg8b,lods,stos,lodsb,stosb,lodsw,stosw,lodsd,stosd,movs,movsb,movsd,movsw,movsx,movzx,bsf,'
               db  'out,outs,outsb,outsd,outsw,ins,insb,insd,insw,bsr,bswap,dup,',0
keyw08         db  'push,pop,pushad,popad,pusha,popa,pushf,popf,pushfd,popfd,lea,cwde,cwd,cbw,cdq,lds,les,lfs,lgs,lidt,lldt,lmsw,'
               db  'lsl,lss,lar,ltr,lgdt,enter,leave,esc,assume,setng,setnge,setnl,setnle,setno,setnp,setns,setnz,seto,'
               db  'setp,setpe,setpo,sets,setz,sgdt,popup,',0
keyw09         db  'mov,cmp,je,jne,jnb,jna,jnl,jmp,jecxz,jz,jnz,jae,ja,jbe,jb,jle,js,jns,jl,jg,jge,jae,jng,jnae,jnbe,'
               db  'jo,jp,jpe,jpo,jc,jcxz,jnc,jnge,jnle,jno,jnp,proc,endp,ret,retf,retn,include,includelib,#include,#define,'
               db  'setae,setb,setbe,setc,sete,setg,setge,setl,setle,setna,setnae,setnb,setnc,setne,bt,btc,btr,bts,rsm,rcl,rcr,'
               db  'menuitem,icon,bitmap,cursor,control,shift,alt,ltext,ctext,rtext,pushbutton,defpushbutton,edittext,groupbox,'
               db  'sal,sar,equ,eq,macro,endm,test,sahf,lahf,nop,int,into,bound,iret,str,virtkey,alt,shift,'
               db  'loadoncall,moveable,discardable,',0
keyw10         db  'finit,fld,fild,fld1,fldcw,fldenv,fldenvd,fldenvw,fldl2e,fldl2t,fldlg2,fldln2,fldpi,fldz,fadd,faddp,fsub,fsubp,'
               db  'fsubr,fsubrp,fisub,fisubr,fdiv,fdivp,fdivr,fdivrp,fidiv,fidivr,fmul,fmulp,fimul,fbld,fbstp,fchs,fclex,'
               db  'fcom,fcomp,fcompp,fcos,fdecstp,fdisi,feni,ffree,fiadd,ficom,ficomp,fincstp,fist,fistp,fst,fstp,'
               db  'ftst,fstcw,fstenv,fstenvd,fstenvw,fstsw,fabs,fnclex,fndisi,fneni,fninit,fnop,fnsave,fnsaved,fnsavew,'
               db  'fnstcw,fnstenv,fnstenvd,fnstenvw,fnstsw,fpatan,fprem,fprem1,fptan,frndint,frstor,frstord,'
               db  'frstorw,fsave,fsaved,fsavew,fscale,fsetpm,fsin,fsincos,fsqrt,fucom,fucomp,fucompp,fwait,'
               db  'fxam,fxch,fxtract,fyl2x,fyl2xp1,f2xm1,',0
keyw11         db  'title,comment,.286,.386,.486,.586,.686,.mmx,.model,option,.list,.const,.data,.data?,.code,begin,end,'
               db  'separator,',0
keyw12         db  'movmd,movmw,movmb,msgbox,tbbutt,tbsep,m2m,@CatStr,@code,@CodeSize,@Cpu,@CurSeg,@data,@DataSize,'
               db  '@Date,@Environ,@fardata,@fardata?,@FileCur,@FileName,@InStr,@Interface,@Line,@Model,@SizeStr,'
               db  '@stack,@SubStr,@Time,@Version,@WordSize,',0
keyw13         db  'emms,movd,movq,packuswb,pand,pandn,pcmpeqb,pcmpeqd,pcmpeqw,pcmpgtb,pcmpgtd,pcmpgtw,pmaddwd,pmulhw,'
               db  'pmullw,por,pslld,psllq,psllw,psrad,psraw,psrld,psrlq,psrlw,psubb,psubd,psubsb,psubsw,'
               db  'psubusb,psubusw,psubw,punpckhbw,punpckhdq,punpckhwd,punpcklbw,punpckldq,punpcklwd,pxor,'
               db  'packsswb,packssdw,paddb,paddw,paddd,paddsb,paddsw,paddusb,paddusw,',0
keyw14         db  'verinf1,versioninfo,fileversion,productversion,fileos,filetype,block,value,',0
.data?
Userkeyw01     db  1024 dup(?)
Userkeyw02     db  1024 dup(?)
.data
KeyArray       dd  keyw01,keyw02,keyw03,keyw04,keyw05,keyw06,keyw07,keyw08,keyw09,keyw10,
                   keyw11,keyw12,keyw13,keyw14,Userkeyw01,Userkeyw02

Color01        dd  00404080h,04000000h,00ff8000h,000000a6h,00ffd000h,00c000c0h,
                   00400040h,0011d952h,00ff0000h,00002200h,00ac5757h,000045d5h,
                   00005000h,000080ffh,0080ff00h,000045d5h,00000000h,00797900h,
                   00ff48a4h,00800080h,00404080h,00b36666h,000080ffh,00ff00ffh,
                   00008080h,0000ff00h,00400040h,000083d6h,00ff0000h,000000ffh,
                   00ffaa00h,00c080ffh,00ac5757h,000045d5h

; Print
Color02        dd  00404080h,04000000h,00ff8000h,00404040h,00ffff00h,00c000c0h,
                   00400040h,0011d952h,00ff0000h,00002200h,00ac5757h,000045d5h,
                   00005000h,000080ffh
;00ff0000h
;00ffff00h
;00808080h
;0000ffffh
;00008080h
;00800080h
;000000ffh
;00ff00ffh
;00c0c0c0h

DefColor       dd  00fffff4h,00005000h,00eaffeah,00efffffh,00000000h,00fffff4h,
                   00ffffebh,00008000h,00ffffffh,00004080h,00808000h,00ffffceh,
                   00c0f0c0h,00c4ffffh,00edc7f8h,0000ffffh,020000ffh,00ff8000h,
                   00ff0080h,00000000h,00ff0080h,00ff00ffh,000000a0h,00808000h,
                   00000000h,000080ffh,000000ffh,00ffffffh

DefColor01     dd  00404080h,04000000h,00ff8000h,000000a6h,00ffd000h,00c000c0h,
                   00400040h,0011d952h,00ff0000h,00002200h,00ac5757h,000045d5h,
                   00005000h,000080ffh,0080ff00h,000045d5h,00000000h,00797900h,
                   00ff48a4h,00800080h,00404080h,00b36666h,000080ffh,00ff00ffh,
                   00008080h,0000ff00h,00400040h,000083d6h,00ff0000h,000000ffh,
                   00ffaa00h,00c080ffh,00ac5757h,000045d5h

DefCustColor   dd  00fffff4h,00005000h,00eaffeah,00ffffcdh,00c0f0c0h,00c4ffffh,
                   00edc7f8h,000000a0h,00ffd000h,00ac5757h,000000a6h,00c000c0h,
                   0011d952h,00002200h,000045d5h,00ffffebh

NumRangeS      db  '001,002,004,006,008,010,015,020,025,030,035,040,045,050,055,'
               db  '060,065,070,075,080,085,090,095,100,110,120,150,200,250,300,',0
szComboProps   db  'Macros,Constants,Data area,Structures,Procedures,Labels,Labels sorted,',0
szIncLib       db  'Windows,user32,kernel32,gdi32,comctl32,comdlg32,advapi32,shell32,'
               db  'tapi32,winmm,winspool,ole32,version,',0

FilterDef      db  'asm,bat,def,inc,rc,ini,',0
Filter01       db  'ccp,def,dsp,dsw,h,ini,',0
Filter02       db  'htm,html,java,ini,',0
.data?
UserFilt01     db  256  dup(?)
UserFilt02     db  256  dup(?)
.data
szTestTxt      db  '      title   Editor',0dh,0ah
               db  "         comment '==========='",0dh,0ah
               db  '         include  Build.asm',0dh,0ah
               db  '.code',0dh,0ah,0dh,0ah
               db  '; H A V E  A  N I C E  D A Y!',0dh,0ah
               db  'start:',0dh,0ah
               db  '      INVOKE     GetModuleHandle, NULL',0dh,0ah

               db  '         mov     hInst, eax',0dh,0ah,0dh,0ah
               db  'WndProc PROC uses ebx hwnd:DWORD',0dh,0ah
               db  'LOCAL    rect:RECT',0dh,0ah
               db  '      INVOKE     GetSystemMetrics, SM_CYCAPTION',0dh,0ah
               db  '         mov     eax, lParam      ; Get width',0dh,0ah
               db  '         and     eax, 0ffffh      ; Lowword',0dh,0ah
               db  '         shr     eax, 2           ; /4',0dh,0ah
               db  '         mov     [sbParts+4], eax',0dh,0ah
               db  "      .if ExtType == 'a' && ExtType + 1 == 's'",0dh,0ah
               db  '            mov     eax, dword ptr[esi+edx+4]',0dh,0ah
               db  '           push     ebx',0dh,0ah
               db  '            pop     w1',0dh,0ah
               db  '      .endif',0dh,0ah
               db  '        call     ChgFont',0dh,0ah
               db  '        fdiv     ST(0), ST(1)',0dh,0ah
               db  'Ret0:',0dh,0ah
               db  '         xor    eax, eax',0dh,0ah
               db  '         ret',0dh,0ah
               db  'WndProc ENDP',0dh,0ah,0dh,0ah,0

szTestHtml     db  'Email: <A HREF="mailto:yooper@kalamazoo.net">yooper@kalamazoo.net</A>',0dh,0ah
               db  '<FONT FACE="Times New Roman,Arial" SIZE="+0"><B>',0dh,0ah
               db  '<BR>',0dh,0ah
               db  '</B></FONT>',0dh,0ah
               db  '<!-- <IMG SRC="images/Tball.gif" WIDTH="14" HEIGHT="14" ALIGN="absmiddle"> -->',0dh,0ah
               db  '<TABLE ALIGN="CENTER" WIDTH="100%" CELLSPACING="0" CELLPADDING="1" BORDER="1">',0dh,0ah
               db  '<TR>',0dh,0ah
               db  '    <TD NOWRAP WIDTH="100%" COLSPAN="4" ALIGN="CENTER" VALIGN="TOP" BGCOLOR="#91c8ff">',0dh,0ah
               db  '    <FONT FACE="Times New Roman,Arial,Helvetica" SIZE="+0" COLOR="#000000"><B>AsmEdit V5.0</B>',0dh,0ah
               db  '    <IMG SRC="images/Tball.gif" WIDTH="14" HEIGHT="14" ALIGN="absmiddle">',0dh,0ah
               db  '    </FONT></TD>',0dh,0ah
               db  '</TR>',0dh,0ah
               db  '</TABLE>',0dh,0ah
               db  '<COMMENT> 1234567890 <\COMMENT>',0dh,0ah
               db  '<LI>',0dh,0ah
               db  '&nbsp; Be carefull',0dh,0ah
               db  '   <BLOCKQUOTE>',0dh,0ah
               db  '      Watch your thoughts; They become words. <BR>',0dh,0ah
               db  '      Watch your words; They become actions. <BR>',0dh,0ah
               db  '      Watch your actions; They become habits. <BR>',0dh,0ah
               db  '      Watch your habits; They become character. <BR>',0dh,0ah
               db  '      Watch your character; It becomes your destiny. <BR>',0dh,0ah
               db  '      Frank Outlaw',0dh,0ah
               db  '   </BLOCKQUOTE>',0dh,0ah
               db  '<P>',0dh,0ah
               db  '<UL>',0dh,0ah
               db  '<LI>',0dh,0ah
               db  '   Never underestimate the power of stupid people in large groups.',0dh,0ah
               db  '<LI>',0dh,0ah
               db  '</UL>',0dh,0ah,0

LineWth        dd  37
SHIFT          dd  10
SPACE          dd  3
Speed          dd  100
TAB            dd  3
WheelNum       dd  3
szTab          dd  09h

szFontEdit     db  'FontEdit',0
szFontLine     db  'FontLine',0
szFontTree     db  'FontTree',0
FontEdit       LOGFONT <-12,0,0,0,400,FALSE,FALSE,FALSE,0,0,0,0,0,'Courier New'>
FontLine       LOGFONT <-11,0,0,0,400,FALSE,FALSE,FALSE,0,0,0,0,0,'QuickType Condensed'>
FontTree       LOGFONT <-11,0,0,0,400,FALSE,FALSE,FALSE,0,0,0,0,0,'Tahoma'>

.data?
;---------- [Keep the following sixteen varibles intact
hWnd           dd  ?
hMenu          dd  ?
hWndTool       dd  ?
hWndStat       dd  ?
hREdit         dd  ?
MenuID         dd  ?
ProjType       dd  ?
TempCode       dd  ?

lpBaseAscii    dd  ?
lpAsciiBase    dd  ?
lpEnaDisMenu   dd  ?

lpRoot         dd  ?
lpPath         dd  ?
lpName         dd  ?
lpProject      dd  ?
lpProPath      dd  ?
lpRegKey       dd  ?
;-------------------

ProjDrive      dd  ?
ProjGroup      dd  ?
FilterGroup    dd  ?

hInst          dd  ?
hIcon          dd  ?
CommandLine    dd  ?
MainExit       dd  ?
hREdDll        dd  ?
hREdDllMS      dd  ?
hCodeHelper     dd  ?
lpRichEdit     dd  ?
hAccel         dd  ?
hSMenu         dd  ?
hSMenuD        dd  ?
hWMenu         dd  ?
hWMenuD        dd  ?
hParent        dd  ?
hParentD       dd  ?
hWndDlg        dd  ?
hWndDlgG       dd  ?
hWndTree       dd  ?
hWndTreeD      dd  ?
hWndList       dd  ?
hWndListD      dd  ?
hItem          dd  ?
hItemD         dd  ?
ItemNew        dd  ?
hBR            dd  ?
hBRD           dd  ?
hBRS           dd  ?
hBrush         dd  ?
hSavBRM        dd  ?
hSplitBar      dd  ?
SaveItem       dd  ?
hWorkArea      dd  ?
hWEdit         dd  ?
lpWorkEdit     dd  ?
hBuild         dd  ?
hBEdit         dd  ?
lpBuildEdit    dd  ?
hEdit          dd  ?
hComboS        dd  ?
hListWS        dd  ?
hButtS         dd  ?
hWorkAreaS     dd  ?
hWEditS        dd  ?
hScrollData    dd  ?
hCopyFile      dd  ?
hProjMaint     dd  ?
hCreateProj    dd  ?
hUserTemp      dd  ?
hKeywordMaint  dd  ?
hAddin         dd  ?
hSnip          dd  ?
hBmpS          dd  ?
hColor         dd  ?
hPref          dd  ?
hType          dd  ?
hTBBmp         dd  ?
hTBBmpQ        dd  ?
hTBBmpU        dd  ?
hFont          dd  ?
hFontB         dd  ?
hFontI         dd  ?
hFontBI        dd  ?
hFontUni       dd  ?
hFontC         dd  ?
hFontL         dd  ?
hFontT         dd  ?
hFontTB        dd  ?
hFontTL        dd  ?
hFontBLD       dd  ?
hFontButt      dd  ?
sbParts        dd  8   dup(?)
hWndToolA      dd  ?
hWndToolB      dd  ?
hWndTool2      dd  ?
hWndToolQ      dd  ?
hWndToolU      dd  ?
hWndProp       dd  ?
hWndFunct      dd  ?
hSel           dd  ?
hImageList     dd  ?
hListS         dd  ?
hListT         dd  ?
hListL         dd  ?
hListW         dd  ?
hGoto          dd  ?
hCombo01       dd  ?
MenuCnt        dd  ?
FontCode       dd  ?

OpenFlg1       dd  ?
SaveFlg1       dd  ?
MaxWin         dd  ?
AutoSave       dd  ?
ProjOn         dd  ?
DriveOn        dd  ?
AddinOn        dd  ?
CodeHelperOn    dd  ?
BeepOn         dd  ?
SpaceAfter     dd  ?
RightAlign     dd  ?
MinMatch       dd  ?
Indent         dd  ?
Outdent        dd  ?
QuickOn        dd  ?
UserOn         dd  ?
PropOn         dd  ?
HexOn          dd  ?
ShiftOn        dd  ?
UnicodeOn      dd  ?
CloseBuild     dd  ?
SyntaxOn       dd  ?
SavSyntaxOn    dd  ?
ItalicOn       dd  ?
NoHiLiteBW     dd  ?
FontZoomOn     dd  ?
SmoothOn       dd  ?
BytesRead      dd  ?
BytesR         dd  ?
HoldM          dd  ?
LineOn         dd  ?
SaveAs         dd  ?
;SelOn          dd  ?
;TabOn          dd  ?
SetupOn        dd  ?
SelectOn       dd  ?
FilterOn       dd  ?
IndentOn       dd  ?
LeadingOn      dd  ?
ConstrainOn    dd  ?
ColumnOn       dd  ?
CloseAllOn     dd  ?
BarType        dd  ?
FromTab        dd  ?
NoSetup        dd  ?
CurPos         dd  ?
LineNum        dd  ?
ColorRes       dd  ?
IncrRes        dd  ?
AutoRefOn      dd  ?
PropCode       dd  ?
SavProp        dd  ?
SaveCode       dd  ?
SaveText       dd  ?
Run            dd  ?
OA             dd  ?
w5             dd  ?

ToolH          dd  ?
ToolH2         dd  ?
TabHgt         dd  ?
dwTop          dd  ?
dwBot          dd  ?
xBuild         dd  ?
yBuild         dd  ?
xFunct         dd  ?
yFunct         dd  ?
wFunct         dd  ?
hFunct         dd  ?

hAsciiBox      dd  ?
lpAsciiBox     dd  ?
hInput         dd  ?
hOutput        dd  ?
hUnicode       dd  ?
hALT           dd  ?
lpALT          dd  ?
dwMsg          dd  ?
dwwParam       dd  ?
dwlParam       dd  ?
HexDec         dd  ?

hDefHeap       dd  ?
hPath          dd  ?
hBuff          dd  ?
hOutPut        dd  ?

ProjCnt        dd  ?
hProjArray     dd  ?
BookArray      dd  22  dup(?)

hWndTab        dd  ?
lpTabCtrl      dd  ?
lpTabChild     dd  ?
TabSelect      dd  ?
hTabSeL        dd  66  dup(?)
Styles         dd  ?
SavSelect      dd  ?
PathIDs        dd  ?

NumTabs        dd  ?
NewTabWnd      dd  ?
WorkArea       dd  ?
SavHand        dd  ?

FRFlags        dd  ?
Prev           dd  ?
hFRDlg         dd  ?
RetCode        dd  ?

hResParent     dd  ?
hResForm       dd  ?
hLibR          dd  ?
hProcessB      dd  ?
ExitCode       dd  ?
OpenCloseOnR   dd  ?
hCtrlParent    dd  ?
hLibCB         dd  ?
OpenCloseOnCB  dd  ?
hCtrlForm      dd  ?
SW44           dd  ?
SW55           dd  ?

hIncLib        dd  ?
hUpdate        dd  ?
hClose         dd  ?
hCreate        dd  ?
hBrowse        dd  ?
hCancel        dd  ?
hCancel01      dd  ?
hReturn        dd  ?
hUser          dd  ?
hStep          dd  ?
hStepByStep    dd  ?
SubControl     dd  ?
hListBox       dd  ?
hListBox01     dd  ?
hListBox02     dd  ?
FilesOn        dd  ?
LineCount      dd  ?
;UpDown         dd  ?
TxtLen         dd  ?
SelLen         dd  ?

LangID         dd  ?
ChineseOn      dd  ?
cpOEM          dd  ?
cpANSI         dd  ?
osvID          dd  ?

Asm            dd  ?
Rsc            dd  ?
Def            dd  ?

h41            dd  ?
h42            dd  ?
h43            dd  ?
h44            dd  ?
h45            dd  ?
h46            dd  ?
h47            dd  ?
h48            dd  ?
h49            dd  ?
h50            dd  ?
h51            dd  ?
h52            dd  ?
h53            dd  ?
h54            dd  ?
h55            dd  ?
h56            dd  ?
h742           dd  ?
h743           dd  ?

disFont        dd  ?
disBack        dd  ?
disText        dd  ?

fpMem          dd  ?
hpMem          dd  ?

lpType         dd  ?
lpcbData       dd  ?
lpdwDisp       dd  ?
lpcbValueName  dd  ?
lpcValues      dd  ?

CustClrs       dd  16   dup(?)
SpeedRange     dd  32   dup(?)

AsmRootDir     db  256  dup(?)
RootDir        db  256  dup(?)
PathName       db  256  dup(?)
WorkBuff       db  256  dup(?)
szLoadPath     db  256  dup(?)
szLoadPathD    db  256  dup(?)
szFolder       db  64   dup(?)
FileName       db  64   dup(?)
ProjName       db  30   dup(?)
szProj         db  50   dup(?)
szProject      db  64   dup(?)
szProject01    db  64   dup(?)
szProject02    db  64   dup(?)
szProject03    db  64   dup(?)
szProject04    db  64   dup(?)
szProject05    db  64   dup(?)

szProjectD     db  64   dup(?)
szWorkPgm      db  32   dup(?)
szFind         db  100  dup(?)
szRep          db  100  dup(?)
Fsize          db  12   dup(?)
szFileSize     db  40   dup(?)
ExtType        db  5    dup(?)
szToolTip      db  64   dup(?)

szDec          db  10   dup(?)
szHex          db  10   dup(?)
szAscii        db  32   dup(?)
szUnicode      db  32   dup(?)

Test4          dd  ?
Test5          dd  ?

.data
ProjNamArray   dd  szProject,szProject01,szProject02,szProject03,szProject04,szProject05

;---------- [Structures] ----------

EDITCHANGE struct
      nmhdr          NMHDR     <?>
      cr             CHARRANGE <?> 
      SelType        dw  ?              ; SEL_TEXT or SEL_OBJECT
      LineNum        dd  ?              ; Line number
      LineLen        dd  ?              ; Line length
      cpLine         dd  ?              ; Character position of first character
      lpLine         dd  ?              ; Pointer to line
      TotLines       dd  ?              ; Total number of lines
      TotHidden      dd  ?              ; Total number of hidden lines
      Changed        dd  ?              ; TRUE if changed since last
      PageNum        dd  ?              ; Page number
EDITCHANGE ends

COLORS struct
      EditBC         dd  00fffff4h      ; Edit back ground color
      SelectBC       dd  00005000h      ; Selection back ground color
      SelbarBC       dd  00eaffeah      ; Selection bar back ground color
      LinebarBC      dd  00efffffh      ; Line bar back ground color
      Seperator      dd  00000000h      ; Seperator color
      TreeListBC     dd  00fffff4h      ; Tree and List back ground color
      DialogBC       dd  00ffffebh      ; Dialog back ground color
      EditTC         dd  00008000h      ; Edit text color
      SelectTC       dd  00ffffffh      ; Selection text color
      LinebarTC      dd  00004080h      ; Line bar text color
      TreeListTC     dd  00808000h      ; Tree and List text color
      HiColor01      dd  00ffffceh      ; Line hilite 1
      HiColor02      dd  00c0f0c0h      ; Line hilite 2
      HiColor03      dd  00c4ffffh      ; Line hilite 3
      HiColor04      dd  00edc7f8h      ; Line hilite 4
      HiColor05      dd  0000ffffh      ; Error hilite
      cmntcol        dd  020000ffh      ; Comment color
      strcol         dd  00ff8000h      ; String color
      Quotecol       dd  00ff0080h      ; Quote color
      Commacol       dd  00000000h      ; Comma color
      Mathcol        dd  00ff0080h      ; Math color
      Deciscol       dd  00ff00ffh      ; Decision color
      oprcol         dd  000000a0h      ; Operator color
      Labelcol       dd  00808000h      ; Label color
      APIScol        dd  00000000h      ; APIS color
      APIProccol     dd  000080ffh      ; API Proc call color
      HiColor06      dd  000000ffh      ; Build hilite
      White          dd  00ffffffh      ; White color
COLORS ends
Color          COLORS          <>

.data?
HANDLES struct
      hWnd           dd  ?              ; Main window
      hWndStat       dd  ?              ; Status bar
      hREdit         dd  ?              ; RichEdit
      hSel           dd  ?              ; Select
      hWorkArea      dd  ?              ; Work area main
      hWEdit         dd  ?              ; Work edit
HANDLES ends

FONTS struct
      hFont          dd  ?              ; Code edit normal
      hFontB         dd  ?              ; Code edit bold
      hFontI         dd  ?              ; Code edit italic
      hFontBI        dd  ?              ; Code edit bold italic
      hFontUni       dd  ?              ; Code edit unicode
      hFontL         dd  ?              ; Line numbers
FONTS ends

FTimeOC        FILETIME        <?>
FTimeOM        FILETIME        <?>
FTimeSC        FILETIME        <?>
FTimeSA        FILETIME        <?>
FTimeSM        FILETIME        <?>

osv            OSVERSIONINFO   <>
tci            TC_ITEM         <?>
sci            SCROLLINFO      <?>
nmhdr          NMHDR           <?>
cr             CHARRANGE       <?>
dis            DRAWITEMSTRUCT  <?>
mii            MENUITEMINFO    <?>
ft             FINDTEXTEX      <>
lf             LOGFONT         <>
Hand           HANDLES         <>
Font           FONTS           <>
