Hello; I'm now using mainly R for windows, mainly because I'm writing a tcl/Tk interface for some people, and I've got two questions. I'm an absolute beginner with tctk or tcktk use under the R GUI. 1) Is it posible to create a shorcut that launchs the R GUI and automatically reads the "source code" of the tcl/tk script to also launch the tcltk interface? 2) Is the RGUI programmed with tcltk? In this case, is it possible for an user like me to create a menu entry at the R GUI to call the source code in this R/tcl/Tk script? Any of the two options would be very good for us. Thanks and best regards, Javier
Yes. It would be nice and useful to save the users the task of loading the source R-TcltK code everytime they start up R. Because, in principle they are going to use R just for this. But the R GUI must remains open Javier ----------------------- El Viernes, 24 de Febrero de 2006 16:39, Frank Samuelson escribi??:> Do you need the user to interact with the Rgui after the code has run? > > -Frank > > Javier Garcia-Pintado wrote: > > Hello; > > I'm now using mainly R for windows, mainly because I'm writing a > > tcl/Tk interface for some people, and I've got two questions. I'm an > > absolute beginner with tctk or tcktk use under the R GUI. > > > > 1) Is it posible to create a shorcut that launchs the R GUI and > > automatically reads the "source code" of the tcl/tk script to also > > launch the tcltk interface? > > > > 2) Is the RGUI programmed with tcltk? In this case, is it possible > > for an user like me to create a menu entry at the R GUI to call the > > source code in this R/tcl/Tk script? > > > > Any of the two options would be very good for us. > > > > Thanks and best regards, > > > > Javier-- javier garc??a-pintado
Regarding question #2: You can write a package that attaches a menu if using Rgui on Windows. For example, I use something like this in one of my packages: ## -------------------------------------------------------------- .onAttach <- function(...){ cat("You have loaded COREtools, version", packageDescription("COREtools", fields = "Version"), "\n") if ("RTerm" %in% .Platform$GUI) cat("COREtools menu not available in Rterm\n") on.exit(if("Rgui" %in% .Platform$GUI) COREtoolsMenu()) } ## -------------------------------------------------------------- Then I put my menu code in a function called 'COREtoolsMenu'. This works well for me. ~Nick -----Original Message----- From: r-help-bounces at stat.math.ethz.ch [mailto:r-help-bounces at stat.math.ethz.ch]On Behalf Of Javier Garcia-Pintado Sent: Friday, February 24, 2006 2:01 AM To: r-help at stat.math.ethz.ch Subject: [R] R script autoload at startup Hello; I'm now using mainly R for windows, mainly because I'm writing a tcl/Tk interface for some people, and I've got two questions. I'm an absolute beginner with tctk or tcktk use under the R GUI. 1) Is it posible to create a shorcut that launchs the R GUI and automatically reads the "source code" of the tcl/tk script to also launch the tcltk interface? 2) Is the RGUI programmed with tcltk? In this case, is it possible for an user like me to create a menu entry at the R GUI to call the source code in this R/tcl/Tk script? Any of the two options would be very good for us. Thanks and best regards, Javier ______________________________________________ R-help at stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html