home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Overload
/
ShartewareOverload.cdr
/
windows
/
kpwdemo.zip
/
DEMO.KB
< prev
next >
Wrap
Text File
|
1990-06-28
|
7KB
|
217 lines
setup ().
&Top ().
(* <<<<<<<<<<<<<<<<<<<<<<< MENU ITEMS >>>>>>>>>>>>>>>>>>>>>>>>>>>> *)
topic '&Top'.
disable_menu_item (?m1,[&Back,&Top]).
list is [].
set_title (,'Introduction to KnowledgePro').
text ('#e
Welcome to KnowledgePro (Windows), a unique development
environment for Windows applications.
Point and click your mouse to select information on the items
below:
#mDevelopment Environment#m
#mHelp System#m
#mSample Tools#m
#mCode Included#m
#mFeatures#m
#mOrdering Information#m
⌐ Knowledge Garden Inc. 1990
473A Malden Bridge Road
Nassau, NY 12123
(518) 766-3000 FAX (518) 766-3003 ').
if ?version is 3
then logo is load_icon ('kpwin.ico') and
icon (?logo,46,14).
end.
topic select (item).
do (?item).
topic &Back.
if list_length (?list) = 1
then &top ()
else
list is sublist (?list, 1, list_length (?list) - 1) and
item is last (?list) and
list is sublist (?list, 1, list_length (?list) - 1) and
(if one_of (['Help System','Sample Tools'], ?item)
then do (?item)
else mark (?item)).
end. (* Back *)
topic &Print.
print ([?get_title, get_text (?w1)]).
end. (*&Print*)
topic &Quit.
clear ().
end. (* &Quit *)
topic &Help.
if last (?list) is '&Help'
then exit ().
set_title (?w1,Help).
enable_menu_item (?m1,&Back).
list gets '&Help'.
text (#e,'
Reading Hypertext.
The line below shows the font used for hypertext on your monitor.
#mThis is the font for hypertext on the current monitor.#m
To select hypertext, point and click with the mouse or, use TAB
and SHIFT TAB to move the cursor among hypertext items and press
ENTER to select the item.
To go back to the previous screen, select BACK.
To return to the first screen, select TOP.
To print the current item, select PRINT.').
topic 'This is the font for hypertext on the current monitor.'.
(* this is a dummy topic to catch the hypertext in the help screen.*)
end.
end. (*&Help*)
end. (*select*)
(* <<<<<<<<<<<<<<<<<<<<<<<<<<<<<< >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> *)
(* //////////////////////////////////////////////// DEFINED HYPERTEXT TOPICS \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ *)
topic 'Help System'.
list gets 'Help System'.
set_title (?w1,'Help System').
enable_menu_item (?m1,[&Top,&Back,&Print]).
text ('#e
The help system gives you access to the complete syntax of
all functions in KnowledgePro. Syntax can be copied to the
clipboard and pasted into your application. Help contains
information about converting from KnowledgePro (DOS) and event
handling. All of the help source code and text files are
included, allowing you to customize Help in any way.
#mSelect here to call the KnowledgePro Help System#m').
topic 'Select here to call the KnowledgePro Help System'.
load ('kphelp.hkb',temp).
'!helpdir' is current_directory ( ).
temp ( ).
remove_topic (temp).
hyper_display (?hyperColor,,?hyperFont).
use_font (system_font).
end.
end. (* Help System *)
topic 'Sample Tools'.
list gets 'Sample Tools'.
set_title (?w1,'Sample Tools').
enable_menu_item (?m1,[&Top,&Back,&Print]).
text ('#e There are several sample tools included with
this demo. These include:
#mCOLOR#m#x15used to find RBG values for screen colors
#mDESIGN#m#x15lets you interactively design screen interfaces.
#x15The code to create the interface is produced and can be
#x15copied to a file or the clipboard
#mENGINE#m#x15an application for reading hypertext files
#mFONT#m#x15a tool for designing fonts
#mPALETTE#m#x15shows the standard colors and their names
#mSETICON#m#x15installs icons on the Windows 3.0 program manager
If you want to run one of these now, click on the file name.
The code for each application is supplied in .SRC files on the
demo disk.').
topic mark (item).
choices is [COLOR,DESIGN,ENGINE,FONT,PALETTE,SETICON].
kbs is ['COLORdem.hKB','DESIGNde.hKB','ENGINEde.hKB','FONTdem.hKB',
'PALETTEd.hKB','SETICONd.hKB'].
new_kb ( element (?kbs, where (?choices, ?item) ) ).
end. (*mark*)
end. (*Sample Tools*)
topic 'click here'.
new_kb ('ddeshowd.hkb').
end.
(* ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// *)
(* ========================= MARK TOPIC ======================== *)
topic mark (item).
if one_of ( ?loadChoices ,?item)
then loadSection ()
else displayText ().
topic loadSection.
hide_window (?w1).
load ( element (?loadKbs, where (?loadChoices,?item) ) , temp).
temp ().
wait ().
remove_topic (temp).
set_display_window (?w1).
show_window (?w1).
end.
topic displayText.
list gets?item.
set_title (?w1,?item).
enable_menu_item (?m1,[&Top,&Back,&Print]).
text (#e,read ('demo.hyp', concat ('//',?item) ,'//') ).
set_file_pos ('demo.hyp',0,beginning).
end.
end. (*mark*)
(* ==================================================================== *)
(* ~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~ SETUP ^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^ *)
topic setup.
displayInfo ().
if version is 3
then [width,height] is_c [85,22]
else [width,height] is_c [70,25].
!main:w1 is window (select:&Quit,5,1,?width,?height,,[PopUp,ThickFrame,MaximizeBox,ControlMenu,VertScroll,ShowChildren,Siblings],,,,close_event).
m1 is menu ([&Top,&Back,&Print,&Quit,&Help],select).
disable_menu_item (?m1,[&Back,&Top]).
show_window (?w1).
list is [].
loadChoices is ['Development Environment',Graphics,Hypertext].
loadKbs is ['develop.hkb','graphics.hkb','hyperex.hkb'].
topic displayInfo.
system is system_info ().
if element (?system,4) is 12
then displayType is EGA and
smallFont is [10,5,400,f,f,f,0,1,34,Helv] and
bigFont is [16,9,400,f,f,f,0,1,18,'Tms Rmn']
else displayType is VGA and
smallFont is [16,7,400,f,f,f,0,1,18,Helv] and
bigFont is [20,8,700,f,f,f,0,1,34,Helv].
if last (?system) < 3
then HyperColor is black
else HyperColor is blue and
hyper_display (blue).
hyperFont is create_font ([12,8,400,f,t,f,0,1,2,System]).
version is string_copy (element (?system,9),1,1).
end.
end. (*setup*)
(* ~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^ *)