= RwdTinker framework for RubyWebDialogs RwdTinker is a web brower interface to and system for developing programs == Usage How to Use the Tinker framework Program (rwdtinker) 1. stand alone application 2. framework for building applications 3. Open brower windows with html documents The GUI interface used is RubyWebDialogs Start the program by typing ruby init.rb Then point your web browser to: http://localhost:7705/ == Viewing installed Applets: Go to "List Scripts" tab You can get a list of all installed applets by clicking the listfiles button To see the text of a install file Type in the name of the file you want. type it without the inf ending rwdapplet-0.1 Then click the "View Installed File" button If it finds the file it will open it. It displays the text the search box. You can uninstall applets on this screen == Installing Applets click on the "Selection Panel" click on Rwdtinker Back Window You can download an applet created by someone else put the file in the zips directory click on the "list zips" tab click on "list applets available for installing" chose the applet you want click on "install applet" If all goes well the applet should be installed. You will need to restart rwdtinker to see the new screens == Changing configuration file click on "Edit Configuration" You can view the configuration file You can edit the configuration Remember to reload the configuration variables if you want your changes used. == Manually installing applets * unzip an applet unzip the applet into the program directoy unzip randomapplet.zip This should place the needed files in the correct directories == Creating Applets To add code, commands and gui tabs Move program files into a directory under the code directory. Move gui files into a directory under the gui directory. The gui directory name you create is important, because the gui rwd file is built in alpha order by directory name There are two ways to add applets to the directories. Creating code * Manually write code and gui files The files go into your code directory the filenames for code do not matter The gui files go into your gui directory The gui files need to be in order by name and end with .rwd If you need a config file that goes in the configuration directory internationalization and localization are helped by replacing the gui files in the subdirectories under gui == Documents when you click on a document name, the document should pop up in a browser window, or in another browser tab. To exit, press the x inside the browser window. == To add context sensitive help You need to add a hash file that just needs to contain Helptext.update( :myapplet_generalhelp => " This is the general help You can add help text hear") And you need to add a help run script that will call runhelpwindow This should have a method that includes: setting $help_topic, and adds to $helptopicsarray, saves the calling window and calls runhelpwindow which will render the help message. if @rwd_tab == "gemservescan" $help_topic = "gemdocs_help" end $helptopicsarray = $helptopicsarray | ["rubyslippers_generalhelp", "Install_Gem","GemCommands_help", "gemfilesinstalled","gemdocs_help"] if @rwd_window != "rwdtinkerhelpwindow" $previouswindow = @rwd_window $previoustab = @rwd_tab end runhelpwindow end == Languages You can add tranlations in the lang subdirectory You change the $lang constant in Tinker config file in the configuration directory You can see one translation on the install applet tab, after you have installed and applet == Using over a Network To serve the application over your local LAN,change the last line in the init.rb file to something like: RwdTinker.file(RWDFile).serve(8080, "-r" ? ".rwduids" : nil) Then you should be able to login at: http://yourhostname:8080 You have to authorize yourself. The .rwuids example is a string with the name of the authorization file, relative to the home directory of the user that started the service. This file has to be in the form of: user1 = password user2 = pass phrase Thus the file .rwduids might contain: erik = secret == Requirements: RubyWebDialogs - I am using 0.1.2 This package you downloaded should have a runtime version of the needed rubywebdialog files Ruby I am using version 1.8.2 I have tested this under Linux-Debian kernel 2.6.9 = Operation: The code files reside in the code directory and are combined before the main Class is loaded The rwd files in gui are combined before the gui is activated Translated text reside in the lang directory == Installing: untar the file tar zxvf rwdtinker-x.y.tar.gz then cd to the directory cd rwdshell-x.y then start the init.rb program file ruby init.rb Then point your browser at http://localhost:7705 or where it tells you. Trouble shooting: If the program is not working, try looking at the ev subdirectory. That is where the runtime of rubywebdialogs are. for long term installation, I would suggest putting most files in a lib directory like /usr/lib/rwdshell then make a writable directory the local directory for command files to be written like ~/rwdshell Closing the browser doesn't terminate the application. You have to use the application's close-button And terminating the application doesn't terminate the application when running in network mode. You just log out. Don't use the back-button of the browser! Strange and unpredictable things may and will happen! RubyWebDialogs is a platform independent graphical user interface for Ruby applications. It generates HTML and serves it with an internal HTTP server, so you can use your favorite web browser as the front end for your Ruby application. All this means, that it can be used on almost every platform, like Ruby itself. http://www.erikveen.dds.nl/rubywebdialogs/ == Credits Thanks go to: * Matz, for creating Ruby in the first place. * Erik, for creating RubyWebDialogs. * Charlotte, my wife for coming up for the name Tinker. == License rwdtinker is copyright (c) 2004 Steven Gibson. It is free software, and may be redistributed under the terms of the GPL licence: == Contact For more information see: http://rwdapplications.rubyforge.org/wiki/wiki.pl For more information about RubyWebDialogs see: http://www.erikveen.dds.nl/rubywebdialogs/index.html Thanks, Steven Gibson == Changelog version 1.57 added rconftool use to update configuration files changed applets remove to not used external rm version 1.56 refactored gui files to load without intermediate files refactored code files to load without intermediate files version 1.55 refactored language files to load without intermediate files refactored language files to load without intermediate files version 1.54 refactored rwdtinker applet installation tab - remote gem and local installs share menu buttons corrected some program logic errors in remote control code including close socket version 1.53 added search of Gems repository for rwdtinker gems download and install of Gems version 1.52 added function to install applets from gem directory version 1.51 changed return to main changed configuration of remote ports updated context sensitive help version 1.50 changed unzip applet to be internal code - no exec to unzip program changed order of tabs on back window - list applets now first added rwdwcalc applet in to zips directory changed width of text fields with help from RubyWebDialogs author changed listing of help options, vertical instead of horizontal version 1.49 added demon function for remote queries startup application on first available port version 1.48 fix in context sensitive help so that applets can use it better version 1.47 change to context sensitive help version 1.46 more work on context help window calls point to tab as well as windows help added help buttons on Document, Selection, View Applet, tabs version 1.45 first steps toward context sensitive help added help button on main window/tab version 1.44 updated directory structure - refactored gui files Changed gui directory names - more like Java package titles version 1.43 changed setup variables file for live changes added editing and reloading of config file added unzip filename to config file version 1.42 update for live update system update applets for live update code file name cleanup version 1.41 l10n work es,nl, jp separated out languge.cnf added zip applets refreshacpi, rwdcalc version 1.40 removed extra lines from init.rb fixed help second window added some tranlations for Spanish More work on l10n version 1.3 refactored gui files to do easier i10n removed lang directories under gui added lang files under lang dir removed redundant code files left from moving applet handling to back window removed zipped applets not yet refactored version 1.24 added internet usage instructions to HowTo_Tinker.txt removed HowTo_Tinker.html added panels for Helpabout changed photo logo tab to only have embedded picture, no button version 1.23 moving diagnostic tab and applet handling tabs to second window added selection panel tab to choose secondary windows. version 1.21 changing version on help screen to be button added version window added diagnostic tab version 1.2 added gemspec for creating a rwdtinker.gem added rdoc comments changed order on remove applets tab version 1.1 changed order of elements on install applet tab Add more i81n ablility - added lang directorys for language hash files added in test file using WATIR stands for "Web Application Testing In Ruby, version 1.0 Improved name selection in zips and applet screens added rubyslippers applet and rwdrefreshacpi applets as zips version 0.9 Fixed bug introduced in 0.8 - code files not sorted correctly - class end was not in correct location updated RubyWebDialogs for people who do not have it installed added rwdschedule applet as zip file version 0.8 changed location of code files only directory of code files needs to be added to inf file changed location of gui files only directory of gui files needs to be added to inf file Added constants in conf file for code location and gui location removed all zips not yt updated to new directory layout change loading of conf files to not need intermediate file and favicon.ico version 0.7 moved changelog to HowTo_Tinker.html copied english gui text to the dirs I think we should translate to update backup zip files to newest versions upgraded the ev directory - for those who don't have RubyWebDialogs version 0.6 updated version number changed merge name to rwdtinker.rb version 0.4 added zip listing and installing - Linux only Version 0,3 changed name to Tinker Version 0.2 added some i18n directories for the gui files Version 0.1 first public version released includes document screen Open Photo screen included configuration directory zips directories installed directory installed applet lister