Discussion forum about PANORAMIC language

Mac, Windows & Android application development with PANORAMIC language
 
HomeFAQSearchRegisterMemberlistUsergroupsLog in
Latest topics
» Hello world.
by Mon Jun 19, 2017 1:37 am

» Biomorphes de PICKOVER
by Sun Jun 18, 2017 2:33 am

» In less than 10 lines of code
by Fri Jun 16, 2017 5:03 am

» Effect Dopler
by Fri Jun 16, 2017 3:29 am

» SuperEllipse
by Wed Jun 14, 2017 4:01 am

» Plants
by Wed Jun 14, 2017 3:38 am

» Mira's attractor
by Wed Jun 14, 2017 3:30 am

» Triangle of Sierpinski
by Wed Jun 14, 2017 3:22 am

» Esthétique polaire
by Wed Jun 14, 2017 3:16 am

» Butterfly effect : Lorenz equations
by Wed Jun 14, 2017 3:08 am

» Collision detection
by Tue Jun 13, 2017 5:09 am

» The Bees Laline Paull Epub Books
by Mon Oct 10, 2016 8:58 pm

» PANORAMIC for Mac OSX 10 is available
by Tue Aug 09, 2016 6:08 pm

» ide
by Sat Jul 16, 2016 12:27 am

» Can I change the program icon/logo in my application ?
by Thu Jul 07, 2016 3:32 am

Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

Share | 
 

 Editor code

View previous topic View next topic Go down 
AuthorMessage
scott93727



Number of posts : 17
Registration date : 2009-10-15

PostSubject: Editor code   Wed Oct 27, 2010 10:12 pm

Finally got around to making the editor, Added Copy, paste, cut functions, Code below

dim a$:dim b$
rem defines line labels
label quit : label ed1 :label sav : label edp : label rtln
label er3 : label nw : label cp :label pt : label ud

rem defines form Label
caption 0,"ViewerPro Ver. 1.0"

rem Creates Dialog Box + filters
open_dialog 11
filter 11,"All Files|*.*|Text Files|*.Txt|Doc Files|*.Doc|RTF Files|*.RTF"
Save_dialog 13
filter 13,"All Files|*.*|Text Files|*.Txt|Doc Files|*.Doc|RTF Files|*.RTF"


rtln:
rem menus---------------------------------------------------------------
main_menu 1
on_error_goto er3
rem Creation of 2 Main_menus at the same level
sub_menu 2 : caption 2,"File" : parent 2, 1
sub_menu 3 : caption 3,"Edit" : parent 3, 1

rem Creation of 3 Sub_Menus to Main_Menu 2 (File)
sub_menu 4 : caption 4,"New" : parent 4, 2
sub_menu 5 : caption 5,"Open" : parent 5, 2
sub_menu 6 : caption 6,"Save" : parent 6, 2
sub_menu 7 : caption 7,"Quit" : parent 7, 2
rem action on click , line number
on_click 4, nw
on_click 5, ed1
on_click 6, sav
on_click 7, edp

rem Creation of 3 Sub_Menus to Main_Menu 3 (Edit)
sub_menu 8 : caption 8,"Copy" : parent 8, 3
sub_menu 9 : caption 9,"Paste" : parent 9, 3
sub_menu 10 : caption 10,"Cut" : parent 10, 3
rem action on click , line number
on_click 8, cp
on_click 9, pt
on_click 10, ud
rem menu----------------------------------------------------------------

rem Inserts text box + Size
memo 12
width 12,800
height 12,600

rem --------------------------------------------------------------------
rem clipboard functions + Memo #
cp:
clipboard_copy 12
goto rtln:
pt:
clipboard_paste 12
goto rtln:
ud:
clipboard_cut 12
goto rtln:
rem -------------------------------------------------------------------
end

quit:
terminate
return

nw:
clear 12
return

ed1:
rem open_dialog 11
a$=file_name$(11)
file_load 12, a$
return

sav:
rem Save_dialog 13
b$=file_name$(13)
file_save 12, b$
return

er3:
print error_type$
return

edp:
terminate
Back to top Go down
View user profile
Severin



Number of posts : 19
Localisation : Germany/Braunschweig
Registration date : 2010-12-13

PostSubject: Re: Editor code   Sat Mar 30, 2013 3:02 pm

****************************************
PANORAMIC V 0.9.24 ist verfügbar
PANORAMIC V 0.9.24 is available
PANORAMIC V 0.9.24 est disponible
PANORAMIC V 0.9.24 es disponible

Das Forum Panoramic ist wieder aktiv.
Bitte besucht uns.

The forum Panoramic is active again.

Please, visits us.

Le forum Panoramic est actif de nouveau.

S'il vous plaît, nous visite.

El foro Panoramic es de nuevo activo.

Por favor, nos visita.
********************************************
Back to top Go down
View user profile
 
Editor code
View previous topic View next topic Back to top 
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
Discussion forum about PANORAMIC language :: Panoramic for Windows :: Source code (snippets)-
Jump to: