search for: topmenu

Displaying 16 results from an estimated 16 matches for "topmenu".

2008 Aug 19
1
Open directory within a menu in tcltk
Hello, I am trying to setup a menu to open files and directories. I have the following code: opendir<-function() { dirname<<-tclvalue(tkchooseDirectory()) } openfile<-function() { filename<<-tclvalue(tkgetOpenFile()) } require(tcltk) t1<-tktoplevel() topMenu<-tkmenu(t1) tkconfigure(t1,menu=topMenu) plotMenu<-tkmenu(topMenu, tearoff=FALSE) tkadd(plotMenu,"command",label="Open file", command=openfile) tkadd(plotMenu, "command",label="Select directory",command=opendir) tkadd(plotMenu,"command",labe...
2006 Aug 11
2
tkinsert
...e)) if (inherits(e, "try-error")) { tkmessageBox(message="Syntax error", icon="error") return() } cat("Executing from script window:", "-----", code, "result:", sep="\n") print(eval(e)) } topMenu <- tkmenu(tt) tkconfigure(tt, menu=topMenu) fileMenu <- tkmenu(topMenu, tearoff=FALSE) tkadd(topMenu, "command", label="Run", command=run) But when I run a=mean(c(1,2,3)) I have the result on my R console but i can't access to the result. If i write a, R don'...
2008 Nov 08
1
Get Information
...t when i save the file, i do not find the file save, please help me, in order to continue my projet. this is the programme: tt <- tktoplevel() txt <- tktext(tt) tkwm.title(tt,"Saisi des modalités") #intitule la fenêtre tkgrid(txt) tkmark.set(txt,"insert","0.0") topMenu <- tkmenu(tt) tkconfigure(tt,menu=topMenu) cascade =function () {fileName=tclvalue(tkgetSaveFile(initialfile="modalite.txt",filetypes="{{JPEG Files} {.jpg .jpeg}} {{PDF File} {.pdf}} {{Text File} {.txt}} {{All files} *}")) return(fileName)...
2012 Nov 19
6
tcltk freezing using MS Windows for R-2.14+
...indows, but not Mac or Unix. see details below. After considerable testing I have reduced the problem from a few thousand lines of code to 30 lines! If you paste the following lines of code into an R window: testGUI <- function(){ require(tcltk) MainWindow <- tktoplevel() topMenu <- tkmenu(MainWindow) tkconfigure(MainWindow,menu=topMenu) normalizeMenu <- tkmenu(topMenu, tearoff=FALSE) tkadd(normalizeMenu,"command",label="Normalize",command = function() NormalizeNow(MainWindow)) tkadd(topMenu, "cascade", label="Ma...
2010 Jul 22
1
check menu button (tcltk)
Hi,   I am making a mock user interface in tcltk and I would like to add a 'check menu button' such as shown here: http://zetcode.com/tutorials/pygtktutorial/images/checkmenuitem.png   Does anybody know how to do this? I am quite new to R. Cheers!! Albert-Jan ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ All right, but apart from the sanitation, the medicine,
2002 Feb 11
0
read.table in TCL/TK interface
...;- "" tt <- tktoplevel() tktitle(tt) <- "Tcl/TK Decision Tree Window " yvar <- "EKV" y.entry <- tkentry(tt,textvariable=yvar) submit.but <- tkbutton(tt, text="submit",command=function()tclvalue(done)<-1) done <- tclVar(0) tkpack(y.entry) topMenu <- tkmenu(tt) tkconfigure(tt,menu=topMenu) fileMenu <- tkmenu(topMenu,tearoff=FALSE) load <- function() { file <- tkcmd("tk_getOpenFile") if (!length(file)) return() chn <- tkcmd("open", file, "r") #tkinsert(txt,&quot...
2008 Dec 22
1
newbie question on tcltk
...r_window );tkgrid(ok.but1) tkgrid(tklabel(top,text=" ")) ok.but2 <- tkbutton(top, text = "2. ", width=20, font=fontHeading, default="active", overrelief="flat", anchor="w"); tkgrid(ok.but2 ) tkgrid(tklabel(top,text=" ")) topMenu <- tkmenu(top) tkconfigure(top, menu = topMenu) fileMenu <- tkmenu(topMenu, tearoff = FALSE) openRecentMenu <- tkmenu(topMenu, tearoff = FALSE) tkadd(openRecentMenu, "command", label = "5 ", command = function() tkmessageBox( message = "xxxxx&qu...
2007 Jan 22
0
How to disable existing menus in tcltk?
...xisting menu, but it seems that neither tkconfigure nor tkentryconfigure contains the state as one of its options. Here's a snip of the code. How could I disable, for example, the Edit data menu choise after already creating the menu (I want it to be active initially)? gui<-tktoplevel() topMenu<-tkmenu(gui) tkconfigure(gui,menu=topMenu) editMenu<-tkmenu(topMenu, tearoff=FALSE) tkadd(editMenu, "command", label="Edit data", command=function() editData()) tkadd(editMenu, "command", label="Preferences", command=function() editPref()) tkadd(topMenu...
2011 Nov 21
1
invalid command name "tk::MenuDup"
Hi to all, I'm developping an user interface in TCL/TK but in some computers this error occurs : <Tcl> invalid command name "tk::MenuDup" when the user runs : tm <- tktoplevel(height=500,width=800) topMenu <- tkmenu(tm) tkconfigure(tm,menu=topMenu) i don't understand why this code works on my computer and is not running on other user environment ? thanks, -- View this message in context: http://r.789695.n4.nabble.com/invalid-command-name-tk-MenuDup-tp4091092p4091092.html Sent from the R he...
2012 Nov 23
1
Adding a function with default parameters into the Rcmdr menu
...ar="314"){ print("hello") print(var) } if I run myfunction() directly i see : > myfunction() [1] "hello" [1] "314" it's ok. But if i edit de Rcmdr-menu.txt (in C:\Users\myname\Documents\R\win-library\2.15\Rcmdr\etc) and add : menu MyMenu topMenu "" "" "" "" item topMenu cascade "MyTest" MyMenu "" "" item MyMenu command "Test"...
2004 Apr 19
1
Menu addditions to Rcmdr v0.9-6
...elp in adding functions to the Rcmdr menu system. I've been able to modify the menus themselves and source test code but I can't get R functions to execute from the menu. My latest proof of concept code follows: Three lines added to "Rcmdr-menus.txt": menu junkMenu topMenu "" "" item junkMenu command "Print stuff..." "function() stuff ()" item topMenu cascade "Junk" junkMenu "stuff.R": stuff <-function(){ c("This is st...
2007 Nov 01
1
Rcmdr Plugin and menus.txt
...Essentially the problem I am having is: I cannot create a submenu to a newly created menu. Here is what the menus.txt file looks like: # type menu/item operation/parent label command/menu activation install? menu psychMenu topMenu "" "" "" "" item psychMenu command "Test" testOne "" "" item topMenu...
2007 May 14
3
pxe password protect option
Hi, I have tried several different line options, but I cannot seem to get the pxe master password option to work? I have basically tried all combinations of: DEFAULT local PROMPT 0 ALLOWOPTIONS 1 TIMEOUT 500 MENU TITLE sometitle MENU MASTER PASSWD somepassword But just can't seem to get the menu to prompt for a password. version I have is pxe 3.31 Thanks for any help
2017 Sep 22
3
gtk3 update causing havoc
On my lab systems, the automatic updates were failing because of the problems with ipod libraries from EPEL being in the way. It turns out that was a good thing, because when I "fixed" it, a massive set of packages was updated, including the new gtk3. These packages are the ones causing problems, I think. gtk3-3.22.10-4.el7.x86_64 gtk3-devel-3.22.10-4.el7.x86_64 In the release notes,
2008 May 26
11
doesn't create my guestbook
Hi, I''m having some trouble with my realtions (I think). I''m creating a guestbook with comments in ajax (the structure resembles the structure of a blog). So I''ve got a "flogs table" which keeps the "user_id" and the "id" of the flogs. This table. Then I''ve got a "guestbooks table" containing "id" of the
2008 Dec 29
0
Serial Correlation Test for Short Time Series
...other_window );tkgrid(ok.but1) tkgrid(tklabel(top,text=" ")) ok.but2 <- tkbutton(top, text = "2. ", width=20, font=fontHeading, default="active", overrelief="flat", anchor="w"); tkgrid(ok.but2 ) tkgrid(tklabel(top,text=" ")) topMenu <- tkmenu(top) tkconfigure(top, menu = topMenu) fileMenu <- tkmenu(topMenu, tearoff = FALSE) openRecentMenu <- tkmenu(topMenu, tearoff = FALSE) tkadd(openRecentMenu, "command", label = "5 ", command = function() tkmessageBox( message = "xxxxx&quot...