Programming

Tcl/Tk xtablelist

XTablelist Package Purpose: A TclOO class to extend the fabulous tablelist widget. TclOO naming conventions: public methods - starts with lower case declaration names, whereas private methods - starts with uppercase naming, so we use CamelCase … widget commands: xtablelist::xtablelist xtablelist::configure xtablelist::cget xtablelist::xtablelist understands all commands from original tablelist, for more sub-command refer as well to the public class interface widget options: -xhideoption boolean “yes”,1 / “no”,0 (default: “no”), hide/show a popup-menu which allows to manipulate the tablelist column display

Continue reading

Tcl/tk BWidget_patch

BWidget_patch Purpose: This package solves some issues with BWidget in conjunction with the ttk widget set. As long as the bugs are not fixed, this package can be used to “overload” original procedures where the problems araise. Usage: A typical initialization sequence might look like: # starkit support sequence: if {[catch { package require starkit if {[starkit::startup] eq "sourced"} { return } }]} { namespace eval ::starkit { if {[set this [info script]] == ""} { set this [info nameofexecutable] } variable topdir [file normalize [file dirname $this]] } } # where to find support packages: lappend auto_path [file join $::starkit::topdir "lib"] package require Tk package require tile # initialize a custom theme (optional): set ctheme "plastik" package require ttk::theme::${ctheme} ttk::setTheme $ctheme package require -exact BWidget 1.

Continue reading

HelpViewer based on Tkhtml 3.0

HelpViewer Application The HelpViewer is a standalone application to display html files which might be organized in a directory structure. The program is written in tcl/tk and is based on the Tkhtml 3.0 library. When starting the application, a dialog pops up, where you can drag&drop your prefered directory using the file explorer: Features: Once a directory is specified, the program traverses down the tree to search for all available html files.

Continue reading

ImageFlow for Hugo

ImageFlow for Hugo Hugo is a static site generator, whereas ImageFlow implements a nice interactive image gallery ontop of hugo’s infrastructure. Example: jQuery(document).ready(function() { var instanceOne = new ImageFlow(); instanceOne.init( { ImageFlowID: 'myImageFlow', xStep: 100, opacity: true, slider: true, captions: true, slideshow: true, slideshowAutoplay: true, slideshowSpeed: 4000, startID: 2, onClick: function() { $.fancybox.open( { href: this.getAttribute('this.url'), title: this.getAttribute('alt'), } ); } }); });

Continue reading

Tcl/tk html3widget

html3widget - a tcl/tk megawidget Purpose: The html3widget is a tcl/tk package which implements a megawidget to render html + css. The code is based on Tkhtml3.0 and as well HV3 which (for the moment) is not actively developed, but still offers a solid base to render html including css support. The following picture illustrates of how a html file with underlying css bootstrap3.xx framework might look like: The package might be used to implement an internal help viewer (for an application) in an easy way.

Continue reading

QLOCKTWO

QLOCKTWO Description: Just for fun. When I was walking around for sightseeing, I discovered such a clock in the presentation area of a shop. I thought, this could be a nice fun program to implement with tcl/tk. After a quick search, I discovered that someone else already had the same idea. Pls see here: wiki.tcl.tk/27622. I just thought, it might be useful, to prepare an executable, so that everyone quickly can give it a trial.

Continue reading

DirDiff

DirDiff -- Purpose: A directory comparison utility. The program is a combination of dirdiff (directory comparison) as well as tkdiff (file comparison). It depends on the diff command - a unix utility command. For the moment, diff.exe needs to be available in the same directory as dirdiff.exe. If you need support for a different operating system, please use the comment section below. The program is especially usefull:

Continue reading

Tcl/tk

Tcl (Tool Command Language) is a very powerful but easy-to-learn dynamic programming language, suitable for a very wide range of use cases: including web and desktop applications, networking, administration, testing and many more. Open source and business-friendly, Tcl is a mature yet evolving language that is truly cross-platform, easily deployed and highly extensible. Tk is a graphical user interface toolkit that takes developing desktop applications to a higher level than conventional approaches.

Continue reading

Delete Empty Part Bodies

Delete Empty Part Bodies A utility CATScript macro for CatiaV5 to clean up a all empty PartBodies in a CATPart. Usage: Assuming that one needs to clean e.g. a CATAllPart from all unneccessary geometry. After the clean operation (by selecting geometry visually on the screen rather than in the object tree) a lot of empty PartBodies might remain. In such a case, executing the macro is much faster than going through the object tree to manually select and delete those empty PartBodies.

Continue reading

Export All Drawings 2 PDF

Export All Drawings 2 PDF PURPOSE: This utility CATScript macro for CatiaV5 can be used to create PDF documents for all CATDrawing files which are stored in a directory structure. Starting from a given directory, the function recursively searches all sub-directories, trying to find every drawing document down below the directory tree. USAGE: Start Catia and run this macro, (it is not necessary, to load any model). A directory selection dialog pops up and the user is asked to select a directory where to start from.

Continue reading