Post Reply 
How Drawmenu work's?
11-12-2016, 01:36 AM (This post was last modified: 11-12-2016 02:11 AM by compsystems.)
Post: #8
RE: How Drawmenu work's?
+1 Good program

suggestions
1: on the libMenu directory, please write a subroutine to exit the menu
2: A single argument for input as array,

PHP Code:
{
  { 
"name menu 1" "prg menu 1"}
  { 
"name menu 2" "prg menu 2"}
  { 
"name menu 3" "prg menu 3"}
  { 
"name menu 4" "prg menu 4"}
  { 
"name menu 5" "prg menu 5"}
  { 
"name menu 6" "prg menu 6"}


"prg menu x" -> Path of the directory or program ([dirName.]prg([args]) ), If the sublist is empty, black menu (off)

sample
PHP Code:
{
  {
"abc","tstLibM.f1()"}
  {
"menu2","tstLibM.f2()"}
  {}
  {
"nothing"}
  {}
 {
"menu6","abs(-3)"}


3: Please comment on each line, to learn how the event captures
// to manage events, trigger actions
PHP Code:
EXPORT events()
BEGIN
  
IF MOUSE(1)<200 //
  
THEN RETURN; 
  
END;
  
LOCAL m:=1+FLOOR(MOUSE(2)/53); //
  
callit(a(m));
END


PHP Code:
callit(F)
BEGIN
  
IF F=="" THEN  // If there is not program, nop
  
RETURN; 
  
END;
  
EXPR(F); // Evaluates the program.
  
draw(); // Put the menu
END
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
How Drawmenu work's? - fabio.hdl - 11-03-2016, 05:02 PM
RE: How Drawmenu work's? - Han - 11-03-2016, 06:41 PM
RE: How Drawmenu work's? - Tyann - 11-03-2016, 07:02 PM
RE: How Drawmenu work's? - StephenG1CMZ - 11-03-2016, 08:58 PM
RE: How Drawmenu work's? - toml_12953 - 11-04-2016, 02:28 PM
RE: How Drawmenu work's? - primer - 11-11-2016, 07:31 PM
RE: How Drawmenu work's? - fabio.hdl - 11-05-2016, 08:22 PM
RE: How Drawmenu work's? - compsystems - 11-12-2016 01:36 AM
RE: How Drawmenu work's? - primer - 11-12-2016, 10:41 AM
RE: How Drawmenu work's? - compsystems - 11-12-2016, 02:53 PM
RE: How Drawmenu work's? - primer - 11-12-2016, 08:36 PM
RE: How Drawmenu work's? - StephenG1CMZ - 11-12-2016, 08:23 AM
RE: How Drawmenu work's? - compsystems - 11-12-2016, 09:05 PM
RE: How Drawmenu work's? - primer - 11-12-2016, 10:04 PM
RE: How Drawmenu work's? - compsystems - 11-14-2016, 04:03 AM
RE: How Drawmenu work's? - StephenG1CMZ - 11-14-2016, 09:03 AM
RE: How Drawmenu work's? - ggauny@live.fr - 01-25-2017, 12:11 PM
RE: How Drawmenu work's? - ggauny@live.fr - 01-25-2017, 05:06 PM
RE: How Drawmenu work's? - primer - 01-25-2017, 11:18 PM



User(s) browsing this thread: 4 Guest(s)