Displaying 20 results from an estimated 25 matches for "tkframe".
Did you mean:
tframe
2007 May 24
1
GUI component Margin on tkcanvas, tkframe or tktoplevel
Dear gurus:
I have a question on how to configure the margin layout on tcl/tk GUI
objects like tkcanvas, tkframe or tktoplevel.
For example, if I want to leave a larger margin on the left side of the
GUI container, which one should I configure, the toplevel or tkcanvas or
tkframe?
top<-tktoplevel()
canvas<-tkcanvas(top, relief=, borderwidth=...)
I also find the documentation for all the possible arg...
2007 Aug 14
2
Question about unicode characters in tcltk
...and subscripts into a tcltk menu.
The code creates all the mu's, and the 1 and 2 subscripts, but it
won't create the 0. Is there a certain set of characters that R won't
recognize the unicode for? Or am I input the \u2080 incorrectly?
library(tcltk)
m <-tktoplevel()
frame1 <- tkframe(m)
frame2 <- tkframe(m)
frame3 <- tkframe(m)
entry1 <- tkentry(frame1,width=5,bg='white')
entry2 <- tkentry(frame2,width=5,bg='white')
entry3 <- tkentry(frame3,width=5,bg='white')
tkpack(tklabel(frame1,text='\u03bc\u2080'),side='left')
tkpack(...
2006 Jun 21
0
Some R-Tcl/Tk-BWidget newbie questions.
...NoteBook")
tkgrid(tn, sticky="news")
### --> I guess there is a simpler way to do this ...
tbn <- tclvalue(tkinsert(tn, "end", "Algemeen", "-text", "Algemeen"))
tkpack(tbw.algemeen <- .Tk.newwin(tbn))
tkpack(tab.algemeen <- tkframe(tbw.algemeen))
tbn <- tclvalue(tkinsert(tn, "end", "Relaties", "-text", "Relaties"))
tkpack(tbw.relaties <- .Tk.newwin(tbn))
tkpack(tab.relaties <- tkframe(tbw.relaties))
tbn <- tclvalue(tkinsert(tn, "end", "Posten", &q...
2009 Oct 19
1
Problem with geometry manager in TclTK
...(tcltk)
ask.format <- function() {
ask.form <- tktoplevel()
tkgrab.set(ask.form)
tkfocus(ask.form)
tkwm.title(ask.form,"Input Format")
tkwm.resizable(ask.form, 0, 0)
file.format <- tclVar("1")
ReturnFormat <- "ID_CANCEL"
Title.frame <- tkframe(ask.form, relief="groove")
tkgrid(tklabel(Title.frame,text="Input File Format", font="Times 15",
foreground="dark red"))
tkgrid(Title.frame)
Choose.frame <- tkframe(ask.form, relief="groove", borderwidth=2)
file.format1 <- tkradiobutt...
2008 Nov 03
1
possible tcltk event loop problem
...whatever the
source of the problem, it doesn't always manifest itself. Some detail, and a
kludgy solution appear below.
What's odd is that the Rcmdr has three similar windows -- Script, Output,
and Messages, created by the following code:
For the messages window:
messagesFrame <- tkframe(.commander)
putRcmdr("messagesWindow", tktext(messagesFrame, bg="lightgray",
font=getRcmdr("logFont"), height=3, width=log.width, wrap="none"))
.messages <- MessagesWindow()
messagesXscroll <- ttkscrollbar(messagesFrame, orient="...
2005 Sep 05
1
tcltk, X11 protocol error: Bug?
...[i])
#xl <- xl+inc
}
}
save.ramp <- function(){
cr<<-colorRampPalette(c(b.color,e.color),space="Lab",interpolate="spline")
tkdestroy(tt)
##invisible(cr)
}
tt <- tktoplevel()
tkwm.title(tt,"Color Ramp Tool")
frame <- tkframe(tt)
bframe <- tkframe(frame,relief="groove",borderwidth=1)
if(is.null(b.color)) b.color <- "blue"
if(is.null(e.color)) e.color <- "yellow"
if(missing(n.col)) n.col <- 100
canvas.b <- tkcanvas(bframe,width="50",height="25",...
2010 Mar 01
0
Multicolumn Listbox selectcommand trouble
...command is supposed to go in the
tk2mclistbox()
totalcols = 5
totalrows = 100
idb <- matrix(NA, nrow = totalrows, ncol = totalcols, dimnames =
list(c(),c("Date","URL", "Title", "List Price", "Category")))
base <- tktoplevel()
listings <- tkframe(parent = base)
editor <- tkframe(parent = base)
tkwm.title(base, "my super program")
#changeeditor function(){
# }
mlb <- tk2mclistbox(listings, height = 20, width = 95, resizablecolumns =
TRUE, yscrollcommand = function(...)tkset(scr1,...))
#?tk2mclistbox
# Define the columns
t...
2007 Jan 07
1
Scoping issues
Hi everyone,
I'm trying to split up a large R file that implements a tcl/tk gui into
several smaller ones. The problem is that the main GUI creation
function defines many tclVars and tkframes that need to be accessible to
functions that are currently defined in main function, but which I'd
like to move to different source files. These files make up a package,
so it seems that using source() is a bad idea. I could try argument
passing, but there are a lot of arguments to pass in s...
2008 Dec 22
1
newbie question on tcltk
...s, i want it somehow separated from these two buttons, but i don't know how. I searched the web for some examples but my results were unsatisfactory.
Thank you and have a great day ahead.
#my code
library(tcltk)
rm(list=ls())
top <- tktoplevel(padx=70, pady=70)
frameOverall <- tkframe(top)
frameUpper <- tkframe(frameOverall,relief="groove",borderwidth=2)
back_but <- tkbutton (frameUpper, text = "BACK", width=20, height=1, default="active", overrelief="flat",anchor="w", borderwidth=4 )
tkgrid(frameUpper)
tkgrid(frameOver...
2010 Aug 05
1
Error in as.environment(pos): using 'as.environment(NULL)' is defunct
...clVar(test2(as.numeric(tclObj(VKG)),as.numeric(tclObj(HZ))
,as.numeric(tclObj(VZ)),as.numeric(tclObj(Aktivit?t)),as.numeric(tclObj(
tclArray1)))))
}
test2 <- local({source("C:/Berechnung_Funktion.R", local = TRUE)
environment(Berechnung) <- .GlobalEnv
Berechnung })
and:
Button<-tkframe(InputOutputfenster)
tkpack(Button, side='top')
tkpack(tkbutton(Button, text='compute optimal
solution',command=handler.Berechnung))
and the function in the other R-file:
Berechnung<-function(a,b,c,d,e) {
}
Thanks!
2010 Jun 11
1
Windows, OSX and Linux: updating a graphic device and double buffering
...nually?
If not, is it possible to force update my graphic device. E.g. with a
command like dev.flush()?
How can I run my code on all operating systems without any "jumps"?
Regards,
Adrian Waddell
Here is a minimal example code:
library(tcltk)
tt <- tktoplevel()
tkpack(top <- tkframe(tt), side = "top")
SliderValue <- tclVar("50")
SliderValueLabel <- tklabel(top,text=as.character(tclvalue(SliderValue)))
tkpack(tklabel(top,text="Slider Value : "),SliderValueLabel, side = "left")
tkconfigure(SliderValueLabel,textvariable=SliderValue)
s...
2008 Oct 30
3
using yscrollcommand in tkcanvas crashes R (PR#13231)
Full_Name: Sundar Dorai-Raj
Version: 2.8.0
OS: Windows
Submission from: (NULL) (76.220.41.126)
The following code crashes R:
library(tcltk)
tt <- tktoplevel()
tc <- tkcanvas(tt, yscrollcommand = function(...) tkset(ts, ...))
> sessionInfo()
R version 2.8.0 (2008-10-20)
i386-pc-mingw32
locale:
LC_COLLATE=English_United States.1252;LC_CTYPE=English_United
2004 Mar 19
5
loop through files in a dir
Hello
I have data in many files in a directory, how can I
loop through the files in a given dir in-order-to
build a data.frame?
thanks
2009 Sep 28
2
re trieve user input from an tcl/tk interface
Hello everyone,
this is my first post here and I hope I signed up correctly and someone will
take me by the hand and help me out. I am new to R and cannot figure out
what to do here...
... I want to have an User Interface that requests input. I want to save
this input to a variable to use it later on. I was able to do this with a
modalDiaglog (
2003 Jun 06
4
stuck tcltk scrollbars under Windows XP
...o reproduce the problem intermittently on an XP system,
and found that the problem appears to go away when I remove the calls to
tkgrab() and tkgrab.release().
You can test for the problem with the following code:
window1 <- tktoplevel()
window2 <- tktoplevel()
xFrame <- tkframe(window2)
xScroll <- tkscrollbar(xFrame, repeatinterval=5, command=function(...)
tkyview(xBox, ...))
xBox <- tklistbox(xFrame, height=4,
selectmode="single", background="white", exportselection="FALSE",
yscrollcommand=function(...) tks...
2003 Oct 01
0
curious error with tkcheckbutton
...in the array b and they exist:
> b
[1] "::RTcl1" "::RTcl2" "::RTcl3" "::RTcl4" "::RTcl5" "::RTcl6"
the script is(I'm use R 1.7.1 for win, the fail is in the first execution
of the script):
library(tcltk)
tt<-tktoplevel()
f<-tkframe(tt)
tkpack(f)
j<-6
nbre<-c("c1","c2","c3","c4","c5","c6")
b<-c()
i<-1
while (i<=j){
aux<-paste("b",i,sep="")
aux<-tclVar(init=0)
b<-c(b,as.character(aux))
tclvalue(b[i])<-0
i<-i+...
2003 Oct 09
0
curious mistake in tkradiobutton
...ariable.
when six variables tcl has been created in the array b and they exist:
> b
[1] "::RTcl1" "::RTcl2" "::RTcl3" "::RTcl4" "::RTcl5" "::RTcl6"
the script is(I'm use R 1.7.1 for win):
library(tcltk)
tt<-tktoplevel()
f<-tkframe(tt)
tkpack(f)
j<-6
nbre<-c("c1","c2","c3","c4","c5","c6")
b<-c()
i<-1
while (i<=j){
aux<-paste("b",i,sep="")
aux<-tclVar(init=0)
b<-c(b,as.character(aux))
tclvalue(b[i])<-0
i<-i+...
2007 Jan 01
0
autofill for a tkentry field
...(f1)
ind <- grep(entry, fruitList)
if (length(ind)>0){f1 <- tclVar(fruitList[ind[1]])}
}
fruitList <<- c("Apple", "Banana", "Peach", "Pear", "Plum", "Mango")
tkdestroy(tt)
tt <- tktoplevel()
pw <- tkframe(tt)
ppw <- tk2labelframe(pw, text="Fruits:")
f1 <<- tclVar("")
entry1.f <- tkentry(ppw, width=30, textvariable=f1, validate="key",
validatecommand=autofill)
tkgrid(entry1.f)
tkgrid(ppw)
tkgrid(pw)
I don't know how to...
2007 Oct 19
1
tcltk: help with tkmenubutton
...rlkurs/part4/tkperl.html
... to R's tcltk.
But I don't know how to convert one line in this example:
library(tcltk)
# create a main window
mw <- tktoplevel()
# a menu consists of a horizontal menubar,
# with associated submenus
##### first create the horizontal menubar
mb <- tkframe(mw, relief = 'raised', bd = 2)
# now put in the menubar some menubuttons
m_file <- tkmenubutton(mb, text = "File", underline = 0)
# pack everything from the menubar
tkpack(mb, side = "top", fill = "x")
tkpack(m_file, side = "left")
#### now cr...
2006 Oct 21
0
tcltk: multiple listboxes, selection
...nts, the current selection in the *other* listboxes is
cleared!
Anybody knows how I can prevent this?
Here's my code (sorry not complete):
(E.g. If I select an X value, I'd lose the Y value I selected before)
gui.create.tab.general <- function(tt) {
# Network topology
frame.1 <- tkframe(tt)
combo_topology <- tkwidget(frame.1, "ComboBox", values = infras,
editable = FALSE)
tcl(combo_topology, "setvalue", "first")
tkgrid(tklabel(frame.1, text="Network topology"), combo_topology)
tkgrid(frame.1, sticky = "w")
# X valu...