diff -crN oommf-1.1b0/CHANGES oommf/CHANGES *** oommf-1.1b0/CHANGES Tue Apr 4 06:18:20 2000 --- oommf/CHANGES Tue Oct 2 12:15:40 2001 *************** *** 1,3 **** --- 1,40 ---- + ========== OOMMF 1.1b1 released 2001/10/02 ========== + Significant changes since 1.1b0: + + * Expanded Tcl/Tk support + - 8.3.3, 8.4a2, and ActiveTcl distribution + - Many fixes in Tcl 7.x support + + * Bug fixes + - mmdisp: buffer re-use problem + - mmdisp: Data Scale bug + - mmsolve: output file format fixes + - mmsolve2d: check protocol only on ready threads + - batchsolve: check protocol only on ready threads + - documentation: updated HTML links + - Nb: More protection from buffer overflows and FPEs + - Net: Better recovery when account server not found + - Better [uplevel] preservation of Tcl_Obj's (floating point numbers) + - Removed most dependencies on Tk internals + + * New/revised features + - odtcols: New app for extracting data from ODT files + - oommf (bootstrap): removed senseless +console and +cwd options + - oommf (bootstrap): +platform checks for threaded Tcl/Tk + - omfsh: use Img instead of If, if available + - mmdisp: removed unused old code + - mmhelp: PNG image support if Img package present + - mmhelp: Refresh of a page doesn't have to re-render it. + - mmpe: passes through unrecognized fields + - mmsolve: MIF file read errors now logged + - mmsolve: log messages also reported via Oc_DefaultMessage + - mmsolve: work around Tcl fconfigure bug in mask file conversion + - Nb: Nb_IsFinite() + - Net: host/account servers: Removed expiration timeouts. + - Oc: tclIndex now generated on the fly. + - Oc: Can write to console via C Tcl_Write to TCL_STDOUT + - C++ exceptions assumed, override in config/cache. + ========== OOMMF 1.1b0 released 2000/04/04 ========== Significant changes since 1.1a2: diff -crN oommf-1.1b0/Changes.txt oommf/Changes.txt *** oommf-1.1b0/Changes.txt Tue Oct 2 20:32:51 2001 --- oommf/Changes.txt Tue Oct 2 20:32:50 2001 *************** *** 1,3 **** --- 1,40 ---- + ========== OOMMF 1.1b1 released 2001/10/02 ========== + Significant changes since 1.1b0: + + * Expanded Tcl/Tk support + - 8.3.3, 8.4a2, and ActiveTcl distribution + - Many fixes in Tcl 7.x support + + * Bug fixes + - mmdisp: buffer re-use problem + - mmdisp: Data Scale bug + - mmsolve: output file format fixes + - mmsolve2d: check protocol only on ready threads + - batchsolve: check protocol only on ready threads + - documentation: updated HTML links + - Nb: More protection from buffer overflows and FPEs + - Net: Better recovery when account server not found + - Better [uplevel] preservation of Tcl_Obj's (floating point numbers) + - Removed most dependencies on Tk internals + + * New/revised features + - odtcols: New app for extracting data from ODT files + - oommf (bootstrap): removed senseless +console and +cwd options + - oommf (bootstrap): +platform checks for threaded Tcl/Tk + - omfsh: use Img instead of If, if available + - mmdisp: removed unused old code + - mmhelp: PNG image support if Img package present + - mmhelp: Refresh of a page doesn't have to re-render it. + - mmpe: passes through unrecognized fields + - mmsolve: MIF file read errors now logged + - mmsolve: log messages also reported via Oc_DefaultMessage + - mmsolve: work around Tcl fconfigure bug in mask file conversion + - Nb: Nb_IsFinite() + - Net: host/account servers: Removed expiration timeouts. + - Oc: tclIndex now generated on the fly. + - Oc: Can write to console via C Tcl_Write to TCL_STDOUT + - C++ exceptions assumed, override in config/cache. + ========== OOMMF 1.1b0 released 2000/04/04 ========== Significant changes since 1.1a2: diff -crN oommf-1.1b0/README oommf/README *** oommf-1.1b0/README Tue Apr 4 06:18:20 2000 --- oommf/README Tue Oct 2 20:30:17 2001 *************** *** 1,8 **** README: OOMMF Object Oriented MicroMagnetic computing Framework ! Release 1.1b0 ! This file last modified on: $Date: 2000/04/04 10:18:20 $ OOMMF is a project in the Mathematical and Computational Sciences Division (MCSD) of ITL/NIST aimed at developing portable, extensible --- 1,8 ---- README: OOMMF Object Oriented MicroMagnetic computing Framework ! Release 1.1b1 ! This file last modified on: $Date: 2001/10/03 00:30:17 $ OOMMF is a project in the Mathematical and Computational Sciences Division (MCSD) of ITL/NIST aimed at developing portable, extensible *************** *** 18,24 **** Before you can do anything with OOMMF, you must have Tcl/Tk installed on your computer. The Tcl/Tk Core is available for free download from ! the Scriptics Corporation web site at . OOMMF requires at least Tcl version 7.5 and Tk version 4.1 on Unix platforms, and requires at least Tcl version 7.6 and Tk version 4.2 on Microsoft Windows platforms. OOMMF software does not support any alpha --- 18,24 ---- Before you can do anything with OOMMF, you must have Tcl/Tk installed on your computer. The Tcl/Tk Core is available for free download from ! the Tcl Developer eXchange at . OOMMF requires at least Tcl version 7.5 and Tk version 4.1 on Unix platforms, and requires at least Tcl version 7.6 and Tk version 4.2 on Microsoft Windows platforms. OOMMF software does not support any alpha *************** *** 30,36 **** with pre-compiled executables compatible with Tcl/Tk 8.3.x. Type the following commands at an MS-DOS Prompt to start using OOMMF: ! unzip oommf11b0_20000404.zip cd oommf tclsh83 oommf.tcl pimake upgrade tclsh83 oommf.tcl --- 30,36 ---- with pre-compiled executables compatible with Tcl/Tk 8.3.x. Type the following commands at an MS-DOS Prompt to start using OOMMF: ! unzip oommf11b1_20011002.zip cd oommf tclsh83 oommf.tcl pimake upgrade tclsh83 oommf.tcl *************** *** 38,44 **** For most OOMMF users on Unix, the following sequence of commands should upgrade, build, and run your OOMMF installation: ! gunzip -c oommf11b0_20000404.tar.gz | tar xvf - cd oommf oommf.tcl pimake distclean oommf.tcl pimake upgrade --- 38,44 ---- For most OOMMF users on Unix, the following sequence of commands should upgrade, build, and run your OOMMF installation: ! gunzip -c oommf11b1_20011002.tar.gz | tar xvf - cd oommf oommf.tcl pimake distclean oommf.tcl pimake upgrade diff -crN oommf-1.1b0/Readme.txt oommf/Readme.txt *** oommf-1.1b0/Readme.txt Tue Oct 2 20:32:51 2001 --- oommf/Readme.txt Tue Oct 2 20:32:50 2001 *************** *** 1,8 **** README: OOMMF Object Oriented MicroMagnetic computing Framework ! Release 1.1b0 ! This file last modified on: $Date: 2000/04/04 10:18:20 $ OOMMF is a project in the Mathematical and Computational Sciences Division (MCSD) of ITL/NIST aimed at developing portable, extensible --- 1,8 ---- README: OOMMF Object Oriented MicroMagnetic computing Framework ! Release 1.1b1 ! This file last modified on: $Date: 2001/10/03 00:30:17 $ OOMMF is a project in the Mathematical and Computational Sciences Division (MCSD) of ITL/NIST aimed at developing portable, extensible *************** *** 18,24 **** Before you can do anything with OOMMF, you must have Tcl/Tk installed on your computer. The Tcl/Tk Core is available for free download from ! the Scriptics Corporation web site at . OOMMF requires at least Tcl version 7.5 and Tk version 4.1 on Unix platforms, and requires at least Tcl version 7.6 and Tk version 4.2 on Microsoft Windows platforms. OOMMF software does not support any alpha --- 18,24 ---- Before you can do anything with OOMMF, you must have Tcl/Tk installed on your computer. The Tcl/Tk Core is available for free download from ! the Tcl Developer eXchange at . OOMMF requires at least Tcl version 7.5 and Tk version 4.1 on Unix platforms, and requires at least Tcl version 7.6 and Tk version 4.2 on Microsoft Windows platforms. OOMMF software does not support any alpha *************** *** 30,36 **** with pre-compiled executables compatible with Tcl/Tk 8.3.x. Type the following commands at an MS-DOS Prompt to start using OOMMF: ! unzip oommf11b0_20000404.zip cd oommf tclsh83 oommf.tcl pimake upgrade tclsh83 oommf.tcl --- 30,36 ---- with pre-compiled executables compatible with Tcl/Tk 8.3.x. Type the following commands at an MS-DOS Prompt to start using OOMMF: ! unzip oommf11b1_20011002.zip cd oommf tclsh83 oommf.tcl pimake upgrade tclsh83 oommf.tcl *************** *** 38,44 **** For most OOMMF users on Unix, the following sequence of commands should upgrade, build, and run your OOMMF installation: ! gunzip -c oommf11b0_20000404.tar.gz | tar xvf - cd oommf oommf.tcl pimake distclean oommf.tcl pimake upgrade --- 38,44 ---- For most OOMMF users on Unix, the following sequence of commands should upgrade, build, and run your OOMMF installation: ! gunzip -c oommf11b1_20011002.tar.gz | tar xvf - cd oommf oommf.tcl pimake distclean oommf.tcl pimake upgrade diff -crN oommf-1.1b0/app/mmarchive/appindex.tcl oommf/app/mmarchive/appindex.tcl *** oommf-1.1b0/app/mmarchive/appindex.tcl Mon Mar 20 14:02:51 2000 --- oommf/app/mmarchive/appindex.tcl Thu Apr 27 16:37:47 2000 *************** *** 1,7 **** Oc_Application Define { -name mmArchive ! -version 1.1.1.0 -machine omfsh -file mmarchive.tcl -options {-tk 0} --- 1,7 ---- Oc_Application Define { -name mmArchive ! -version 1.1.1.1 -machine omfsh -file mmarchive.tcl -options {-tk 0} diff -crN oommf-1.1b0/app/mmarchive/mmarchive.tcl oommf/app/mmarchive/mmarchive.tcl *** oommf-1.1b0/app/mmarchive/mmarchive.tcl Thu Mar 9 16:24:07 2000 --- oommf/app/mmarchive/mmarchive.tcl Thu Apr 27 16:37:47 2000 *************** *** 12,19 **** } Oc_Main SetAppName mmArchive ! Oc_Main SetVersion 1.1.1.0 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/03/09 21:24:07 $} _ date Oc_Main SetDate [string trim $date] Oc_Main SetAuthor [Oc_Person Lookup dgp] Oc_CommandLine Parse $argv --- 12,19 ---- } Oc_Main SetAppName mmArchive ! Oc_Main SetVersion 1.1.1.1 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/04/27 20:37:47 $} _ date Oc_Main SetDate [string trim $date] Oc_Main SetAuthor [Oc_Person Lookup dgp] Oc_CommandLine Parse $argv diff -crN oommf-1.1b0/app/mmdatatable/appindex.tcl oommf/app/mmdatatable/appindex.tcl *** oommf-1.1b0/app/mmdatatable/appindex.tcl Fri Feb 18 11:29:21 2000 --- oommf/app/mmdatatable/appindex.tcl Thu Apr 27 16:37:47 2000 *************** *** 1,7 **** Oc_Application Define { -name mmDataTable ! -version 1.1.1.0 -machine omfsh -file mmdatatable.tcl } --- 1,7 ---- Oc_Application Define { -name mmDataTable ! -version 1.1.1.1 -machine omfsh -file mmdatatable.tcl } diff -crN oommf-1.1b0/app/mmdatatable/mmdatatable.tcl oommf/app/mmdatatable/mmdatatable.tcl *** oommf-1.1b0/app/mmdatatable/mmdatatable.tcl Thu Mar 23 19:25:33 2000 --- oommf/app/mmdatatable/mmdatatable.tcl Thu Apr 27 16:37:47 2000 *************** *** 23,30 **** wm withdraw . Oc_Main SetAppName mmDataTable ! Oc_Main SetVersion 1.1.1.0 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/03/24 00:25:33 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] --- 23,30 ---- wm withdraw . Oc_Main SetAppName mmDataTable ! Oc_Main SetVersion 1.1.1.1 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/04/27 20:37:47 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] diff -crN oommf-1.1b0/app/mmdisp/makerules.tcl oommf/app/mmdisp/makerules.tcl *** oommf-1.1b0/app/mmdisp/makerules.tcl Mon Mar 27 00:58:26 2000 --- oommf/app/mmdisp/makerules.tcl Thu Apr 27 16:37:47 2000 *************** *** 52,64 **** puts $f [format { Oc_Application Define { -name mmDispSh ! -version 1.1.1.0 -machine %s -file "%s" } Oc_Application Define { -name conDispSh ! -version 1.1.1.0 -machine %s -file "%s" } --- 52,64 ---- puts $f [format { Oc_Application Define { -name mmDispSh ! -version 1.1.1.1 -machine %s -file "%s" } Oc_Application Define { -name conDispSh ! -version 1.1.1.1 -machine %s -file "%s" } diff -crN oommf-1.1b0/app/mmdisp/misc.tcl oommf/app/mmdisp/misc.tcl *** oommf-1.1b0/app/mmdisp/misc.tcl Fri Aug 20 09:57:36 1999 --- oommf/app/mmdisp/misc.tcl Tue May 8 17:52:38 2001 *************** *** 3,14 **** # Various Tcl/Tk utility scripts for the OOMMF 2D display program # - # Procedure to append a bindtag at the end of a window's - # curreng bindtag list - proc OMF_AppendBindTag { win newtag } { - bindtags $win [concat [bindtags $win] $newtag] - } - # Automatically select/deselect entire text upon Entry widget FocusIn/Out #bind Entry {+%W selection from 0 ; %W selection to end } bind Entry {+%W selection clear} --- 3,8 ---- *************** *** 18,33 **** # but not the , which I _really_ dislike, so I reinstated # the latter on 97/9/26. -mjd - set omfStdNumericFormat "%4.2f" - - proc OMF_FormatNumber { var {fmt {}}} { - if { [string match {} $fmt] } { - global omfStdNumericFormat - set fmt $omfStdNumericFormat - } - return [format $fmt $var] - } - # Load input filter program options set omfMmdispFilter [list [list *.gz {gzip -dc}]] Oc_Option Get Input filters omfMmdispFilter --- 12,17 ---- *************** *** 118,264 **** set _mmdispcmds(TroughColor) [format "#%04X%04X%04X" $tempr $tempg $tempb] } ! # Get a list of all descendents of a window (children, grandchildren, ...) ! proc OMF_GetDescendentList { basewin } { ! set winlist {} ! set childlist [winfo children $basewin] ! foreach w $childlist { ! lappend winlist $w ! eval lappend winlist [OMF_GetDescendentList $w] ! } ! return $winlist ! } ! ! # Get a list of all current toplevel windows. If import ! # $include_hidden is true, returns complete list. Otherwise ! # returns only those toplevel windows that are visible (viewable). ! proc OMF_GetTopLevelList { {include_hidden 0} } { ! set toplist "." ! foreach w [OMF_GetDescendentList .] { ! if { [string compare $w [winfo toplevel $w]] == 0 } { ! if { $include_hidden || [winfo viewable $w] } { ! lappend toplist $w ! } ! } ! } ! return $toplist ! } # Push/Pop stack operators ! proc OMF_Push { stackname newvalue } { ! upvar $stackname stack ! lappend stack $newvalue ! } ! proc OMF_Pop { stackname } { ! # NOTE: Returns {} if stack is empty ! upvar $stackname stack ! if { ![info exists stack] } { return {} } ! set size [llength $stack] ! if { $size < 1 } { return {} } ! incr size -1 ! set top_elt [lindex $stack $size] ! set stack [lreplace $stack $size $size] ! return $top_elt ! } ! ! # Check if $x is a valid base-ten number ! proc OMF_IsNumber { x } { ! # Returns 1 iff $x is a valid number ! ! # Don't allow octal representations ! if { [regexp {^ *[-+]?0+ *$} "$x"] } { return 1 } ;# This is a 0 ! if { [regexp {^ *[-+]?0[^.]*$} "$x"] } { return 0 } ! ! # If not octal, check for valid forms ! if { [regexp {^ *[-+]?[0-9]+\.?[0-9]* *$} "$x"] } { return 1 } ! if { [regexp {^ *[-+]?[0-9]*\.?[0-9]+ *$} "$x"] } { return 1 } ! # Else, illegal form. ! return 0 ! } ! ! # Return a modified string by removing anything that is not ! # 0-9 or '.', and keeping only first '.'. ! # NOTE: This routine *may* return the string ".", which is ! # *not* a legal number for most (any?) standard ! # Tcl/Tk routines. This makes for more amiable ! # interactive editing of a traced variable, however. ! proc OMF_MakeValidPosNumber { string } { ! regsub -all -nocase {[^0-9.]} $string {} stringfix ! # Now remove all '.''s except the first. Do this by ! # temporarily changing the first '.' to an 'x' ! if {[regsub {\.} $stringfix {x} stringfix]} { ! regsub -all {\.} $stringfix {} stringfix ! regsub {x} $stringfix {.} stringfix ! } ! return $stringfix ! } ! ! # A trace proc providing OMF_MakeValidPosNumber service. ! proc OMF_KeepValidPosNumber { name elt op } { ! global mmd_log ! if { ![string match {} $elt] } { set name ${name}($elt) } ! upvar $name x ! if {![info exists x]} { ! # Try global level ! upvar #0 $name x ! if {![info exists x]} { ! $mmd_log Append "Error in proc OMF_KeepValidPosNumber, \ ! run level #[info level]: \ ! Unable to locate variable $name" ! return {} ! } ! } ! set x [OMF_MakeValidPosNumber $x] ! } ! ! # Similar to OMF_MakeValidPosNumber, but allows a leading '-'. ! # NOTE: This routine *may* return the string ".", which is ! # *not* a legal number for most (any?) standard ! # Tcl/Tk routines. This makes for more amiable ! # interactive editing of a traced variable, however. ! proc OMF_MakeValidNumber { string } { ! regsub -all -nocase {[^-0-9.]} $string {} stringfix ! # Now remove all '.''s except the first. Do this by ! # temporarily changing the first '.' to an 'x' ! if {[regsub {\.} $stringfix {x} stringfix]} { ! regsub -all {\.} $stringfix {} stringfix ! regsub {x} $stringfix {.} stringfix ! } ! # Next strip out any "-"'s except leading one, if any. ! regexp -- {^(-?)(.*)} $stringfix junk prefix number ! regsub -all -- {-} $number {} number ! return $prefix$number ! } ! ! # A trace proc providing OMF_MakeValidNumber service. ! proc OMF_KeepValidNumber { name elt op } { ! global mmd_log ! if { ![string match {} $elt] } { set name ${name}($elt) } ! upvar $name x ! if {![info exists x]} { ! # Try global level ! upvar #0 $name x ! if {![info exists x]} { ! $mmd_log Append "Error in proc OMF_KeepValidNumber, \ ! run level #[info level]: \ ! Unable to locate variable $name" ! return {} ! } ! } ! set x [OMF_MakeValidNumber $x] ! } ! ! # Checks if x & y would differ if converted the the omfStdNumericFormat. ! # Used bindings to determine if the shadowed variable needs ! # updating. Returns 1 iff x!=y after conversion. ! proc OMF_StdFormatCompare { x y } { ! global omfStdNumericFormat ! set x [format $omfStdNumericFormat $x] ! set y [format $omfStdNumericFormat $y] ! if {$x==$y} { return 0 } ! return 1 ! } # Converts width, height, xcenter & ycenter across rotations proc OMF_RotateDimensions { angle widthname heightname \ --- 102,125 ---- set _mmdispcmds(TroughColor) [format "#%04X%04X%04X" $tempr $tempg $tempb] } ! # Removed - Can't find evidence that anything has used these in a long time. ! # proc OMF_GetDescendentList args {} ! # proc OMF_GetTopLevelList args {} ! # proc OMF_AppendBindTag args {} # Push/Pop stack operators ! # Removed - Can't find evidence that anything has used these in a long time. ! # proc OMF_Push args {} ! # proc OMF_Pop args {} ! ! # Removed - the Ow_* widgets do their own validity checks ! # proc OMF_MakeValidPosNumber args {} ! # proc OMF_KeepValidPosNumber args {} ! # proc OMF_MakeValidNumber args {} ! # proc OMF_KeepValidNumber args {} ! # Removed - Can't find evidence that anything has used this in a long time. ! # proc OMF_StdFormatCompare args {} # Converts width, height, xcenter & ycenter across rotations proc OMF_RotateDimensions { angle widthname heightname \ *************** *** 336,951 **** return 0 } ! ##### ! # Info message dialog box (non-modal) ! # The return value is the window designation ! # Set import bitmap to "none" to get no bitmap ! proc OMF_InfoDialog { message {title {}} {bitmap {}} {width {}} \ ! {justification "left"} } { ! # First make up a unique window name ! set id 0 ! set basename .omfInfoDialogWin ! while { [winfo exists "$basename$id"] } { ! if { $id > 200 } { ! Ow_FatalError "Too many (>$id) open InfoDialog windows" ! } ! incr id ! } ! set window $basename$id ! ! if { {} == $title } { set title "Informational Message" } ! ! toplevel $window ! wm group $window . ! wm title $window "$title" ! Ow_PositionChild $window ! ! global omfDialogWidth ! if { {} == "$width" } { set width $omfDialogWidth } ;# Default width ! ! frame $window.top ! frame $window.bottom ! # Insert beam to insure minimum width ! frame $window.top.beam -height 0 -width $width ! pack $window.top.beam -side top ! if { {} == $bitmap } { set bitmap info } ! if { [string compare "none" $bitmap] != 0 } { ! label $window.top.bitmap -bitmap $bitmap ! pack $window.top.bitmap -side left -anchor w -padx 2m ! } ! ! message $window.top.msg -width $width -text $message \ ! -justify $justification ! ## UNFORTUNATELY, the message widget doesn't support "selections". :-[ ! ! pack $window.top.msg -side left -fill both -expand 1 ! ! set current_focus [focus] ! if { [string match {} $current_focus] } { ! set current_focus "." ! } else { ! set current_focus [winfo toplevel [focus]] ! } ! button $window.bottom.btn -text "OK" \ ! -command "OMF_SetFocus $current_focus $window; destroy $window" ! ! # Note: It is important to release focus _before_ ! # destroying the window, as otherwise the focus can ! # get misplaced. -mjd 2/97 ! # Note 2: Forcing the focus against the window manager can ! # make for some strangeness. With the above code, when the ! # message box is closed, the focus jumps to the window that ! # had the focus when the message box was created (or "."; ! # OMF_SetFocus falls back to "." if the import window doesn't ! # exist). I may decide to disable this in the future. -mjd 9/97 ! wm protocol $window WM_DELETE_WINDOW "$window.bottom.btn invoke" ! pack $window.bottom.btn -side top -expand 1 ! pack $window.top $window.bottom -side top -fill both -expand 1 ! Ow_SetIcon $window ! ! OMF_InfoDialogHelper $window ! # WARNING WILL ROBINSON: This routine trys to control the ! # focus in a sensible manner. To do this, it waits for ! # $window.bottom.btn to become viewable, which may require ! # event loop processing. This can cause REENTRANCY PROBLEMS ! # IN EVENT BINDINGS. You have been warned. ! ! return $window ! } ! ! proc OMF_InfoDialogHelper { window } { ! if {![winfo exists $window.bottom.btn]} { ! return ! } ! WaitVisible $window.bottom.btn ! ! set current_focus [focus] ! if { [string match {} $current_focus] } { ! set current_focus "." ! } else { ! set current_focus [winfo toplevel [focus]] ! } ! $window.bottom.btn configure \ ! -command "OMF_SetFocus $current_focus $window; destroy $window" ! focus $window.bottom.btn ! } ! ! ! # Routine to direct mouse & keyboard focus to a specified ! # top-level window, provided it is not iconified (or withdrawn). ! # If called by a window "destroy" routine, it is important to ! # call this _before_ the window is destroyed, as otherwise the ! # focus may be "misplaced" (i.e., lost). Also if you specify ! # the "other top-level window", then tlw will be raised with ! # respect to that window. (Note: Linux/AXP + XFree is painfully ! # slow on 'raise $tlw', but 'raise $tlw $otlw' is quick. ! proc OMF_SetFocus { tlw {otlw ""} } { ! if { ![winfo exists $tlw] } { set tlw "." } ! set top [winfo toplevel $tlw] ! if {[string compare [wm state $top] normal]==0} { ! if {[string compare $otlw ""]!=0 && [winfo exists $otlw]} { ! raise $top $otlw ! } ! focus [focus -lastfor $tlw] ;# Return focus to last window ! # in $tlw that had focus ! } ! } ! ! # Convert .'s in $window to _'s, and extract everything up to ! # the second underscore as a (per-call) ID that can be used to ! # form global variable names. This proc assumes that $window ! # begins with a leading '.'. This routine also extracts the ! # base (up to second .) and extension part of $window ! # NOTE: If "$id" is sent in place of $window, then this routine ! # will return "$id" unaltered (i.e. "OMF_GetID $w" == ! # "OMF_GetID [OMF_GetID $w]") ! proc OMF_GetID { window {idname ""} {basename ""} {extname ""} } { ! if { "$idname" != "" } { upvar $idname id } ! if { "$basename" != "" } { upvar $basename base } ! if { "$extname" != "" } { upvar $extname ext } ! set base ""; ! set id "$window" ;# If regexp doesn't match, we get $window back ! regexp {^ *(\.[^.]*)(.*)$} "$window" full base ext ! regsub -all {\.} "$base" _ id ! return $id ! } ! ! # OMF_EntryFollow copies $name to ${name}Entry ! proc OMF_EntryFollow { name elt op } { ! # Assumes $elt == "" ! upvar #0 $name base ! global mmd_log ! if {![info exists base]} { ! $mmd_log Append \ ! "Error in OMF_EntryFollow; global variable ->$name<- does not exist" ! return ! } ! upvar #0 ${name}Entry follower ! if {![info exists follower]} { ! $mmd_log Append -nonewline "Error in OMF_EntryFollow;" ! $mmd_log Append " global variable ->${name}Entry<- does not exist" ! return ! } ! set follower $base ! } ! ! # OMF_ScaleFollow copies $name to ${name}Scale ! proc OMF_ScaleFollow { name elt op } { ! # Assumes $elt == "" ! upvar #0 $name base ! upvar #0 ${name}Scale follower ! global mmd_log ! if {![info exists base]} { ! $mmd_log Append \ ! "Error in OMF_ScaleFollow; global variable ->$name<- does not exist" ! return ! } ! if {![info exists follower]} { ! $mmd_log Append -nonewline "Error in OMF_ScaleFollow;" ! $mmd_log Append " global variable ->${name}Scale<- does not exist" ! return ! } ! set follower $base ! } ! ! # OMF_ScaleEntryFollow copies $name to ' regsub {Scale$} "$name" "Entry" ' ! proc OMF_ScaleEntryFollow { name elt op } { ! # Assumes $elt == "" ! upvar #0 $name base ! global mmd_log ! # Make sure this routine isn't be called from OMF_ScaleFollow, ! # because in that case $name is "follower" ! if { ![info exist base] } return ! regsub {Scale$} "$name" "Entry" followername ! upvar #0 $followername follower ! if {![info exists follower]} { ! $mmd_log Append -nonewline "Error in OMF_ScaleEntryFollow;" ! $mmd_log Append " global variable ->$followername<- does not exist" ! return ! } ! global omfStdNumericFormat ! set follower [format $omfStdNumericFormat $base] ! } # Produce an entry window collection: ! # $framename, $framename.label, & $framename.value ! # You also get $framename.scrx if '$scrollbar' is true. ! # If you set "numeric" to non-zero, then the displayed value is held ! # in a shadow variable called ${varname}Entry, at the global level. ! # It is copied the "varname" upon a or a event, ! # and the value from "varname" is copied back into ${varname}Entry on ! # an event, or anytime "varname" changes. ! # Note: Variables tied to entry widgets are at the global level. Also, ! # bindings run at global level, so either way "varname" must be at ! # the global level. ! # If "numeric" is >0, then the value is kept a valid positive number ! # (via OMF_KeepValidPosNumber), or if "numeric" <0 then it is kept at ! # any valid number (via OMF_KeepValidNumber). ! proc OMF_MakeEntryWindow { framename label labelwidth varname varwidth \ ! scrollbar {relief "raised"} {numeric "0"}} { ! global $varname ! frame $framename -relief $relief -bd 2 ! label $framename.label -text "$label" ! if {[string compare $labelwidth ""]!=0} { ! $framename.label configure -width $labelwidth -anchor e ! } ! entry $framename.value -relief sunken -bd 2 \ ! -width $varwidth -bg [$framename.label cget -bg] ! # The default color scheme under Tcl 8.0 + Windows makes ! # labels a light gray, and entry backgrounds bright white. ! # *I* think it looks pretty hideous... -mjd 97/10/3 ! ! OMF_AppendBindTag $framename.value omfCursorOverride ! pack $framename.label -side left -anchor e ! if { $scrollbar } { ! $framename.value configure \ ! -xscrollcommand "$framename.scrx set" ! scrollbar $framename.scrx -bd 2 -troughcolor [TroughColor] \ ! -orient horizontal -command "$framename.value xview" ! pack $framename.scrx -side bottom -fill x ! } ! if { $numeric != 0 } { ! global ${varname}Entry ! $framename.value configure -textvariable ${varname}Entry \ ! -justify right -font [Oc_Font Get bold] ! if { $numeric > 0 } { ! trace variable ${varname}Entry w OMF_KeepValidPosNumber ! } else { ! trace variable ${varname}Entry w OMF_KeepValidNumber ! } ! bind $framename.value \ ! "set $varname \[set ${varname}Entry\]" ! bind $framename.value \ ! "set $varname \[set ${varname}Entry\]" ! bind $framename.value \ ! "set ${varname}Entry \[set $varname\]" ! trace variable $varname w OMF_EntryFollow ! } else { ! $framename.value configure -textvariable $varname ! } ! pack $framename.value -fill x -expand 1 -side left ! } ! ! # Produce a entry+scale window collection ! proc OMF_MakeEntryScaleWindow {framename label labelwidth varname varwidth \ ! scalewidth scalemin scalemax scalestep procname} { ! # NOTE: varname *must* be a global variable name ! # Make widgets ! frame $framename -borderwidth 2 -relief ridge ! frame $framename.col1 ! frame $framename.col2 -bd 2 -relief sunken ! label $framename.label -text $label -anchor e ! if {[string compare $labelwidth {}]!=0} { ! $framename.label configure -width $labelwidth ! } ! entry $framename.value -textvariable ${varname}Entry \ ! -width $varwidth -bd 0 -justify right \ ! -bg [$framename.label cget -bg] ! # The default color scheme under Tcl 8.0 + Windows makes ! # labels a light gray, and entry backgrounds bright white. ! # *I* think it looks pretty hideous... -mjd 97/10/3 ! ! OMF_AppendBindTag $framename.value omfCursorOverride ! ! $framename.value configure -font [Oc_Font Get bold] ! ! scale $framename.scale -variable ${varname}Scale \ ! -orient horizontal -troughcolor [TroughColor] -showvalue 0 \ ! -length $scalewidth -from $scalemin -to $scalemax \ ! -resolution $scalestep -bigincrement 0 -bd 0 ! # Pack widgets ! pack $framename.label -side left -in $framename.col1 ! pack $framename.value -side left -in $framename.col2 ! pack $framename.scale -side right -in $framename.col2 -fill x -expand 1 ! pack $framename.col1 -side left ! pack $framename.col2 -side right -fill x -expand 1 ! # Bind widgets ! bind $framename.value \ ! "OMF_EntryScaleBinding $procname $varname" ! bind $framename.value \ ! "OMF_EntryScaleBinding $procname $varname 1" ! bind $framename.value "OMF_EntryScaleEscapeBinding $varname" ! bind $framename.scale \ ! "OMF_EntryScaleButtonReleaseBinding %W %x %y $procname $varname" ! bind $framename.scale \ ! "tkCancelRepeat ; OMF_EntryScaleEscapeBinding $varname" ! # Note: tkCancelRepeat is an apparently undocumented call that turns ! # off the auto-stepping feature initiated by a event in the ! # scale trough. If this breaks in a new release of Tk, then another ! # approach might be to try using "%W config -state disabled/normal" calls. ! bind $framename.scale \ ! "OMF_ScaleMotionBinding %W %x %y" ! bind $framename.scale \ ! "OMF_ScaleScaleBinding %W $procname $varname 0" ! bind $framename.scale \ ! "OMF_ScaleScaleBinding %W $procname $varname 1" ! bind $framename.scale "OMF_EntryScaleEscapeBinding $varname" ! bind $framename.scale "set ${varname}Scale \[%W get %x %y\]" ! # Set traces ! global $varname ${varname}Entry ${varname}Scale ! ### Tie *Entry variables to *Scale variables ! trace variable ${varname}Scale w OMF_ScaleEntryFollow ! ### Tie *Entry & *Scale variables to base variables ! trace variable $varname w OMF_EntryFollow ! trace variable $varname w OMF_ScaleFollow ! ### Make sure *Entry variable gets written in 'Standard Numeric Format' ! if {![info exists $varname]} { set $varname 0.0 } ! set $varname [OMF_FormatNumber [set $varname]] ! set ${varname}Entry [set $varname] ! } ! ! proc OMF_EntryScaleBinding { procname varname {stepcheck 0}} { ! global $varname ${varname}Entry ! # Make sure we got valid input from user ! if { [OMF_IsNumber [set ${varname}Entry]] } { ! if {!$stepcheck || [OMF_StdFormatCompare \ ! [set $varname] [set ${varname}Entry]]} { ! $procname [set ${varname}Entry] ! } ! } else { ! set ${varname}Entry [set $varname] ! } ! set ${varname}Entry [OMF_FormatNumber [set $varname]] ! } ! ! proc OMF_ScaleScaleBinding { widget procname varname {stepcheck 0}} { ! upvar #0 $varname var ! upvar #0 ${varname}Scale varscale ! if {!$stepcheck || 2*abs($var-$varscale) > [$widget cget -resolution]} { ! $procname $varscale ! } ! } ! ! proc OMF_EntryScaleEscapeBinding { varname } { ! global $varname ${varname}Entry ${varname}Scale ! global omfStdNumericFormat ! set ${varname}Scale [set $varname] ! set ${varname}Entry [format $omfStdNumericFormat [set $varname]] ! # Note: Order is important here. There is a trace on ${varname}Scale ! # that resets ${varname}Entry, and some Tcl/Tk interpreters ! # will force ${varname}Scale to the nearest scale resolution ! # step, which then gets copied to ${varname}Entry by the tracing. ! # So we must set ${varname}Entry *after* ${varname}Scale. ! } ! ! proc OMF_EntryScaleButtonReleaseBinding { w x y procname varname } { ! # Updates $varname if button release was over slider or trough, ! # otherwise calls OMF_EntryScaleEscapeBinding ! global $varname ${varname}Entry ${varname}Scale ! if {[string compare [$w identify $x $y] {}]!=0} { ! $procname [set ${varname}Scale] ! } else { ! OMF_EntryScaleEscapeBinding $varname ! } ! } ! ! proc OMF_ScaleMotionBinding { w x y } { ! if {[string compare [$w identify $x $y] {}]==0} {return -code break} ! } # Produce a radio box window collection ! # Each elt of "args" is a label/value list. Any args elt ! # with only 1 sub-element is automatically defined a value ! # equivalent to its label, but all lowercase. ! # Ex: OMF_MakeRadioList frame "Sample:" "" sample {} \ ! # A {B 2} "C Button" {"Last button" 4} ! # gets label/values of: A/a B/2 "C Button"/"c button" "Last button"/4 ! proc OMF_MakeRadioList {framename rows center label labelwidth \ ! varname tracename args} { ! # Note: If you want centering inside the frame, do ! # pack $framename.label -side left -anchor e -expand 1 ! # and on the last button do ! # pack $framename.r$j -side left -anchor w -expand 1 ! frame $framename -borderwidth 2 -relief ridge ! label $framename.label -text "$label" -anchor e ! if {[string compare $labelwidth {}]!=0} { ! $framename.label configure -width $labelwidth ! } ! if {$rows<2} { ! pack $framename.label -side left ! } else { ! pack $framename.label -side top ! } ! if {$center} { ! pack configure $framename.label -anchor e -expand 1 ! } ! set j 0 ! foreach i $args { ! if {[llength $i]>2} { ! Ow_FatalError "Too long list element: $i" \ ! "OMF_MakeRadioList Error" ! } ! set text "" ! if {[llength $i]>0} { ! set text [lindex $i 0] ! } ! if {[llength $i]>1} { ! set value [lindex $i 1] ! } else { ! set value [string tolower $text] ! } ! radiobutton $framename.r$j -text $text -variable $varname \ ! -value $value ! if {$rows<2} { ! pack $framename.r$j -side left -anchor w ! } else { ! pack $framename.r$j -side left -expand 1 ! } ! incr j ! } ! if {$center} { ! pack configure $framename.r[expr {$j-1}] -expand 1 ! } ! if {[string compare $tracename {}]!=0} { ! global $varname; trace variable $varname w $tracename ! } ! } ! ! # Converts a length specification of the form 4.5i (4.5 inches) to an ! # equivalent length in specified units, and returns the converted length ! # *without* a suffix. Valid units/suffixes are: c (cm), i (inch), m (mm), ! # and p for printer's points (=1/72 inch). If no suffix is found then ! # p is assumed. This is consistent with the interpretation used by Tk's ! # canvas widget's 'postscript' command. The default output unit is ! # centimeters. ! proc OMF_ConvertUnits { length {newunits "c"}} { ! set length [string trim $length] ! if {![regexp {^(-?[0-9.]+)(.?)} $length match number dimension]} { ! Ow_FatalError "Invalid length: $length" "OMF_ConvertToCm Error" ! } ! # Determine multiplier to convert to cm ! switch -exact -- [string tolower $dimension] { ! c { set multa 1. } ! i { set multa 2.54 } ! m { set multa 0.1 } ! {} - ! p { set multa [expr 2.54/72.] } ! default { ! Ow_FatalError "Invalid dimension ($dimension) on length: \ ! $length" "OMF_ConvertUnits Error" ! } ! } ! # Determine multiplier to convert from cm to "newunits" ! switch -exact -- [string tolower $newunits] { ! c { set multb 1. } ! i { set multb 1./2.54 } ! m { set multb 10. } ! {} - ! p { set multb [expr 72./2.54] } ! default { ! Ow_FatalError "Invalid output unit request: $newunits" \ ! "OMF_ConvertUnits Error" ! } ! } ! return [expr {$number*$multa*$multb}] ! } # Print a canvas ! # The input is an array including the following fields: ! # canvas - name of canvas widget ! # inname - name of file being displayed ! # outname - name of output file or pipe ! # orient - portrait | landscape ! # size - output width *or* height (not both), in the format ! # '-pagewidth 3.i' (3 inches width), or ! # '-pageheight 5.c' (5 cm high), for example ! # papertype - letter | legal | A4 | A3 ! # clip - 1 | 0 (1=>print only displayed region of canvas) ! # xmargin - left/right margin, with units. E.g.: 1.i ! # ymargin - top/bottom margin, as above ! # position - One of: c nw n ne e se s sw w ! proc OMF_PrintCanvas { parr } { ! upvar $parr popt ! set errcode 0 ! ! # File overwrite check ! set popt(outname) [string trim $popt(outname)] ! if { "|" != [string index $popt(outname) 0] \ ! && [file exists $popt(outname)] } { ! # File is not a pipe, and already exists. ! # Check with user before overwriting. ! global ProgName ! set response [Ow_Dialog 1 "$ProgName: Print Warning" \ ! warning "Overwrite existing file $popt(outname)?" \ ! {} "1" "Yes" "No"] ! if { $response != 0 } { ! # First (0'th) button (which is "Yes") _not_ selected ! set errcode 1 ! return $errcode ! } ! } ! ! # Set paper dimensions ! switch -exact -- [string tolower $popt(papertype)] { ! letter { set xmax 8.5i; set ymax 11i } ! legal { set xmax 8.5i; set ymax 14i } ! a4 { set xmax 21.c; set ymax 29.7c } ! a3 { set xmax 29.7c; set ymax 42.c } ! default { Ow_FatalError "Illegal papertype: $popt(papertype)" \ ! "OMF_PrintCanvas Error" } ! } ! ! # Calculate positioning (in cm) ! set xmax [OMF_ConvertUnits $xmax] ! set ymax [OMF_ConvertUnits $ymax] ! set xmargin [OMF_ConvertUnits $popt(xmargin)] ! set ymargin [OMF_ConvertUnits $popt(ymargin)] ! if {[string compare "landscape" [string tolower $popt(orient)]]==0} { ! # Rotation notes: If $rotate==1, then the 'page' coordinate system ! # origin is moved to the upper lefthand corner of the page, with ! # +x running down the page and +y running to the right. If you ! # adopt this reference frame, then you can ignore the rotation ! # and just pretend you are working from the start on a landscape'd ! # page. The man page and online documentation ! # http://www.sunlabs.com/tcl/development/man/TkCmd/canvas.n.html#M55 ! # says "in rotated output the x-axis runs along the long dimension ! # of the page (``landscape'' orientation)." This is true for ! # the 'canvas' coordinate system, but not true for the 'page' ! # coordinate system (adjusted with the -pagex & -pagey options). ! set rotate 1 ! set temp $xmargin ; set xmargin $ymargin; set ymargin $temp ! } else { set rotate 0 } ! # The following page offsets are used in conjuction ! # with the '$canvas postscript -anchor' option ! if {"$popt(position)"==""} { set $popt(position) "c" } ;# Safety ! if {[string first "n" $popt(position)]>=0} { ! # Position at top of page, minus margin ! if {!$rotate} { ! set yoff [expr {$ymax-$ymargin}] ! } else { ! set xoff $xmargin ! } ! } elseif {[string first "s" $popt(position)]>=0} { ! # Position along page bottom margin ! if {!$rotate} { ! set yoff $ymargin ! } else { ! set xoff [expr {$xmax-$xmargin}] ! } ! } else { ! # Top/bottom center ! if {!$rotate} { ! set yoff [expr {$ymax/2.}] ! } else { ! set xoff [expr {$xmax/2.}] ! } ! } ! if {[string first "e" $popt(position)]>=0} { ! # Position page right, minus margin ! if {!$rotate} { ! set xoff [expr {$xmax-$xmargin}] ! } else { ! set yoff [expr {$ymax-$ymargin}] ! } ! } elseif {[string first "w" $popt(position)]>=0} { ! # Position page left, plus margin ! if {!$rotate} { ! set xoff $xmargin ! } else { ! set yoff $ymargin ! } ! } else { ! # Left/right center ! if {!$rotate} { ! set xoff [expr {$xmax/2.}] ! } else { ! set yoff [expr {$ymax/2.}] ! } ! } ! ! # Setup crop options ! if {$popt(crop)} { ! set cropoptions {} ! } else { ! # Printing whole canvas ! set sr [.canvas_frame.canvas cget -scrollregion] ! set width [expr {[lindex $sr 2] - [lindex $sr 0]}] ! set height [expr {[lindex $sr 3] - [lindex $sr 1]}] ! set cropoptions "-x 0 -y 0 -width $width -height $height" ! } ! ! ! # Print ! set output {} ! set errmsg {} ! if { [catch { ! set output [open $popt(outname) w] ! puts -nonewline $output \ ! [eval $popt(canvas) postscript -colormode color \ ! $popt(size) -pageanchor $popt(position) \ ! -pagex ${xoff}c -pagey ${yoff}c -rotate $rotate \ ! $cropoptions ] ! } errmsg] } { ! global ProgName ! Ow_NonFatalError "Error printing to $popt(outname): $errmsg" \ ! "$ProgName: Print Error" ! set errcode 2 ! } ! catch { ! if { ![string match {} $output] } { close $output } ! } ! ! return $errcode ! } --- 197,233 ---- return 0 } ! # Removed - Replaced by the proc Ow_Dialog ! # proc OMF_InfoDialog args {} ! # proc OMF_InfoDialogHelper args {} ! # proc OMF_SetFocus args {} ! # Removed - Can't find evidence that anything has used this in a long time. ! # proc OMF_GetID args {} # Produce an entry window collection: ! # Removed - Can't find evidence that anything has used this in a long time. ! # proc OMF_MakeEntryWindow args {} ! # proc OMF_EntryFollow args {} ! ! # Produce an entry+scale window collection ! # Removed - These have now been replaced by the Oc_Class Ow_EntryScale ! # proc OMF_MakeEntryScaleWindow args {} ! # proc OMF_EntryScaleBinding args {} ! # proc OMF_ScaleScaleBinding args {} ! # proc OMF_EntryScaleEscapeBinding args {} ! # proc OMF_EntryScaleButtonReleaseBinding args {} ! # proc OMF_ScaleMotionBinding args {} ! # proc OMF_ScaleEntryFollow args {} ! # proc OMF_ScaleFollow args {} ! # proc OMF_IsNumber args {} # Produce a radio box window collection ! # Removed - Can't find evidence that anything has used this in a long time. ! # proc OMF_MakeRadioList args {} # Print a canvas ! # Removed - This has now been replaced by the Oc_Class Ow_PrintDlg ! # proc OMF_PrintCanvas args {} ! # proc OMF_ConvertUnits args {} diff -crN oommf-1.1b0/app/mmdisp/mmdispcmds.cc oommf/app/mmdisp/mmdispcmds.cc *** oommf-1.1b0/app/mmdisp/mmdispcmds.cc Mon Mar 20 20:54:15 2000 --- oommf/app/mmdisp/mmdispcmds.cc Tue Sep 5 14:07:27 2000 *************** *** 244,249 **** --- 244,265 ---- int DrawFrame(ClientData,Tcl_Interp *interp,int argc,char** argv) { + /* + * We use the following buffer to store commands for passing to + * Tcl_Eval(). It is important that we do not use the global + * buffer, buf, for commands evaluted by Tcl_Eval() since that is + * used to write result strings to Tcl_AppendResult(). If the + * contents of a buffer are overwritten while Tcl_Eval() is + * evaluating them, bad results can happen. + * + * Note that similar bad things can happen if the contents of + * cmdbuf are overwritten which Tcl_Eval() evaluates them. This + * means it is a bad thing for DrawFrame() to appear on the call + * stack twice. Take care that none of the Tcl_Eval()s below make + * another call to DrawFrame(). + */ + static CHAR cmdbuf[MY_BUF_SIZE]; + int error_code; Tcl_ResetResult(interp); if(argc!=2) { *************** *** 253,266 **** return TCL_ERROR; } ! sprintf(buf,"%s delete all ;# update idletasks",argv[1]); /// Uncomment the "update idletasks" command to get a white /// screen between frames ! Tcl_Eval(interp,buf); // Clear canvas error_code=myFrame.Show(argv[1]); // Redraw canvas ! sprintf(buf,"global DrawFrameCount; incr DrawFrameCount"); ! Tcl_Eval(interp,buf); // Increment DrawFrameCount variable /* Adjust subsample setting to actual value. * Note: Any tracings on plot_config triggered as a result --- 269,282 ---- return TCL_ERROR; } ! sprintf(cmdbuf,"%s delete all ;# update idletasks",argv[1]); /// Uncomment the "update idletasks" command to get a white /// screen between frames ! Tcl_Eval(interp,cmdbuf); // Clear canvas error_code=myFrame.Show(argv[1]); // Redraw canvas ! sprintf(cmdbuf,"global DrawFrameCount; incr DrawFrameCount"); ! Tcl_Eval(interp,cmdbuf); // Increment DrawFrameCount variable /* Adjust subsample setting to actual value. * Note: Any tracings on plot_config triggered as a result diff -crN oommf-1.1b0/app/mmdisp/mmdispcmds.h oommf/app/mmdisp/mmdispcmds.h *** oommf-1.1b0/app/mmdisp/mmdispcmds.h Mon Mar 20 20:54:15 2000 --- oommf/app/mmdisp/mmdispcmds.h Thu Apr 27 16:37:47 2000 *************** *** 20,26 **** #define MMDISPCMDS_MAJOR_VERSION 1 #define MMDISPCMDS_MINOR_VERSION 1 #define MMDISPCMDS_RELEASE_LEVEL 1 ! #define MMDISPCMDS_RELEASE_SERIAL 0 #define MMDISPCMDS_VERSION OC_MAKE_VERSION(MMDISPCMDS) --- 20,26 ---- #define MMDISPCMDS_MAJOR_VERSION 1 #define MMDISPCMDS_MINOR_VERSION 1 #define MMDISPCMDS_RELEASE_LEVEL 1 ! #define MMDISPCMDS_RELEASE_SERIAL 1 #define MMDISPCMDS_VERSION OC_MAKE_VERSION(MMDISPCMDS) diff -crN oommf-1.1b0/app/mmdisp/mmdispcmds.tcl oommf/app/mmdisp/mmdispcmds.tcl *** oommf-1.1b0/app/mmdisp/mmdispcmds.tcl Fri Feb 18 12:06:56 2000 --- oommf/app/mmdisp/mmdispcmds.tcl Thu Apr 27 16:37:47 2000 *************** *** 2,15 **** # # Pure Tcl commands supporting mmDisp # ! # Last modified on: $Date: 2000/02/18 17:06:56 $ # Last modified by: $Author: dgp $ # Verify that C++ portion of this version of the Mmdispcmds extension # has been initialized # # NOTE: version number below must match that in ./mmdispcmds.h ! package require -exact Mmdispcmds 1.1.1.0 Oc_CheckTclIndex Mmdispcmds --- 2,15 ---- # # Pure Tcl commands supporting mmDisp # ! # Last modified on: $Date: 2000/04/27 20:37:47 $ # Last modified by: $Author: dgp $ # Verify that C++ portion of this version of the Mmdispcmds extension # has been initialized # # NOTE: version number below must match that in ./mmdispcmds.h ! package require -exact Mmdispcmds 1.1.1.1 Oc_CheckTclIndex Mmdispcmds diff -crN oommf-1.1b0/app/mmdisp/scripts/appindex.tcl oommf/app/mmdisp/scripts/appindex.tcl *** oommf-1.1b0/app/mmdisp/scripts/appindex.tcl Mon Mar 27 00:58:26 2000 --- oommf/app/mmdisp/scripts/appindex.tcl Thu Apr 27 16:37:47 2000 *************** *** 1,13 **** Oc_Application Define { -name mmDisp ! -version 1.1.1.0 -machine mmDispSh -file mmdisp.tcl } Oc_Application Define { -name avf2ave ! -version 1.1.1.0 -machine conDispSh -file avf2ave.tcl -options {-tk 0} --- 1,13 ---- Oc_Application Define { -name mmDisp ! -version 1.1.1.1 -machine mmDispSh -file mmdisp.tcl } Oc_Application Define { -name avf2ave ! -version 1.1.1.1 -machine conDispSh -file avf2ave.tcl -options {-tk 0} *************** *** 16,22 **** Oc_Application Define { -name avf2ovf ! -version 1.1.1.0 -machine conDispSh -file avf2ovf.tcl -options {-tk 0} --- 16,22 ---- Oc_Application Define { -name avf2ovf ! -version 1.1.1.1 -machine conDispSh -file avf2ovf.tcl -options {-tk 0} *************** *** 25,31 **** Oc_Application Define { -name avf2vio ! -version 1.1.1.0 -machine conDispSh -file avf2vio.tcl -options {-tk 0} --- 25,31 ---- Oc_Application Define { -name avf2vio ! -version 1.1.1.1 -machine conDispSh -file avf2vio.tcl -options {-tk 0} *************** *** 34,40 **** Oc_Application Define { -name avf2ppm ! -version 1.1.1.0 -machine conDispSh -file avf2ppm.tcl -options {-tk 0} --- 34,40 ---- Oc_Application Define { -name avf2ppm ! -version 1.1.1.1 -machine conDispSh -file avf2ppm.tcl -options {-tk 0} diff -crN oommf-1.1b0/app/mmdisp/scripts/avf2ave.tcl oommf/app/mmdisp/scripts/avf2ave.tcl *** oommf-1.1b0/app/mmdisp/scripts/avf2ave.tcl Fri Mar 17 16:11:18 2000 --- oommf/app/mmdisp/scripts/avf2ave.tcl Thu Apr 27 16:37:47 2000 *************** *** 8,14 **** catch {wm withdraw .} Oc_Main SetAppName avf2ave ! Oc_Main SetVersion 1.1.1.0 Oc_CommandLine Option console {} {} Oc_CommandLine Option [Oc_CommandLine Switch] { --- 8,14 ---- catch {wm withdraw .} Oc_Main SetAppName avf2ave ! Oc_Main SetVersion 1.1.1.1 Oc_CommandLine Option console {} {} Oc_CommandLine Option [Oc_CommandLine Switch] { diff -crN oommf-1.1b0/app/mmdisp/scripts/avf2ovf.tcl oommf/app/mmdisp/scripts/avf2ovf.tcl *** oommf-1.1b0/app/mmdisp/scripts/avf2ovf.tcl Fri Mar 17 16:11:18 2000 --- oommf/app/mmdisp/scripts/avf2ovf.tcl Thu Apr 27 16:37:47 2000 *************** *** 8,14 **** catch {wm withdraw .} Oc_Main SetAppName avf2ovf ! Oc_Main SetVersion 1.1.1.0 Oc_CommandLine Option console {} {} Oc_CommandLine Option format { --- 8,14 ---- catch {wm withdraw .} Oc_Main SetAppName avf2ovf ! Oc_Main SetVersion 1.1.1.1 Oc_CommandLine Option console {} {} Oc_CommandLine Option format { diff -crN oommf-1.1b0/app/mmdisp/scripts/avf2ppm.tcl oommf/app/mmdisp/scripts/avf2ppm.tcl *** oommf-1.1b0/app/mmdisp/scripts/avf2ppm.tcl Tue Mar 21 13:29:31 2000 --- oommf/app/mmdisp/scripts/avf2ppm.tcl Thu Apr 27 16:37:47 2000 *************** *** 8,14 **** catch {wm withdraw .} Oc_Main SetAppName avf2ppm ! Oc_Main SetVersion 1.1.1.0 Oc_CommandLine Option console {} {} --- 8,14 ---- catch {wm withdraw .} Oc_Main SetAppName avf2ppm ! Oc_Main SetVersion 1.1.1.1 Oc_CommandLine Option console {} {} diff -crN oommf-1.1b0/app/mmdisp/scripts/avf2vio.tcl oommf/app/mmdisp/scripts/avf2vio.tcl *** oommf-1.1b0/app/mmdisp/scripts/avf2vio.tcl Fri Mar 17 16:11:18 2000 --- oommf/app/mmdisp/scripts/avf2vio.tcl Thu Apr 27 16:37:47 2000 *************** *** 8,14 **** catch {wm withdraw .} Oc_Main SetAppName avf2vio ! Oc_Main SetVersion 1.1.1.0 Oc_CommandLine Option console {} {} Oc_CommandLine Option [Oc_CommandLine Switch] { --- 8,14 ---- catch {wm withdraw .} Oc_Main SetAppName avf2vio ! Oc_Main SetVersion 1.1.1.1 Oc_CommandLine Option console {} {} Oc_CommandLine Option [Oc_CommandLine Switch] { diff -crN oommf-1.1b0/app/mmdisp/scripts/mmdisp.tcl oommf/app/mmdisp/scripts/mmdisp.tcl *** oommf-1.1b0/app/mmdisp/scripts/mmdisp.tcl Thu Mar 23 19:25:33 2000 --- oommf/app/mmdisp/scripts/mmdisp.tcl Thu May 10 11:09:39 2001 *************** *** 13,20 **** ########################### PROGRAM DOCUMENTATION ################### Oc_Main SetAppName mmDisp ! Oc_Main SetVersion 1.1.1.0 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/03/24 00:25:33 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] --- 13,20 ---- ########################### PROGRAM DOCUMENTATION ################### Oc_Main SetAppName mmDisp ! Oc_Main SetVersion 1.1.1.1 ! regexp \\\044Date:(.*)\\\044 {$Date: 2001/05/10 15:09:39 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] *************** *** 1032,1047 **** } if { ![file exists $filename] } { ! OMF_InfoDialog "File $filename does not exist." \ ! "[Oc_Main GetInstanceName]:Error" warning 10c lappend errmsg "ERROR: File does not exists" } elseif { ![file isfile $filename] } { ! OMF_InfoDialog "File $filename is not an ordinary file." \ ! "[Oc_Main GetInstanceName]:Error" warning 10c lappend errmsg "ERROR: Special file" } elseif { ![file readable $filename] } { ! OMF_InfoDialog "Don't have read access to file $filename." ! "[Oc_Main GetInstanceName]:Error" warning 10c lappend errmsg "ERROR: No read access" } else { GetFrameRotation rot --- 1032,1047 ---- } if { ![file exists $filename] } { ! Ow_Dialog 0 "[Oc_Main GetInstanceName]:Error" warning \ ! "File $filename does not exist." 10c lappend errmsg "ERROR: File does not exists" } elseif { ![file isfile $filename] } { ! Ow_Dialog 0 "[Oc_Main GetInstanceName]:Error" warning \ ! "File $filename is not an ordinary file." 10c lappend errmsg "ERROR: Special file" } elseif { ![file readable $filename] } { ! Ow_Dialog "[Oc_Main GetInstanceName]:Error" warning \ ! "Don't have read access to file $filename." 10c lappend errmsg "ERROR: No read access" } else { GetFrameRotation rot *************** *** 1210,1215 **** --- 1210,1216 ---- ## but probably not worth the bother. SetScale $cfg(misc,zoom) 0 SetDataScaling $cfg(misc,datascale) 0 + set cfg(misc,datascale) $plot_config(misc,datascale) array set plot_config [array get cfg] UpdatePlotConfiguration DrawFrame $canvas *************** *** 1308,1334 **** } trace variable DisplayRotation w DisplayRotationTrace bind $ctrlbar.rotation.coords { ! set temp [expr (round($DisplayRotation/90.)+1)%%4] ! set DisplayRotation [expr $temp*90] } bind $ctrlbar.rotation.coords { # Same as ! set temp [expr (round($DisplayRotation/90.)+1)%%4] ! set DisplayRotation [expr $temp*90] } bind $ctrlbar.rotation.coords { ! set temp [expr (round($DisplayRotation/90.)-1)%%4] ! set DisplayRotation [expr $temp*90] } bind $ctrlbar.rotation.coords { # Same as ! set temp [expr (round($DisplayRotation/90.)-1)%%4] ! set DisplayRotation [expr $temp*90] } bind $ctrlbar.rotation.coords { set bw [%W cget -borderwidth] set ht [%W cget -highlightthickness] ! set size [expr %h - 2*$bw - 2*$ht] set cwidth [%W cget -width] set cheight [%W cget -height] if {$cwidth!=$size || $cheight!=$size} { --- 1309,1335 ---- } trace variable DisplayRotation w DisplayRotationTrace bind $ctrlbar.rotation.coords { ! set temp [expr {(round($DisplayRotation/90.)+1)%%4}] ! set DisplayRotation [expr {$temp*90}] } bind $ctrlbar.rotation.coords { # Same as ! set temp [expr {(round($DisplayRotation/90.)+1)%%4}] ! set DisplayRotation [expr {$temp*90}] } bind $ctrlbar.rotation.coords { ! set temp [expr {(round($DisplayRotation/90.)-1)%%4}] ! set DisplayRotation [expr {$temp*90}] } bind $ctrlbar.rotation.coords { # Same as ! set temp [expr {(round($DisplayRotation/90.)-1)%%4}] ! set DisplayRotation [expr {$temp*90}] } bind $ctrlbar.rotation.coords { set bw [%W cget -borderwidth] set ht [%W cget -highlightthickness] ! set size [expr {%h - 2*$bw - 2*$ht}] set cwidth [%W cget -width] set cheight [%W cget -height] if {$cwidth!=$size || $cheight!=$size} { *************** *** 1357,1363 **** -troughcolor [TroughColor] \ -outer_frame_options "-bd 2 -relief ridge" \ -command SetArrowSubsampling \ ! -hardmin [expr -($valmax)] -hardmax $valmax proc SetArrowSubsamplingIncrement { {incr {}} } { global arrowsswidget --- 1358,1364 ---- -troughcolor [TroughColor] \ -outer_frame_options "-bd 2 -relief ridge" \ -command SetArrowSubsampling \ ! -hardmin [expr {-1 * $valmax}] -hardmax $valmax proc SetArrowSubsamplingIncrement { {incr {}} } { global arrowsswidget *************** *** 1377,1391 **** } proc ArrowSizeCallback { widget action args } { ! global plot_config ! set x [$widget Cget -value] ! set y [OMF_MakeValidNumber $x] ! if { $x != $y } { ! # Illegal input string ! $widget Set $plot_config(arrow,size) ! } else { ! SetArrowSize $x ! } } Ow_EntryBox New arrowsizewidget $ctrlbar -label "Size:" \ --- 1378,1385 ---- } proc ArrowSizeCallback { widget action args } { ! if {[string compare $action UPDATE]} {return} ! SetArrowSize [lindex $args 1] } Ow_EntryBox New arrowsizewidget $ctrlbar -label "Size:" \ *************** *** 1400,1414 **** # Data value scaling proc SetDataScaling { newscale {redraw 1}} { global plot_config canvas ! if {$newscale<=0} { # Illegal value; Reset to default set newscale $plot_config(misc,default_datascale) } set config [Oc_Config RunPlatform] set valmin [expr \ ! sqrt([$config GetValue compiletime_dbl_min])] if {$newscale<$valmin} { set newscale $valmin } ;# Safety ! set valmax [expr [$config GetValue compiletime_dbl_max]/4.0] if {$newscale>$valmax} { set newscale $valmax } ;# Safety if {$newscale!=$plot_config(misc,datascale)} { set tempscale [SetDataValueScaling $newscale] --- 1394,1408 ---- # Data value scaling proc SetDataScaling { newscale {redraw 1}} { global plot_config canvas ! if {[string match {} $newscale] || $newscale<=0} { # Illegal value; Reset to default set newscale $plot_config(misc,default_datascale) } set config [Oc_Config RunPlatform] set valmin [expr \ ! {sqrt([$config GetValue compiletime_dbl_min])}] if {$newscale<$valmin} { set newscale $valmin } ;# Safety ! set valmax [expr {[$config GetValue compiletime_dbl_max]/4.0}] if {$newscale>$valmax} { set newscale $valmax } ;# Safety if {$newscale!=$plot_config(misc,datascale)} { set tempscale [SetDataValueScaling $newscale] *************** *** 1425,1432 **** } set plot_config(misc,datascale) [GetDataValueScaling] ! set minval [expr pow(10,round(log10($plot_config(misc,datascale)))-1)] ! set maxval [expr $minval*100] set plot_config(misc,dataunits) [GetDataValueUnit] set tunits $plot_config(misc,dataunits) set tlabel "Data Scale" --- 1419,1426 ---- } set plot_config(misc,datascale) [GetDataValueScaling] ! set minval [expr {pow(10,round(log10($plot_config(misc,datascale)))-1)}] ! set maxval [expr {$minval*100}] set plot_config(misc,dataunits) [GetDataValueUnit] set tunits $plot_config(misc,dataunits) set tlabel "Data Scale" *************** *** 1435,1441 **** } append tlabel ":" Ow_EntryScale New datascalewidget $ctrlbar.datascale \ ! -label $tlabel" \ -variable plot_config(misc,datascale) -valuewidth 8 \ -scalewidth 50 -rangemin $minval -rangemax $maxval \ -scalestep 0.01 -displayfmt "%.3g" \ --- 1429,1435 ---- } append tlabel ":" Ow_EntryScale New datascalewidget $ctrlbar.datascale \ ! -label $tlabel \ -variable plot_config(misc,datascale) -valuewidth 8 \ -scalewidth 50 -rangemin $minval -rangemax $maxval \ -scalestep 0.01 -displayfmt "%.3g" \ *************** *** 1444,1450 **** -marklist $plot_config(misc,default_datascale) -markwidth 2 \ -command SetDataScaling \ -hardmax [expr \ ! [[Oc_Config RunPlatform] GetValue compiletime_dbl_max]/4.0] # Zoom (formerly known as FrameScale) Ow_EntryScale New zoomwidget $ctrlbar.zoom -label "Zoom:" \ --- 1438,1444 ---- -marklist $plot_config(misc,default_datascale) -markwidth 2 \ -command SetDataScaling \ -hardmax [expr \ ! {[[Oc_Config RunPlatform] GetValue compiletime_dbl_max]/4.0}] # Zoom (formerly known as FrameScale) Ow_EntryScale New zoomwidget $ctrlbar.zoom -label "Zoom:" \ *************** *** 1492,1500 **** $viewmenu add command -label "Fill Display" -command { FillDisplay } \ -underline 0 $viewmenu add command -label "Rotate ccw" -underline 0 \ ! -command {set DisplayRotation [expr round($DisplayRotation+90)%360]} $viewmenu add command -label "Rotate cw" -underline 7 \ ! -command {set DisplayRotation [expr round($DisplayRotation-90)%360]} $viewmenu add command -label "reDraw" -underline 2 -command { RedrawDisplay } $optionmenu add command -label "Configure..." -underline 0 \ --- 1486,1494 ---- $viewmenu add command -label "Fill Display" -command { FillDisplay } \ -underline 0 $viewmenu add command -label "Rotate ccw" -underline 0 \ ! -command {set DisplayRotation [expr {round($DisplayRotation+90)%360}]} $viewmenu add command -label "Rotate cw" -underline 7 \ ! -command {set DisplayRotation [expr {round($DisplayRotation-90)%360}]} $viewmenu add command -label "reDraw" -underline 2 -command { RedrawDisplay } $optionmenu add command -label "Configure..." -underline 0 \ *************** *** 1531,1546 **** bind $cf { OMF_RecoverDisplayState } bind $cf { Zoom $SmallZoom } bind $cf { Zoom $LargeZoom } ! bind $cf { Zoom [expr 1./$SmallZoom] } ! bind $cf { Zoom [expr 1./$LargeZoom] } ## NOTE: SunOS apparently doesn't have Page_Up & Page_Down. For the ## record, Prior == Page_Up, and Next == Page_Down. # Ditto for KeyPad; Note that the keypad values are funky, # and might be wrong for some keyboards. catch {bind $cf { Zoom $SmallZoom }} catch {bind $cf { Zoom $LargeZoom }} ! catch {bind $cf { Zoom [expr 1./$SmallZoom] }} ! catch {bind $cf { Zoom [expr 1./$LargeZoom] }} bind $cf { FillDisplay } bind $cf { WrapDisplay } --- 1525,1540 ---- bind $cf { OMF_RecoverDisplayState } bind $cf { Zoom $SmallZoom } bind $cf { Zoom $LargeZoom } ! bind $cf { Zoom [expr {1./$SmallZoom}] } ! bind $cf { Zoom [expr {1./$LargeZoom}] } ## NOTE: SunOS apparently doesn't have Page_Up & Page_Down. For the ## record, Prior == Page_Up, and Next == Page_Down. # Ditto for KeyPad; Note that the keypad values are funky, # and might be wrong for some keyboards. catch {bind $cf { Zoom $SmallZoom }} catch {bind $cf { Zoom $LargeZoom }} ! catch {bind $cf { Zoom [expr {1./$SmallZoom}] }} ! catch {bind $cf { Zoom [expr {1./$LargeZoom}] }} bind $cf { FillDisplay } bind $cf { WrapDisplay } *************** *** 1553,1595 **** ## Note: The last two depend upon the text in the pull down menus! bind $cf { ;# Ctrl-r ! set DisplayRotation [expr round($DisplayRotation+90)%%360] } bind $cf { ;# Shift-Ctrl-R ! set DisplayRotation [expr round($DisplayRotation-90)%%360] } bind $cf { ;# Ctrl-c ! set DisplayRotation [expr round($DisplayRotation-90)%%360] } bind $cf { ! set newrate [expr $plot_config(arrow,subsample)-1] if {$newrate<0} {set newrate 0} SetArrowSubsampling $newrate } bind $cf { ! SetArrowSubsampling [expr $plot_config(arrow,subsample)+1] } bind $cf { ! SetArrowSubsampling [expr $plot_config(arrow,subsample)/2.] } bind $cf { ! SetArrowSubsampling [expr $plot_config(arrow,subsample)*2] } # Ditto for KeyPad; Note that the keypad values are funky, # and might be wrong for some keyboards. catch { bind $cf { ! set newrate [expr $plot_config(arrow,subsample)-1] if {$newrate<0} {set newrate 0} SetArrowSubsampling $newrate } } catch {bind $cf { ! SetArrowSubsampling [expr $plot_config(arrow,subsample)+1] } } catch {bind $cf { ! SetArrowSubsampling [expr $plot_config(arrow,subsample)/2.] } } catch {bind $cf { ! SetArrowSubsampling [expr $plot_config(arrow,subsample)*2] } } # Proc to scroll canvas from keyboard. direction should be one of --- 1547,1589 ---- ## Note: The last two depend upon the text in the pull down menus! bind $cf { ;# Ctrl-r ! set DisplayRotation [expr {round($DisplayRotation+90)%%360}] } bind $cf { ;# Shift-Ctrl-R ! set DisplayRotation [expr {round($DisplayRotation-90)%%360}] } bind $cf { ;# Ctrl-c ! set DisplayRotation [expr {round($DisplayRotation-90)%%360}] } bind $cf { ! set newrate [expr {$plot_config(arrow,subsample)-1}] if {$newrate<0} {set newrate 0} SetArrowSubsampling $newrate } bind $cf { ! SetArrowSubsampling [expr {$plot_config(arrow,subsample)+1}] } bind $cf { ! SetArrowSubsampling [expr {$plot_config(arrow,subsample)/2.}] } bind $cf { ! SetArrowSubsampling [expr {$plot_config(arrow,subsample)*2}] } # Ditto for KeyPad; Note that the keypad values are funky, # and might be wrong for some keyboards. catch { bind $cf { ! set newrate [expr {$plot_config(arrow,subsample)-1}] if {$newrate<0} {set newrate 0} SetArrowSubsampling $newrate } } catch {bind $cf { ! SetArrowSubsampling [expr {$plot_config(arrow,subsample)+1}] } } catch {bind $cf { ! SetArrowSubsampling [expr {$plot_config(arrow,subsample)/2.}] } } catch {bind $cf { ! SetArrowSubsampling [expr {$plot_config(arrow,subsample)*2}] } } # Proc to scroll canvas from keyboard. direction should be one of *************** *** 1788,1794 **** if {$omfZoomDirection>=0} { set offset $arrlength } \ else { set offset -$arrlength } set arrheadsize [expr {round($arrlength/2)}] ! set arrheadshape "$arrheadsize $arrheadsize [expr $arrheadsize/2]" if { $ylimit < $xlimit + $xfudge} { # Draw arrows on top & bottom sides $canvas create line \ --- 1782,1788 ---- if {$omfZoomDirection>=0} { set offset $arrlength } \ else { set offset -$arrlength } set arrheadsize [expr {round($arrlength/2)}] ! set arrheadshape "$arrheadsize $arrheadsize [expr {$arrheadsize/2}]" if { $ylimit < $xlimit + $xfudge} { # Draw arrows on top & bottom sides $canvas create line \ *************** *** 1820,1827 **** } if {$omfZoomDirection<0} { set scale [expr {1./double($scale)}]} global omfStdNumericFormat ! set newsize [OMF_FormatNumber \ ! [expr {$plot_config(misc,zoom)*$scale}]] $zoomwidget SetEdit $newsize } } --- 1814,1820 ---- } if {$omfZoomDirection<0} { set scale [expr {1./double($scale)}]} global omfStdNumericFormat ! set newsize [format "%4.2f" [expr {$plot_config(misc,zoom)*$scale}]] $zoomwidget SetEdit $newsize } } *************** *** 1998,2005 **** # Bind canvas resize proc bind $canvas_frame { ! set border [expr 2*[%W cget -borderwidth]+2*[%W cget -highlightthickness]] ! ResizeViewport [expr %w-$border] [expr %h-$border] # Note: The resize request *includes* both -borderwidth # & -highlightthickness! } --- 1991,1998 ---- # Bind canvas resize proc bind $canvas_frame { ! set border [expr {2*[%W cget -borderwidth]+2*[%W cget -highlightthickness]}] ! ResizeViewport [expr {%w-$border}] [expr {%h-$border}] # Note: The resize request *includes* both -borderwidth # & -highlightthickness! } diff -crN oommf-1.1b0/app/mmgraph/appindex.tcl oommf/app/mmgraph/appindex.tcl *** oommf-1.1b0/app/mmgraph/appindex.tcl Fri Feb 18 11:36:21 2000 --- oommf/app/mmgraph/appindex.tcl Thu Apr 27 16:37:48 2000 *************** *** 1,7 **** Oc_Application Define { -name mmGraph ! -version 1.1.1.0 -machine omfsh -file mmgraph.tcl } --- 1,7 ---- Oc_Application Define { -name mmGraph ! -version 1.1.1.1 -machine omfsh -file mmgraph.tcl } diff -crN oommf-1.1b0/app/mmgraph/mmgraph.tcl oommf/app/mmgraph/mmgraph.tcl *** oommf-1.1b0/app/mmgraph/mmgraph.tcl Thu Mar 23 19:25:33 2000 --- oommf/app/mmgraph/mmgraph.tcl Thu Apr 27 16:37:48 2000 *************** *** 69,76 **** wm withdraw . Oc_Main SetAppName mmGraph ! Oc_Main SetVersion 1.1.1.0 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/03/24 00:25:33 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] --- 69,76 ---- wm withdraw . Oc_Main SetAppName mmGraph ! Oc_Main SetVersion 1.1.1.1 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/04/27 20:37:48 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] diff -crN oommf-1.1b0/app/mmhelp/appindex.tcl oommf/app/mmhelp/appindex.tcl *** oommf-1.1b0/app/mmhelp/appindex.tcl Fri Feb 18 12:58:29 2000 --- oommf/app/mmhelp/appindex.tcl Thu Apr 27 16:37:48 2000 *************** *** 1,7 **** Oc_Application Define { -name mmHelp ! -version 1.1.1.0 -machine omfsh -file mmhelp.tcl } --- 1,7 ---- Oc_Application Define { -name mmHelp ! -version 1.1.1.1 -machine omfsh -file mmhelp.tcl } diff -crN oommf-1.1b0/app/mmhelp/mmhelp.tcl oommf/app/mmhelp/mmhelp.tcl *** oommf-1.1b0/app/mmhelp/mmhelp.tcl Thu Mar 9 15:48:36 2000 --- oommf/app/mmhelp/mmhelp.tcl Wed Jun 13 12:51:19 2001 *************** *** 16,22 **** # v--Edit here if necessary \ exec wish "$0" ${1+"$@"} # ! # Last modified on: $Date: 2000/03/09 20:48:36 $ # Last modified by: $Author: dgp $ # # Usage: omfsh mmhelp.tcl --- 16,22 ---- # v--Edit here if necessary \ exec wish "$0" ${1+"$@"} # ! # Last modified on: $Date: 2001/06/13 16:51:19 $ # Last modified by: $Author: dgp $ # # Usage: omfsh mmhelp.tcl *************** *** 160,165 **** --- 160,166 ---- ######################################################################## package require Tk catch {package require Ow} + catch {package require Img} ;# Can support more image formats with this wm withdraw . # Define standard global variables *************** *** 172,179 **** source [file join [file dirname [info script]] counter.tcl] Oc_Main SetAppName mmHelp ! Oc_Main SetVersion 1.1.1.0 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/03/09 20:48:36 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] --- 173,180 ---- source [file join [file dirname [info script]] counter.tcl] Oc_Main SetAppName mmHelp ! Oc_Main SetVersion 1.1.1.1 ! regexp \\\044Date:(.*)\\\044 {$Date: 2001/06/13 16:51:19 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] *************** *** 258,263 **** --- 259,265 ---- .gif image/gif .jpg image/jpeg .jpeg image/jpeg .jpe image/jpeg .tif image/tiff .tiff image/tiff + .png image/png .pnm image/x-portable-anymap .pbm image/x-portable-bitmap .pgm image/x-portable-graymap .ppm image/x-portable-pixmap .xbm image/x-xbitmap .xpm image/x-xpixmap *************** *** 1897,1903 **** set idx [$_omfhb_g(fmenu$textwidget) index Refresh] $_omfhb_g(fmenu$textwidget) entryconfigure $idx -state disabled $textwidget tag configure link -foreground black -underline 0 ! # if {[string compare $targetURL $currentURL]} { array set contentinfo [_OMFHB_FetchUrl $targetURL contents] if {[string length [info commands \ _OMFHB_Display_$contentinfo(type)_$contentinfo(subtype)]]} { --- 1899,1906 ---- set idx [$_omfhb_g(fmenu$textwidget) index Refresh] $_omfhb_g(fmenu$textwidget) entryconfigure $idx -state disabled $textwidget tag configure link -foreground black -underline 0 ! if {[string compare $targetURL $currentURL] ! || [string match _OMFHB_Refresh [lindex [info level -1] 0] ] } { array set contentinfo [_OMFHB_FetchUrl $targetURL contents] if {[string length [info commands \ _OMFHB_Display_$contentinfo(type)_$contentinfo(subtype)]]} { *************** *** 1907,1913 **** _OMFHB_DisplayUnknownContentType $targetURL $contentinfo(type) \ $contentinfo(subtype) $textwidget } ! # } if {[regexp . $targetFragment]} { # Use catch in case the named anchor doesn't exist if {[catch {$textwidget see [lindex [$textwidget tag ranges \ --- 1910,1916 ---- _OMFHB_DisplayUnknownContentType $targetURL $contentinfo(type) \ $contentinfo(subtype) $textwidget } ! } if {[regexp . $targetFragment]} { # Use catch in case the named anchor doesn't exist if {[catch {$textwidget see [lindex [$textwidget tag ranges \ diff -crN oommf-1.1b0/app/mmlaunch/appindex.tcl oommf/app/mmlaunch/appindex.tcl *** oommf-1.1b0/app/mmlaunch/appindex.tcl Fri Feb 18 11:29:21 2000 --- oommf/app/mmlaunch/appindex.tcl Thu Apr 27 16:37:48 2000 *************** *** 1,7 **** Oc_Application Define { -name mmLaunch ! -version 1.1.1.0 -machine omfsh -file mmlaunch.tcl } --- 1,7 ---- Oc_Application Define { -name mmLaunch ! -version 1.1.1.1 -machine omfsh -file mmlaunch.tcl } diff -crN oommf-1.1b0/app/mmlaunch/mmlaunch.tcl oommf/app/mmlaunch/mmlaunch.tcl *** oommf-1.1b0/app/mmlaunch/mmlaunch.tcl Thu Mar 9 15:35:55 2000 --- oommf/app/mmlaunch/mmlaunch.tcl Thu Apr 27 16:37:48 2000 *************** *** 3,9 **** # An application which presents an interface for launching and # interconnecting other OOMMF applications. # ! # Last modified on: $Date: 2000/03/09 20:35:55 $ # Last modified by: $Author: dgp $ # Support libraries --- 3,9 ---- # An application which presents an interface for launching and # interconnecting other OOMMF applications. # ! # Last modified on: $Date: 2000/04/27 20:37:48 $ # Last modified by: $Author: dgp $ # Support libraries *************** *** 16,23 **** wm withdraw . Oc_Main SetAppName mmLaunch ! Oc_Main SetVersion 1.1.1.0 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/03/09 20:35:55 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] --- 16,23 ---- wm withdraw . Oc_Main SetAppName mmLaunch ! Oc_Main SetVersion 1.1.1.1 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/04/27 20:37:48 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] diff -crN oommf-1.1b0/app/mmpe/appindex.tcl oommf/app/mmpe/appindex.tcl *** oommf-1.1b0/app/mmpe/appindex.tcl Fri Feb 18 11:47:57 2000 --- oommf/app/mmpe/appindex.tcl Thu Apr 27 16:37:48 2000 *************** *** 2,15 **** Oc_Application Define { -name mmProbEd -aliases mmpe ! -version 1.1.1.0 -machine omfsh -file mmpe.tcl } Oc_Application Define { -name FileSource ! -version 1.1.1.0 -machine omfsh -file filesource.tcl } --- 2,15 ---- Oc_Application Define { -name mmProbEd -aliases mmpe ! -version 1.1.1.1 -machine omfsh -file mmpe.tcl } Oc_Application Define { -name FileSource ! -version 1.1.1.1 -machine omfsh -file filesource.tcl } diff -crN oommf-1.1b0/app/mmpe/examples/oommf-small.mif oommf/app/mmpe/examples/oommf-small.mif *** oommf-1.1b0/app/mmpe/examples/oommf-small.mif Fri Feb 11 15:17:50 2000 --- oommf/app/mmpe/examples/oommf-small.mif Wed Aug 9 23:01:32 2000 *************** *** 8,14 **** demag type:constmag part height:580E-9 part width:1440E-9 - base material type:Permalloy part thickness:100e-9 part shape:mask app/mmpe/examples/oommf-small.bmp cell size:20.0e-9 --- 8,13 ---- *************** *** 20,26 **** user report code:30 converge mxh value:.0001 randomizer seed:1 - max iteration count:-1 field range: 0. 0.0 0 0.05 0.001 0 25 field range: 0.05 0.001 0 -0.05 -0.001 0 50 field range: -0.05 -0.001 0.0 0.05 0.001 0 50 --- 19,24 ---- diff -crN oommf-1.1b0/app/mmpe/filesource.tcl oommf/app/mmpe/filesource.tcl *** oommf-1.1b0/app/mmpe/filesource.tcl Thu Mar 9 12:45:53 2000 --- oommf/app/mmpe/filesource.tcl Thu Apr 27 16:37:48 2000 *************** *** 7,14 **** wm withdraw . Oc_Main SetAppName FileSource ! Oc_Main SetVersion 1.1.1.0 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/03/09 17:45:53 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] --- 7,14 ---- wm withdraw . Oc_Main SetAppName FileSource ! Oc_Main SetVersion 1.1.1.1 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/04/27 20:37:48 $} _ date Oc_Main SetDate [string trim $date] # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] diff -crN oommf-1.1b0/app/mmpe/mmpe.tcl oommf/app/mmpe/mmpe.tcl *** oommf-1.1b0/app/mmpe/mmpe.tcl Thu Mar 23 19:25:33 2000 --- oommf/app/mmpe/mmpe.tcl Fri Jun 9 18:33:22 2000 *************** *** 12,21 **** wm withdraw . Oc_Main SetAppName mmProbEd ! Oc_Main SetVersion 1.1.1.0 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/03/24 00:25:33 $} _ date Oc_Main SetDate [string trim $date] ! # regexp \\\044Author:(.*)\\\044 {$Author: dgp $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] Oc_Main SetAuthor [Oc_Person Lookup jeicke] Oc_Main SetHelpURL [Oc_Url FromFilename [file join [file dirname \ --- 12,21 ---- wm withdraw . Oc_Main SetAppName mmProbEd ! Oc_Main SetVersion 1.1.1.1 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/06/09 22:33:22 $} _ date Oc_Main SetDate [string trim $date] ! # regexp \\\044Author:(.*)\\\044 {$Author: donahue $} _ author # Oc_Main SetAuthor [Oc_Person Lookup [string trim $author]] Oc_Main SetAuthor [Oc_Person Lookup jeicke] Oc_Main SetHelpURL [Oc_Url FromFilename [file join [file dirname \ *************** *** 37,43 **** set file1Id [open $filename "r"] set data [read -nonewline $file1Id] regsub -all "\\\\\n\[ \t\r\n]*" $data " " data ! set inbuff [split $data \n] close $file1Id } else { Oc_Log Log "Empty file or file not readable" warning --- 37,43 ---- set file1Id [open $filename "r"] set data [read -nonewline $file1Id] regsub -all "\\\\\n\[ \t\r\n]*" $data " " data ! set inbuff [split $data "\n"] close $file1Id } else { Oc_Log Log "Empty file or file not readable" warning *************** *** 48,70 **** #*************************************************************************# proc ChangeMif { Ref NewValue } { global MifKnow ! set temp [lindex $MifKnow($Ref) 0] ! #puts $temp ! if { $temp != "1" } { ! set MifKnow($Ref) [concat [lrange $MifKnow($Ref) 0 0] $NewValue] ! } else { ! lappend MifKnow($Ref) $NewValue ! } ! #puts $MifKnow($Ref) ! #puts $NewValue ! #puts $MifKnow($Ref) } #*************************************************************************# #set up an array that contains the entries of a MifFile #What is needed in a mif file is stored in state.dat proc KnowWhat {filename} { ! global inbuff MifKnow KnowOrder set listsize [ReadFile $filename] for {set i 0} {$i<$listsize} {incr i} { set shortbuff [lindex $inbuff $i] #puts $shortbuff --- 48,63 ---- #*************************************************************************# proc ChangeMif { Ref NewValue } { global MifKnow ! set MifKnow($Ref) \ ! [lreplace $NewValue 0 -1 [lindex $MifKnow($Ref) 0]] } #*************************************************************************# #set up an array that contains the entries of a MifFile #What is needed in a mif file is stored in state.dat proc KnowWhat {filename} { ! global inbuff MifKnow KnowOrder MifUnknown set listsize [ReadFile $filename] + catch {unset MifKnow} ;# Force wipe out of any old data for {set i 0} {$i<$listsize} {incr i} { set shortbuff [lindex $inbuff $i] #puts $shortbuff *************** *** 72,83 **** set MifKnow([lindex $shortbuff 0]) [lindex $shortbuff 1] set KnowOrder([expr {$i+1}]) [lindex $shortbuff 0] } } #Reads and understands the mif file (must run KnowWhat first) #(needs ReadFile) puts result in array MifKnow #*************************************************************************# proc ParseFile {filename} { ! global inbuff MifKnow FieldState set listsize [ReadFile $filename] set firstbuff vals set FieldCount 0 --- 65,77 ---- set MifKnow([lindex $shortbuff 0]) [lindex $shortbuff 1] set KnowOrder([expr {$i+1}]) [lindex $shortbuff 0] } + catch {unset MifUnknown} ;# Wipe out any old unknown data } #Reads and understands the mif file (must run KnowWhat first) #(needs ReadFile) puts result in array MifKnow #*************************************************************************# proc ParseFile {filename} { ! global inbuff MifKnow FieldState MifUnknown set listsize [ReadFile $filename] set firstbuff vals set FieldCount 0 *************** *** 104,111 **** #puts "$FieldState($FieldCount) $FieldCount" } ChangeMif $prefix $suffix ! } } } ! ChangeMif "field range count" $FieldCount } #*************************************************************************# --- 98,109 ---- #puts "$FieldState($FieldCount) $FieldCount" } ChangeMif $prefix $suffix ! } else { ! lappend MifUnknown $prefix $suffix ! } ! } ! } ! ChangeMif "field range count" $FieldCount } #*************************************************************************# *************** *** 698,711 **** } #*************************************************************************# proc SaveMifFile {savefilename} { ! global MifKnow FieldState KnowOrder set file2Id [open $savefilename "w"] puts $file2Id "# MIF 1.1" for {set one 1} {$one<[array size KnowOrder]} {incr one} { set index $KnowOrder($one) set flipped $MifKnow($index) set vals [lindex $flipped 1] ! if {$vals!="" && $index!="field range"&&$index!="material name"&&$index!="field range count"} { puts $file2Id "$index:[join [lrange $flipped 1 end] ]" #puts "l32:$index:[lrange $flipped 1 end]" } elseif {$index=="material name"&&$vals!=""} { --- 696,710 ---- } #*************************************************************************# proc SaveMifFile {savefilename} { ! global MifKnow FieldState KnowOrder MifUnknown set file2Id [open $savefilename "w"] puts $file2Id "# MIF 1.1" for {set one 1} {$one<[array size KnowOrder]} {incr one} { set index $KnowOrder($one) set flipped $MifKnow($index) set vals [lindex $flipped 1] ! if {$vals!="" && $index!="field range" \ ! && $index!="material name" && $index!="field range count"} { puts $file2Id "$index:[join [lrange $flipped 1 end] ]" #puts "l32:$index:[lrange $flipped 1 end]" } elseif {$index=="material name"&&$vals!=""} { *************** *** 721,726 **** --- 720,732 ---- } } } + # Dump unrecognized entries + if {[info exists MifUnknown] && [llength $MifUnknown]>0} { + puts $file2Id "\n# Input file entries unrecognized by mmProbEd ---" + foreach {name value} $MifUnknown { + puts $file2Id "$name : $value" + } + } close $file2Id } #**************************************************************************# *************** *** 765,771 **** $btn entryconfigure $item -state disabled } proc LoadCallback { widget actionid args } { ! global resetfilepath if {[string match DELETE $actionid]} { eval [join $args] return --- 771,777 ---- $btn entryconfigure $item -state disabled } proc LoadCallback { widget actionid args } { ! global resetfilepath initfilepath if {[string match DELETE $actionid]} { eval [join $args] return *************** *** 799,809 **** $menuname add separator $menuname add command -label Exit -command {Die .} -underline 1 Ow_StdHelpMenu $helpmenu ! global resetfilepath ! KnowWhat [file join [file dirname [info script]] state.dat] set resetfilepath [file join [file dirname [info script]] state.dat] ! #puts $resetfilepath ! ParseFile [file join [file dirname [info script]] init.mif] global TopButton set listsize [ReadFile [file join [file dirname [info script]] topmenu]] for {set i 0} {$i<$listsize} {incr i} { --- 805,815 ---- $menuname add separator $menuname add command -label Exit -command {Die .} -underline 1 Ow_StdHelpMenu $helpmenu ! global resetfilepath initfilepath set resetfilepath [file join [file dirname [info script]] state.dat] ! set initfilepath [file join [file dirname [info script]] init.mif] ! KnowWhat $resetfilepath ! ParseFile $initfilepath global TopButton set listsize [ReadFile [file join [file dirname [info script]] topmenu]] for {set i 0} {$i<$listsize} {incr i} { diff -crN oommf-1.1b0/app/mmsolve/any2ppm.tcl oommf/app/mmsolve/any2ppm.tcl *** oommf-1.1b0/app/mmsolve/any2ppm.tcl Sun Mar 26 22:23:22 2000 --- oommf/app/mmsolve/any2ppm.tcl Wed May 9 19:26:12 2001 *************** *** 11,17 **** Oc_ForceNoTkDefaultMessage Oc_Main SetAppName any2ppm ! Oc_Main SetVersion 1.1.1.0 Oc_CommandLine Option console {} {} --- 11,17 ---- Oc_ForceNoTkDefaultMessage Oc_Main SetAppName any2ppm ! Oc_Main SetVersion 1.1.1.1 Oc_CommandLine Option console {} {} *************** *** 73,80 **** {} {#do nothing} {-} {set outchan stdout} default { ! if {[catch {open $outname "w"} msg]} { ! puts stderr "Unable to open output file $outname: $msg" incr errcount } else { set outchan $msg --- 73,80 ---- {} {#do nothing} {-} {set outchan stdout} default { ! if {[catch {open $outSpec "w"} msg]} { ! puts stderr "Unable to open output file $outSpec: $msg" incr errcount } else { set outchan $msg diff -crN oommf-1.1b0/app/mmsolve/appindex.tcl oommf/app/mmsolve/appindex.tcl *** oommf-1.1b0/app/mmsolve/appindex.tcl Tue Feb 29 18:11:03 2000 --- oommf/app/mmsolve/appindex.tcl Sat Sep 29 14:24:58 2001 *************** *** 1,9 **** Oc_Application Define { -name any2ppm ! -version 1.1.1.0 -machine filtersh -file any2ppm.tcl -mode fg } --- 1,17 ---- Oc_Application Define { -name any2ppm ! -version 1.1.1.1 -machine filtersh -file any2ppm.tcl + -mode fg + } + + Oc_Application Define { + -name odtcols + -version 1.1.1.1 + -machine tclsh + -file odtcols.tcl -mode fg } diff -crN oommf-1.1b0/app/mmsolve/filelogger.tcl oommf/app/mmsolve/filelogger.tcl *** oommf-1.1b0/app/mmsolve/filelogger.tcl Thu Jun 3 18:56:32 1999 --- oommf/app/mmsolve/filelogger.tcl Wed Jun 7 17:07:20 2000 *************** *** 3,24 **** common filename "" proc Log {msg type src} { catch { ! puts stderr "[Oc_Main GetInstanceName] $src $type: $msg" ! fflush stderr ! } ! if {[string match "" $filename]} {return} ! if {[catch {open $filename a} chanid]} { ! puts stderr "Error in FileReport: unable to\ ! open error log file $filename: $chanid" ! } else { ! set instanceinfo [Oc_Main GetInstanceName] ! set iipid [lindex $instanceinfo 0] ! set iiname [lrange $instanceinfo 1 end] ! catch { puts $chanid "\[$iipid [clock format [clock seconds]\ ! -format %H:%M:%S\ %Y-%m-%d]\] $$iiname $src $type: $msg" } ! close $chanid ! } } proc SetFile {name} { --- 3,27 ---- common filename "" proc Log {msg type src} { + catch { + # Use default message reporter as well + Oc_DefaultMessage $msg $type $src + } + if {[string match "" $filename]} {return} + if {[catch {open $filename a} chanid]} { + puts stderr "Error in FileReport: unable to\ + open error log file $filename: $chanid" + } else { + set instanceinfo [Oc_Main GetInstanceName] + set iipid [lindex $instanceinfo 0] + set iiname [lrange $instanceinfo 1 end] catch { ! puts $chanid "\[$iipid [clock format [clock seconds]\ ! -format %H:%M:%S\ %Y-%m-%d]\] $$iiname $src $type:\ ! $msg" ! } ! close $chanid ! } } proc SetFile {name} { diff -crN oommf-1.1b0/app/mmsolve/grid.cc oommf/app/mmsolve/grid.cc *** oommf-1.1b0/app/mmsolve/grid.cc Tue Apr 4 16:09:19 2000 --- oommf/app/mmsolve/grid.cc Wed Apr 26 16:54:52 2000 *************** *** 745,751 **** (*InitM)(Nx,Nz,m,&(MagInitArgs.argv[1])); for(int i=0;i0) { outstr.Append("Magnetization Output Format: "); ! ospec_argv[0]=ab(OutMagFormat.GetStr()); ! ospec_cptr=Tcl_Merge(1,ospec_argv); // Protect spaces ! if(ospec_cptr!=NULL) { ! outstr.Append(ospec_cptr); ! Tcl_Free((char *)ospec_cptr); ! } outstr.Append("\n"); } if(OutTotalFieldFormat.Length()>0) { outstr.Append("Total Field Output Format: "); ! ospec_argv[0]=ab(OutTotalFieldFormat.GetStr()); ! ospec_cptr=Tcl_Merge(1,ospec_argv); // Protect spaces ! if(ospec_cptr!=NULL) { ! outstr.Append(ospec_cptr); ! Tcl_Free((char *)ospec_cptr); ! } outstr.Append("\n"); } if(OutDataTableFormat.Length()>0) { --- 1081,1092 ---- outstr.Append("\n"); if(OutMagFormat.Length()>0) { outstr.Append("Magnetization Output Format: "); ! outstr.Append(OutMagFormat); outstr.Append("\n"); } if(OutTotalFieldFormat.Length()>0) { outstr.Append("Total Field Output Format: "); ! outstr.Append(OutTotalFieldFormat); outstr.Append("\n"); } if(OutDataTableFormat.Length()>0) { diff -crN oommf-1.1b0/app/mmsolve/mms.tcl oommf/app/mmsolve/mms.tcl *** oommf-1.1b0/app/mmsolve/mms.tcl Fri Feb 18 12:18:35 2000 --- oommf/app/mmsolve/mms.tcl Mon May 15 16:10:27 2000 *************** *** 2,14 **** # # Master Tcl file for the mmsolve shell # ! # Last modified on: $Date: 2000/02/18 17:18:35 $ # Last modified by: $Author: dgp $ Oc_CheckTclIndex mmSolve # NOTE: version number below must match that in ./mmsolve.h ! package require -exact Mms 1.1.1.0 # Set up for autoloading of Oc extension commands set mms(library) [file dirname [info script]] --- 2,14 ---- # # Master Tcl file for the mmsolve shell # ! # Last modified on: $Date: 2000/05/15 20:10:27 $ # Last modified by: $Author: dgp $ Oc_CheckTclIndex mmSolve # NOTE: version number below must match that in ./mmsolve.h ! package require -exact Mms 1.1.1.1 # Set up for autoloading of Oc extension commands set mms(library) [file dirname [info script]] *************** *** 19,24 **** # Load in any local modifications set local [file join [file dirname [info script]] local mms.tcl] if {[file isfile $local] && [file readable $local]} { ! uplevel #0 source [list $local] } --- 19,24 ---- # Load in any local modifications set local [file join [file dirname [info script]] local mms.tcl] if {[file isfile $local] && [file readable $local]} { ! uplevel #0 [list source $local] } diff -crN oommf-1.1b0/app/mmsolve/mmsinit.cc oommf/app/mmsolve/mmsinit.cc *** oommf-1.1b0/app/mmsolve/mmsinit.cc Mon Feb 28 20:18:53 2000 --- oommf/app/mmsolve/mmsinit.cc Thu Jun 8 19:24:19 2000 *************** *** 237,246 **** MessageLocker::Reset(); \ return TCL_ERROR; \ } else if(errorcode<0) { \ ! /* Warning message detected. Should write to some sort of */ \ ! /* log channel, but for now just pitch into bit bucket. */ \ ! MessageLocker::Reset(); \ ! return TCL_OK; \ } \ return TCL_OK; \ } \ --- 237,248 ---- MessageLocker::Reset(); \ return TCL_ERROR; \ } else if(errorcode<0) { \ ! /* Warning message detected. Use PlainWarning() to report. */ \ ! Nb_DString errmsg; \ ! MessageLocker::GetMessage(errmsg); \ ! PlainWarning(errmsg.GetStr()); \ ! MessageLocker::Reset(); \ ! return TCL_OK; \ } \ return TCL_OK; \ } \ diff -crN oommf-1.1b0/app/mmsolve/mmsolve.h oommf/app/mmsolve/mmsolve.h *** oommf-1.1b0/app/mmsolve/mmsolve.h Wed Mar 15 18:47:16 2000 --- oommf/app/mmsolve/mmsolve.h Thu Apr 27 16:37:48 2000 *************** *** 26,32 **** #define MMSOLVE_MAJOR_VERSION 1 #define MMSOLVE_MINOR_VERSION 1 #define MMSOLVE_RELEASE_LEVEL 1 ! #define MMSOLVE_RELEASE_SERIAL 0 #define MMSOLVE_VERSION OC_MAKE_VERSION(MMSOLVE) --- 26,32 ---- #define MMSOLVE_MAJOR_VERSION 1 #define MMSOLVE_MINOR_VERSION 1 #define MMSOLVE_RELEASE_LEVEL 1 ! #define MMSOLVE_RELEASE_SERIAL 1 #define MMSOLVE_VERSION OC_MAKE_VERSION(MMSOLVE) diff -crN oommf-1.1b0/app/mmsolve/odtcols.tcl oommf/app/mmsolve/odtcols.tcl *** oommf-1.1b0/app/mmsolve/odtcols.tcl Wed Dec 31 19:00:00 1969 --- oommf/app/mmsolve/odtcols.tcl Mon Oct 1 14:28:37 2001 *************** *** 0 **** --- 1,271 ---- + #!/bin/sh + # FILE: odtcols.tcl + # + # This Tcl script takes an .odt (OOMMF Data Table) file on stdin, and + # prints to stdout the requested columns, which are specified numerically + # starting with 1. + # + # Example Usage: tclsh odtcols.tcl 6 1 3 10 outfile.odt + # + # v--Edit here if necessary \ + exec tclsh "$0" ${1+"$@"} + + # Check for usage request + if {[llength $argv]<1 || [lsearch -regexp $argv {-+h.*}]>=0} { + puts stderr {Usage: tclsh odtcols.tcl [-h] [-s]\ + [-w colwidth] [-f format]\ + col# [col# ...] outfile} + exit 1 + } + + # Check for file summary request + set show_summary 0 + set cmdindex [lsearch -regexp $argv {-+s.*}] + if {$cmdindex>=0} { + set show_summary 1 + set argv [lreplace $argv $cmdindex $cmdindex] + } + + # Tweak stdio streams + fconfigure stdin -buffering full -buffersize 30000 + fconfigure stdout -buffering full -buffersize 30000 + + # Pull column width requests out from $argv + set colwidth 15 + while {[set width_index [lsearch -regexp $argv {-+w.*}]]>=0} { + set colwidth [lindex $argv [expr $width_index+1]] + set argv [lreplace $argv $width_index [expr $width_index+1]] + } + + # Pull data format requests out from $argv + set data_format "%-${colwidth}s" + while {[set fmt_index [lsearch -regexp $argv {-+f.*}]]>=0} { + set data_format [lindex $argv [expr $fmt_index+1]] + set argv [lreplace $argv $fmt_index [expr $fmt_index+1]] + } + + # Get column request from $argv + set colspecs $argv + if {[llength $colspecs]==0} {set colspecs {*}} ;# Default is full list + + # Proc to substitute column glob-style selection expressions + # to numerical indices. + proc GenerateColumnIndexList { subset full } { + # Do case insensitive matching. It might be preferable to + # match uppercase in subset only against uppercase in full, + # but to match lowercase in subset against either uppercase + # or lowercase in full. + set subset [string tolower $subset] + set full [string tolower $full] + set indices {} + foreach id $subset { + if {[regexp -- {^[0-9]+$} $id] && $id<[expr {[llength $full]+1}]} { + # id is a number; assume this is a direct index request, + # and shift from 1-based to 0-based indexing + lappend indices [expr {$id-1}] + } else { + # Otherwise, try a glob-style match + for {set i 0} {$i<[llength $full]} {incr i} { + if {[string match $id [lindex $full $i]]} { + lappend indices $i + } + } + } + } + return $indices + } + + # Header list request + if {$show_summary} { + proc DumpHeaders {column_subset column_list units_list \ + table_number table_title row_count} { + global colwidth + if {$table_number>1} { puts "" } ;# Table separator + if {[string match {} $table_title]} { + puts [format "*** Table %2d ***" $table_number] + } else { + puts [format "*** Table %2d: $table_title ***" $table_number] + } + if {[llength column_list]<1} { + if {$row_count>0} { + puts "WARNING: No column header line detected." + } + } else { + puts [format "Column %-${colwidth}s %s" Label Units] + set index 0 + if {[llength $column_subset]==0} { + # List all columns + foreach c $column_list u $units_list { + set c [list $c] + set u [list $u] + incr index + puts [format "%4d: %-${colwidth}s %s" $index $c $u] + } + } else { + # Dump column subset + foreach index $column_subset { + set c [list [lindex $column_list $index]] + set u [list [lindex $units_list $index]] + incr index + puts [format "%4d: %-${colwidth}s %s" $index $c $u] + } + puts "Columns: [llength $column_list]" + } + puts "Data rows: $row_count" + } + } + + set row_count 0 + set table_count 1 + set table_label {} + set column_list {} + set units_list {} + set columns {} + set line {} + while {[gets stdin newline]>=0} { + # Is new line a continuation of previous line? + if {![string match {} $line]} { + # Yes: strip any leading #'s + set newline [string trimleft $newline "#"] + } + # Is new line continued on next read? + if {[regexp -- {^(.*)\\$} $newline dummy match]} { + # Yes: append w/o trailing slash to current line + # and immediately read next line. + append line $match + continue + } + # Append new line to current line + append line $newline + + # Replace tabs (if any) with spaces. This simplifies regexp + # processing below + regsub -all -- "\t" $line " " line + + # Process current line + if {[string match "#" [string index $line 0]]} { + # Comment line + if {[regexp -nocase -- {^# +columns} $line]} { + # Column header line + set column_list [concat $column_list [lrange $line 2 end]] + set columns [GenerateColumnIndexList $colspecs $column_list] + } elseif {[regexp -nocase -- {^# +units} $line]} { + set units_list [concat $units_list [lrange $line 2 end]] + } elseif {[regexp -nocase -- {^# +table +start} $line]} { + # New table. Copy title string, if any + if {[regexp {^[^:]*: *(.*[^ ]) *$} $line dummy new_title]} { + set table_label $new_title + } + } elseif {[regexp -nocase -- {^# +title} $line]} { + # New title + if {[regexp {^[^:]*: *(.*[^ ]) *$} $line dummy new_title]} { + set table_label $new_title + } + } elseif {[regexp -nocase -- {^# +table +end} $line]} { + # End of current table + DumpHeaders $columns $column_list $units_list \ + $table_count $table_label $row_count + set row_count 0 + set table_label {} + set column_list {} + set units_list {} + incr table_count + } else { + # Plain or otherwise unprocessed comment line; skip + } + } else { + # Data line + incr row_count + } + set line {} + } + if {![string match {} $column_list] || $row_count>0} { + DumpHeaders $columns $column_list $units_list \ + $table_count $table_label $row_count + incr table_count + } + if {$table_count>2} { + puts [format "\nTotal number of tables: %2d" [expr $table_count-1]] + } + exit 0 + } + + # Collimated output routines + proc ColumnDump { list {leader " "}} { + global colwidth default_format + puts -nonewline $leader + foreach elt $list { + puts -nonewline [format " %-${colwidth}s" [list $elt]] + } + puts {} + } + + proc ColumnDataDump { list {leader " "}} { + global colwidth data_format + puts -nonewline $leader + foreach elt $list { + set entry [format $data_format $elt] + puts -nonewline [format " %-${colwidth}s" $entry] + } + puts {} + } + + + # Loop through input lines + set line {} + set columns {} + while {[gets stdin newline]>=0} { + # Is new line a continuation of previous line? + if {![string match {} $line]} { + # Yes: strip any leading #'s + set newline [string trimleft $newline "#"] + } + # Is new line continued on next read? + if {[regexp -- {^(.*)\\$} $newline dummy match]} { + # Yes: append w/o trailing slash to current line + # and immediately read next line. + append line $match + continue + } + # Append new line to current line + append line $newline + + # Replace tabs (if any) with spaces. This simplifies regexp + # processing below + regsub -all -- "\t" $line " " line + + # Process current line + if {[string match "#" [string index $line 0]]} { + # Comment line + if {[regexp -nocase -- {^# +columns} $line]} { + # Column header line + set columns [GenerateColumnIndexList $colspecs \ + [lrange $line 2 end]] + set outlist {} + foreach i $columns { + lappend outlist [lindex $line [expr $i+2]] + } + puts "# Columns: \\" + ColumnDump $outlist "#" + } elseif {[regexp -nocase -- {^# +units} $line]} { + set outlist {} + foreach i $columns { + lappend outlist [lindex $line [expr $i+2]] + } + puts "# Units: \\" + ColumnDump $outlist "#" + } else { + # Plain comment line + puts $line + } + } else { + # Data line + set outlist {} + foreach i $columns { + lappend outlist [lindex $line $i] + } + ColumnDataDump $outlist " " + } + set line {} + } + diff -crN oommf-1.1b0/app/mmsolve/procs.tcl oommf/app/mmsolve/procs.tcl *** oommf-1.1b0/app/mmsolve/procs.tcl Thu Mar 11 16:28:25 1999 --- oommf/app/mmsolve/procs.tcl Tue May 29 13:30:14 2001 *************** *** 9,14 **** --- 9,19 ---- # First open file directly set chanid [open $filename r] + # Would rather turn on large buffered, binary translation only + # after checking for the P3 header (see [fconfigure] below), + # but a bug in Tcl 8.1-8.3 prevents that. :( + fconfigure $chanid -translation binary \ + -buffering full -buffersize 250000 set var [read $chanid 2] if {![string match P3 $var]} { # Input file is not PPM P3 (ASCII) type. Send through filter. *************** *** 22,30 **** } set cmdLine [linsert $cmdLine 0 |] set chanid [open $cmdLine r] } - fconfigure $chanid -translation binary \ - -buffering full -buffersize 250000 append var [read $chanid] close $chanid } --- 27,35 ---- } set cmdLine [linsert $cmdLine 0 |] set chanid [open $cmdLine r] + fconfigure $chanid -translation binary \ + -buffering full -buffersize 250000 } append var [read $chanid] close $chanid } diff -crN oommf-1.1b0/app/mmsolve/scripts/appindex.tcl oommf/app/mmsolve/scripts/appindex.tcl *** oommf-1.1b0/app/mmsolve/scripts/appindex.tcl Tue Mar 28 19:43:06 2000 --- oommf/app/mmsolve/scripts/appindex.tcl Thu Apr 27 16:37:48 2000 *************** *** 1,6 **** Oc_Application Define { -name batchmaster ! -version 1.1.1.0 -machine filtersh -file batchmaster.tcl -options {-tk 0} --- 1,6 ---- Oc_Application Define { -name batchmaster ! -version 1.1.1.1 -machine filtersh -file batchmaster.tcl -options {-tk 0} *************** *** 9,15 **** Oc_Application Define { -name batchslave ! -version 1.1.1.0 -machine mmsolve -file batchslave.tcl -options {-tk 0} --- 9,15 ---- Oc_Application Define { -name batchslave ! -version 1.1.1.1 -machine mmsolve -file batchslave.tcl -options {-tk 0} *************** *** 17,23 **** Oc_Application Define { -name batchsolve ! -version 1.1.1.0 -machine mmsolve -file batchsolve.tcl -options {-tk 0} --- 17,23 ---- Oc_Application Define { -name batchsolve ! -version 1.1.1.1 -machine mmsolve -file batchsolve.tcl -options {-tk 0} *************** *** 26,32 **** Oc_Application Define { -name mag2hfield ! -version 1.1.1.0 -machine mmsolve -file mag2hfield.tcl -options {-tk 0} --- 26,32 ---- Oc_Application Define { -name mag2hfield ! -version 1.1.1.1 -machine mmsolve -file mag2hfield.tcl -options {-tk 0} diff -crN oommf-1.1b0/app/mmsolve/scripts/batchmaster.tcl oommf/app/mmsolve/scripts/batchmaster.tcl *** oommf-1.1b0/app/mmsolve/scripts/batchmaster.tcl Thu Mar 30 14:49:33 2000 --- oommf/app/mmsolve/scripts/batchmaster.tcl Thu Apr 27 16:37:48 2000 *************** *** 11,17 **** Oc_ForceNoTkDefaultMessage ;# Use stderr, not dialog to report errors Oc_Main SetAppName batchmaster ! Oc_Main SetVersion 1.1.1.0 Oc_CommandLine Option [Oc_CommandLine Switch] { {task_script {} {Task definition file}} --- 11,17 ---- Oc_ForceNoTkDefaultMessage ;# Use stderr, not dialog to report errors Oc_Main SetAppName batchmaster ! Oc_Main SetVersion 1.1.1.1 Oc_CommandLine Option [Oc_CommandLine Switch] { {task_script {} {Task definition file}} diff -crN oommf-1.1b0/app/mmsolve/scripts/batchslave.tcl oommf/app/mmsolve/scripts/batchslave.tcl *** oommf-1.1b0/app/mmsolve/scripts/batchslave.tcl Fri Mar 31 17:09:07 2000 --- oommf/app/mmsolve/scripts/batchslave.tcl Thu Apr 27 16:37:48 2000 *************** *** 14,20 **** Oc_ForceNoTkDefaultMessage ;# Error messages to stderr, not dialog Oc_Main SetAppName batchslave ! Oc_Main SetVersion 1.1.1.0 Oc_CommandLine Option [Oc_CommandLine Switch] { {host {} {Hostname to connect to master}} --- 14,20 ---- Oc_ForceNoTkDefaultMessage ;# Error messages to stderr, not dialog Oc_Main SetAppName batchslave ! Oc_Main SetVersion 1.1.1.1 Oc_CommandLine Option [Oc_CommandLine Switch] { {host {} {Hostname to connect to master}} diff -crN oommf-1.1b0/app/mmsolve/scripts/batchsolve.tcl oommf/app/mmsolve/scripts/batchsolve.tcl *** oommf-1.1b0/app/mmsolve/scripts/batchsolve.tcl Fri Mar 31 17:09:07 2000 --- oommf/app/mmsolve/scripts/batchsolve.tcl Thu Sep 21 15:18:56 2000 *************** *** 10,16 **** Oc_ForceNoTkDefaultMessage ;# use stderr, not dialog for messages Oc_Main SetAppName batchsolve ! Oc_Main SetVersion 1.1.1.0 Oc_CommandLine Option interface { {flag {expr {![catch {expr {$flag && $flag}}]}} {= 0 or 1}} --- 10,16 ---- Oc_ForceNoTkDefaultMessage ;# use stderr, not dialog for messages Oc_Main SetAppName batchsolve ! Oc_Main SetVersion 1.1.1.1 Oc_CommandLine Option interface { {flag {expr {![catch {expr {$flag && $flag}}]}} {= 0 or 1}} *************** *** 463,469 **** # the DataTable protocol set eormsg [list [list "@Filename:" {} 0]] foreach thread [Net_Thread Instances] { ! if {[string match DataTable [$thread Protocol]]} { $thread Send DataTable $eormsg } } --- 463,470 ---- # the DataTable protocol set eormsg [list [list "@Filename:" {} 0]] foreach thread [Net_Thread Instances] { ! if {[$thread Ready] \ ! && [string match DataTable [$thread Protocol]]} { $thread Send DataTable $eormsg } } diff -crN oommf-1.1b0/app/mmsolve/scripts/mag2hfield.tcl oommf/app/mmsolve/scripts/mag2hfield.tcl *** oommf-1.1b0/app/mmsolve/scripts/mag2hfield.tcl Thu Mar 9 22:47:26 2000 --- oommf/app/mmsolve/scripts/mag2hfield.tcl Thu Apr 27 16:37:48 2000 *************** *** 6,12 **** package require Mms 1.1.1 Oc_Main SetAppName mag2hfield ! Oc_Main SetVersion 1.1.1.0 Oc_CommandLine Option console {} {} --- 6,12 ---- package require Mms 1.1.1 Oc_Main SetAppName mag2hfield ! Oc_Main SetVersion 1.1.1.1 Oc_CommandLine Option console {} {} diff -crN oommf-1.1b0/app/mmsolve/solver.tcl oommf/app/mmsolve/solver.tcl *** oommf-1.1b0/app/mmsolve/solver.tcl Wed Jan 19 20:22:08 2000 --- oommf/app/mmsolve/solver.tcl Fri Sep 28 19:32:16 2001 *************** *** 72,77 **** --- 72,84 ---- private variable run_maxangle ;# Largest angle between any ## two neighboring spins throughout run. + private variable angle_threshold = 30 ;# Angle (in degrees) + ## above which a maxangle value should report a warning. + + private variable angle_warning = 1 ;# Whether or not + ## we warn when maxangle exceeds angle_threshold. Determined + ## by whether or not run_maxangle starts exceeding it. + private variable restart = 0 ;# If true, then current grid was ## initialized using (or at least attempting to use) a log file ## from an earlier run to extract restart information. *************** *** 95,100 **** --- 102,108 ---- # FieldDone --- FieldStep attempted, but no more steps in list # RunDone --- New problem, reset, solver closing, or FieldStep # attempted with no more steps in list + # BigAngle --- When maxangle exceeds angle_threshold # delete --- Instance being deleted # Note: A given ODE iteration my raise multiple events, but # CheckPoint events are not raised more than once on the same *************** *** 393,398 **** --- 401,407 ---- puts $logchan " Run Max Angle (deg): $run_maxangle" close $logchan } + set angle_warning [expr {$run_maxangle <= $angle_threshold}] $this ChangeSolverState Pause } private method UpdateField {} { *************** *** 567,573 **** set lcp_maxangle $maxangle ;# Reset on first step ## after control point, or if maxangle is bigger. } ! if {$run_maxangle<$maxangle} { set run_maxangle $maxangle } incr ode_step_count --- 576,588 ---- set lcp_maxangle $maxangle ;# Reset on first step ## after control point, or if maxangle is bigger. } ! if {$run_maxangle<$maxangle} { ! set run_maxangle $maxangle ! if {$angle_warning && ($run_maxangle > $angle_threshold)} { ! Oc_EventHandler Generate $this BigAngle -angle $run_maxangle ! set angle_warning 0 ! } ! } incr ode_step_count diff -crN oommf-1.1b0/app/mmsolve2d/appindex.tcl oommf/app/mmsolve2d/appindex.tcl *** oommf-1.1b0/app/mmsolve2d/appindex.tcl Mon Mar 20 14:02:51 2000 --- oommf/app/mmsolve2d/appindex.tcl Thu Apr 27 16:37:48 2000 *************** *** 1,7 **** Oc_Application Define { -name mmSolve2D ! -version 1.1.1.0 -machine mmsolve -file mmsolve2d.tcl -options {-tk 0} --- 1,7 ---- Oc_Application Define { -name mmSolve2D ! -version 1.1.1.1 -machine mmsolve -file mmsolve2d.tcl -options {-tk 0} diff -crN oommf-1.1b0/app/mmsolve2d/mmsolve2d.tcl oommf/app/mmsolve2d/mmsolve2d.tcl *** oommf-1.1b0/app/mmsolve2d/mmsolve2d.tcl Thu Mar 9 18:18:48 2000 --- oommf/app/mmsolve2d/mmsolve2d.tcl Fri Sep 28 19:32:16 2001 *************** *** 11,18 **** ## goes down. Oc_Main SetAppName mmSolve2D ! Oc_Main SetVersion 1.1.1.0 ! regexp \\\044Date:(.*)\\\044 {$Date: 2000/03/09 23:18:48 $} _ date Oc_Main SetDate [string trim $date] Oc_Main SetAuthor [Oc_Person Lookup dgp] Oc_Main SetHelpURL [Oc_Url FromFilename [file join [file dirname \ --- 11,18 ---- ## goes down. Oc_Main SetAppName mmSolve2D ! Oc_Main SetVersion 1.1.1.1 ! regexp \\\044Date:(.*)\\\044 {$Date: 2001/09/28 23:32:16 $} _ date Oc_Main SetDate [string trim $date] Oc_Main SetAuthor [Oc_Person Lookup dgp] Oc_Main SetHelpURL [Oc_Url FromFilename [file join [file dirname \ *************** *** 115,121 **** [file join [Oc_Main GetOOMMFRootDir] mmsolve2d.errors] mms_mif New mif ! if {[catch {$mif Read $mif_file}]} { Oc_EventHandler Generate LoadProbDescFile BadMifFile -thread $threadID $mif Delete file delete $mif_file --- 115,122 ---- [file join [Oc_Main GetOOMMFRootDir] mmsolve2d.errors] mms_mif New mif ! if {[catch {$mif Read $mif_file} msg]} { ! Oc_Log Log $msg error Oc_EventHandler Generate LoadProbDescFile BadMifFile -thread $threadID $mif Delete file delete $mif_file *************** *** 249,254 **** --- 250,259 ---- [list $connection Tell Status \ "Load failed: Invalid Problem Description (MIF) from %thread"] \ -groups [list $connection] + Oc_EventHandler New _ mms_solver BigAngle \ + [list $connection Tell Status \ + "WARNING: Spin-spin angle (%angle degrees) exceeds threshold"] \ + -groups [list $connection] return [list start [list 0 1]] } $protocol AddMessage start Commands {} { *************** *** 509,515 **** # the DataTable protocol set eormsg [list [list "@Filename:" {} 0]] foreach thread [Net_Thread Instances] { ! if {[string match DataTable [$thread Protocol]]} { $thread Send DataTable $eormsg } } --- 514,520 ---- # the DataTable protocol set eormsg [list [list "@Filename:" {} 0]] foreach thread [Net_Thread Instances] { ! if {[$thread Ready] && [string match DataTable [$thread Protocol]]} { $thread Send DataTable $eormsg } } diff -crN oommf-1.1b0/app/omfsh/makerules.tcl oommf/app/omfsh/makerules.tcl *** oommf-1.1b0/app/omfsh/makerules.tcl Mon Feb 28 20:18:53 2000 --- oommf/app/omfsh/makerules.tcl Thu Apr 27 16:37:48 2000 *************** *** 36,48 **** puts $f [format { Oc_Application Define { -name omfsh ! -version 1.1.1.0 -machine %s -file "%s" } Oc_Application Define { -name filtersh ! -version 1.1.1.0 -machine %s -file "%s" } --- 36,48 ---- puts $f [format { Oc_Application Define { -name omfsh ! -version 1.1.1.1 -machine %s -file "%s" } Oc_Application Define { -name filtersh ! -version 1.1.1.1 -machine %s -file "%s" } diff -crN oommf-1.1b0/app/omfsh/omfsh.cc oommf/app/omfsh/omfsh.cc *** oommf-1.1b0/app/omfsh/omfsh.cc Sun Feb 27 20:53:07 2000 --- oommf/app/omfsh/omfsh.cc Thu Oct 5 18:09:58 2000 *************** *** 4,10 **** * * NOTICE: Plase see the file ../../LICENSE * ! * Last modified on: $Date: 2000/02/28 01:53:07 $ * Last modified by: $Author: dgp $ */ --- 4,10 ---- * * NOTICE: Plase see the file ../../LICENSE * ! * Last modified on: $Date: 2000/10/05 22:09:58 $ * Last modified by: $Author: dgp $ */ *************** *** 29,42 **** return TCL_ERROR; } Tcl_StaticPackage(interp, ab("Oc"), Oc_Init, NULL); ! // For now, always link in and initialize the If extension. // Eventually move to support selection of which extensions // to initialize on the basis of command line switches to // the shell. ! if (If_Init(interp) != TCL_OK) { ! return TCL_ERROR; } - Tcl_StaticPackage(interp, ab("If"), If_Init, NULL); if (Nb_Init(interp) != TCL_OK) { return TCL_ERROR; --- 29,56 ---- return TCL_ERROR; } Tcl_StaticPackage(interp, ab("Oc"), Oc_Init, NULL); ! // Eventually move to support selection of which extensions // to initialize on the basis of command line switches to // the shell. ! ! if (Tcl_PkgPresent(interp, ab("Tk"), NULL, 0) != NULL) { ! // Adding support for image formats only makes sense ! // if Tk is initialized. ! ! // First, try the Img package ! if (Tcl_PkgRequire(interp, ab("Img"), NULL, 0) == NULL) { ! ! // If no Img package available, then supply our ! // poor man's support for image formats (Windows BMP) ! if (If_Init(interp) != TCL_OK) { ! return TCL_ERROR; ! } ! Tcl_StaticPackage(interp, ab("If"), If_Init, NULL); ! ! } ! } if (Nb_Init(interp) != TCL_OK) { return TCL_ERROR; diff -crN oommf-1.1b0/app/pimake/appindex.tcl oommf/app/pimake/appindex.tcl *** oommf-1.1b0/app/pimake/appindex.tcl Tue Feb 29 18:11:03 2000 --- oommf/app/pimake/appindex.tcl Thu Apr 27 16:37:48 2000 *************** *** 1,7 **** Oc_Application Define { -name pimake ! -version 1.1.1.0 -machine tclsh -file pimake.tcl -mode fg --- 1,7 ---- Oc_Application Define { -name pimake ! -version 1.1.1.1 -machine tclsh -file pimake.tcl -mode fg diff -crN oommf-1.1b0/app/pimake/pimake.tcl oommf/app/pimake/pimake.tcl *** oommf-1.1b0/app/pimake/pimake.tcl Tue Mar 28 19:54:18 2000 --- oommf/app/pimake/pimake.tcl Thu Apr 27 16:37:48 2000 *************** *** 138,144 **** wm withdraw . } Oc_Main SetAppName pimake ! Oc_Main SetVersion 1.1.1.0 # Disable the -console option; we don't enter an event loop Oc_CommandLine Option console {} {} --- 138,144 ---- wm withdraw . } Oc_Main SetAppName pimake ! Oc_Main SetVersion 1.1.1.1 # Disable the -console option; we don't enter an event loop Oc_CommandLine Option console {} {} diff -crN oommf-1.1b0/app/pimake/procs.tcl oommf/app/pimake/procs.tcl *** oommf-1.1b0/app/pimake/procs.tcl Mon Nov 8 11:32:11 1999 --- oommf/app/pimake/procs.tcl Wed Jul 26 14:45:00 2000 *************** *** 27,82 **** } } ! proc MakeTclIndex {dir args} { ! puts "Updating [file join [pwd] tclIndex] ..." ! eval auto_mkindex $dir $args ! global errorCode errorInfo ! set oldDir [pwd] ! cd $dir ! set dir [pwd] ! append index "# The following lines were appended to this file by the\n" ! append index "# command 'MakeTclIndex' of the pimake application. They\n" ! append index "# provide entries in the auto_index array to support the\n" ! append index "# auto-loading of Oc_Classes.\n\n" ! if {$args == ""} { ! set args *.tcl ! } ! foreach file [eval glob $args] { ! set f "" ! set error [catch { ! set f [open $file] ! while {[gets $f line] >= 0} { ! if {[regexp {^Oc_Class[ ]+([^ ]*)} $line match className]} { ! append index "set [list auto_index($className)]" ! # Should this be at global scope? ! append index " \[list uplevel #0 source \[list \[file join \$dir [list $file]\]\]\]\n" ! } ! } ! close $f ! } msg] ! if {$error} { ! set code $errorCode ! set info $errorInfo ! catch {close $f} ! cd $oldDir ! error $msg $info $code ! } ! } ! set f "" ! set error [catch { ! set f [open tclIndex a] ! puts $f $index nonewline ! close $f ! cd $oldDir ! } msg] ! if {$error} { ! set code $errorCode ! set info $errorInfo ! catch {close $f} ! cd $oldDir ! error $msg $info $code ! } ! } proc Recursive {target} { foreach mr [glob -nocomplain [file join * makerules.tcl]] { --- 27,33 ---- } } ! interp alias {} MakeTclIndex {} Oc_MakeTclIndex proc Recursive {target} { foreach mr [glob -nocomplain [file join * makerules.tcl]] { diff -crN oommf-1.1b0/config/cache/hpux.tcl oommf/config/cache/hpux.tcl *** oommf-1.1b0/config/cache/hpux.tcl Thu Oct 28 12:01:52 1999 --- oommf/config/cache/hpux.tcl Wed May 9 20:11:32 2001 *************** *** 93,98 **** --- 93,107 ---- $config SetValue program_compiler_c++_option_inc {format "\"-I%s\""} $config SetValue program_compiler_c++_option_warn {format "+w1"} $config SetValue program_compiler_c++_option_debug {format "-g"} + + # The HP CC compiler doesn't support the + # 'using namespace std' directive. + $config SetValue \ + program_compiler_c++_property_no_std_namespace 1 + # Because of that, we should avoid exceptions + $config SetValue \ + program_compiler_c++_property_no_exceptions 1 + } elseif {[string match aCC $ccbasename]} { # ...for HP-UX's compiler aCC. # NOTE: Debugging (-g) is incompatible with optimization. *************** *** 108,113 **** --- 117,126 ---- # 'using namespace std' directive. $config SetValue \ program_compiler_c++_property_no_std_namespace 1 + # Because of that, we should avoid exceptions + $config SetValue \ + program_compiler_c++_property_no_exceptions 1 + } elseif {[string match g++ $ccbasename]} { # ...for GNU g++ C++ compiler $config SetValue program_compiler_c++_option_opt {format "\"-O%s\""} diff -crN oommf-1.1b0/doc/cllaunch-body.tex oommf/doc/cllaunch-body.tex *** oommf-1.1b0/doc/cllaunch-body.tex Tue Apr 4 20:38:43 2000 --- oommf/doc/cllaunch-body.tex Mon Apr 23 15:26:30 2001 *************** *** 117,123 **** applications which do not inherently use display widgets support disabling of Tk with \verb+-tk 0+. Other applications which must use display widgets are unable to run ! with the option \verb+-tk 0+. \item[{\tt\bf -cwd directory}] Set the current working directory of the application. --- 117,127 ---- applications which do not inherently use display widgets support disabling of Tk with \verb+-tk 0+. Other applications which must use display widgets are unable to run ! with the option \verb+-tk 0+. To run those applications that require ! \verb+-tk 1+ on a Unix system with no display, one might use ! \htmladdnormallinkfoot{Xvfb ! }{http://www.itworld.com/AppDev/1461/UIR000330xvfb/} ! \index{application!Xvfb}. \item[{\tt\bf -cwd directory}] Set the current working directory of the application. diff -crN oommf-1.1b0/doc/cmdutils-body.tex oommf/doc/cmdutils-body.tex *** oommf-1.1b0/doc/cmdutils-body.tex Thu Mar 30 19:56:12 2000 --- oommf/doc/cmdutils-body.tex Tue Oct 2 10:47:56 2001 *************** *** 399,404 **** --- 399,452 ---- \fn{.omf} magnetization file name, stripped of any trailing \fn{.omf} or \fn{.ovf} extension. + \subsection{\ODT\ Column Extraction: odtcols}\label{sec:odtcols}% + \index{file!data~table} + + The \app{odtcols}\index{application!odtcols} utility extracts column + subsets from \hyperrefhtml{\ODT}{\ODT\ (Sec.~}{)}{sec:odtformat} data + table files. + + \sssechead{Launching} + The \app{odtcols} launch command is: + \begin{verbatim} + tclsh oommf.tcl odtcols [standard options] [-s] [-w colwidth] \ + [-f format] [col ...] outfile + \end{verbatim} + where + \begin{description} + \item[{\tt\bf -s}] + Produces a file summary instead of column extraction. Output includes + table titles, column and row counts, and the header for each specified + column. If no columns are specified, then the headers for all the + columns are listed. + \item[{\tt\bf -w colwidth}] + Minimum horizontal spacing to provide for each column on output. + Optional. Default value is 15. + \item[{\tt\bf -f format}] + C printf-style format string for each output item. Optional. Default + is \verb+"%-${colwidth}s"+. + \item[{\tt\bf col ...}] + Output column selections. These may either be integers representing + the position of the column in the input data (with the first column + numbered as 1), or else arbitrary strings used for case-insensitive + glob-style matching against the column headers. The columns are + output in match order, obtained by processing the column selections + from left to right. If no columns are specified then by default all + columns are selected. + \item[{\tt\bf $>$infile}] + Odtcols reads its input from stdin. Use the redirection operator + ``$<$'' to read input from a file. + \item[{\tt\bf $>$outfile}] + Odtcols writes its output to stdout. Use the redirection operator + ``$>$'' to send the output to a file. + \end{description} + Commonly the {\tt\bf -s} switch is used in a first pass, to reveal the + column headers; specific column selections may then be made in a second, + separate invocation. + + + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \subsection{Platform-Independent Make: pimake}\label{sec:pimake}% \index{application!pimake} Binary files oommf-1.1b0/doc/contents.gif and oommf/doc/contents.gif differ Binary files oommf-1.1b0/doc/contents_motif.gif and oommf/doc/contents_motif.gif differ diff -crN oommf-1.1b0/doc/credits-body.tex oommf/doc/credits-body.tex *** oommf-1.1b0/doc/credits-body.tex Tue Nov 23 16:10:56 1999 --- oommf/doc/credits-body.tex Mon Aug 27 13:16:16 2001 *************** *** 36,54 **** Quite a few users\index{contributors} have contributed to the development of \OOMMF\ by submitting bug reports, small pieces of code, or suggestions for improvements. Many thanks to all these people, ! including Olivier G\'{e}rardin, Ping He, Michael Ho, Pavel Kabos, ! Michael Kleiber, H. T. Leung, David Lewis, Sang Ho Lim, Yi Liu, Van Luu, ! Andy P. Manners, Edward Myers, Valentine Novosad, Andrew Perrella, Anil ! Prabhakar, Robert Ravlic, Stephen E. Russek, Renat Sabirianov, Zhupei ! Shi, Xiaobo Tan, Stephen Thompson, Pieter Visscher, Scott ! L. Whittenburg, Kong Xiangyang, Chengtao Yu, Steven A. Zielke, and Pei ! Zou. If you have bug reports\index{reporting~bugs}, contributed code, feature requests, or other comments for the \OOMMF\ developers, please send them in an e-mail\index{e-mail} message to {\htmladdnormallink{{\tt }}{mailto:michael.donahue@nist.gov}}% \index{contact~information}. % Give Latex2Html version and reference, as specified by the % Perl $INFO variable set in .latex2html-init. --- 36,71 ---- Quite a few users\index{contributors} have contributed to the development of \OOMMF\ by submitting bug reports, small pieces of code, or suggestions for improvements. Many thanks to all these people, ! including Dieter Buntinx, NgocNga Dao, Olivier G\'{e}rardin, Ping He, ! Michael Ho, Mansoor B. A. Jalil, J\"{o}rg Jorzick, Pavel Kabos, Michael ! Kleiber, H. T. Leung, David Lewis, Sang Ho Lim, Yi Liu, Van Luu, Andy ! P. Manners, Edward Myers, Andrew Newell, Valentine Novosad, Andrew ! Perrella, Angeline Phoa, Anil Prabhakar, Robert Ravlic, Stephen ! E. Russek, Renat Sabirianov, Zhupei Shi, Xiaobo Tan, Stephen Thompson, ! Vassilios Tsiantos, Pieter Visscher, Scott L. Whittenburg, Kong ! Xiangyang, Chengtao Yu, Steven A. Zielke, and Pei Zou. If you have bug reports\index{reporting~bugs}, contributed code, feature requests, or other comments for the \OOMMF\ developers, please send them in an e-mail\index{e-mail} message to {\htmladdnormallink{{\tt }}{mailto:michael.donahue@nist.gov}}% \index{contact~information}. + + Acknowledgement is appreciated if the software is used. We recommend + citing the following NIST technical report\index{citation~information}: + \begin{quote} + M. J. Donahue and D. G. Porter\\ + OOMMF User's Guide, Version 1.0\\ + Interagency Report NISTIR 6376\\ + National Institute of Standards and Technology, Gaithersburg, MD (Sept 1999). + \end{quote} + and optionally include the URL of the \OOMMF\ home page, + \htmladdnormallink{\texttt{http://math.nist.gov/oommf/}}{http://math.nist.gov/oommf/}. + To help us keep our + \htmladdnormallinkfoot{bibliography page}{http://math.nist.gov/oommf/bibliography.html} + current, please direct publication + information to {\htmladdnormallink{{\tt + }}{mailto:michael.donahue@nist.gov}}. % Give Latex2Html version and reference, as specified by the % Perl $INFO variable set in .latex2html-init. diff -crN oommf-1.1b0/doc/disclaimer-body.tex oommf/doc/disclaimer-body.tex *** oommf-1.1b0/doc/disclaimer-body.tex Thu Oct 28 19:01:36 1999 --- oommf/doc/disclaimer-body.tex Mon Aug 27 13:16:16 2001 *************** *** 10,19 **** \OOMMF\ is an experimental system. NIST assumes no responsibility whatsoever for its use by other parties, and makes no guarantees, expressed or implied, about its quality, reliability, or any other ! characteristic. We would appreciate acknowledgement if the software is ! used. ! Commercial equipment and software referred to on these pages is identified for informational purposes only, and does not imply recommendation of or endorsement by the National Institute of Standards and Technology, nor does it imply that the products so identified are --- 10,24 ---- \OOMMF\ is an experimental system. NIST assumes no responsibility whatsoever for its use by other parties, and makes no guarantees, expressed or implied, about its quality, reliability, or any other ! characteristic. ! We would appreciate acknowledgement if the software is used. When ! referencing \OOMMF\ software, we recommend citing the NIST technical ! report, M. J. Donahue and D. G. Porter, ``OOMMF User's Guide, Version ! 1.0,'' \textbf{NISTIR 6376}, National Institute of Standards and ! Technology, Gaithersburg, MD (Sept 1999). ! ! Commercial equipment and software referred to on these pages are identified for informational purposes only, and does not imply recommendation of or endorsement by the National Institute of Standards and Technology, nor does it imply that the products so identified are diff -crN oommf-1.1b0/doc/fileformats-body.tex oommf/doc/fileformats-body.tex *** oommf-1.1b0/doc/fileformats-body.tex Tue Apr 4 06:18:20 2000 --- oommf/doc/fileformats-body.tex Sat Sep 29 14:24:58 2001 *************** *** 248,254 **** sample. \item {\bf avfFile filename}\\ The second parameter specifies an OVF/VIO (i.e., ``any'' ! vector field) file\index{file!ovf}\index{file!vio} to use to initialize the magnetization. The grid in the input file will be scaled as necessary to fit the grid in the current simulation. The file must be accessible to the intended solver --- 248,254 ---- sample. \item {\bf avfFile filename}\\ The second parameter specifies an OVF/VIO (i.e., ``any'' ! vector field) file\index{file!vector~field}\index{file!vio} to use to initialize the magnetization. The grid in the input file will be scaled as necessary to fit the grid in the current simulation. The file must be accessible to the intended solver *************** *** 385,398 **** \begin{itemize} \item {\bf Base Output Filename:} Default base name used to construct output filenames. ! \item {\bf Magnetization Output Format:}\index{file!omf} Format to ! use in the \hyperrefhtml{\OVF}{\OVF\ (Sec.~}{)}{sec:ovfformat} ! data block for exported magnetization files. Should be one of ! ``binary 4'' (default), ``binary 8'', or ``text {\em ! format-spec}'', where {\em format-spec} is a C \cd{printf}-style ! format code (default is \cd{\"\%\lb\ .17g\"}). ! \item {\bf Total Field Output Format:}\index{file!ohf} Analogous to ! the Magnetization Output Format, but for total field output files. \end{itemize} \sssechead{Miscellaneous}\label{par:mifmisc}\par --- 385,399 ---- \begin{itemize} \item {\bf Base Output Filename:} Default base name used to construct output filenames. ! \item {\bf Magnetization Output Format:}\index{file!magnetization} ! Format to use in the \hyperrefhtml{\OVF}{\OVF\ ! (Sec.~}{)}{sec:ovfformat} data block for exported magnetization ! files. Should be one of ``binary 4'' (default), ``binary 8'', or ! ``text {\em format-spec}'', where {\em format-spec} is a C ! \cd{printf}-style format code (default is \cd{\"\%\lb\ .17g\"}). ! \item {\bf Total Field Output Format:}\index{file!vector~field} ! Analogous to the Magnetization Output Format, but for total field ! output files. \end{itemize} \sssechead{Miscellaneous}\label{par:mifmisc}\par *************** *** 519,524 **** --- 520,529 ---- and before any Table End line, with one record per line. The data should be numeric values separated by whitespace. + The command line utility, + \hyperrefhtml{\app{odtcols}}{\app{odtcols} (Sec.~}{)}{sec:odtcols}, + can be a useful tool for examining and partitioning \ODT\ files. + \begin{codelisting}{f}{fig:odtsample}{Sample \ODT\ file.}{sec:odtformat} \begin{verbatim} # ODT 1.0 *************** *** 788,797 **** \subsubsection{The \OVF\ 0.0 format}\label{sec:svfformat} ! The \OVF\ 0.0 format\index{file!ovf} is a simple \ASCII\ text format ! supporting irregularly sampled data. It is intended as an aid for ! importing data from non-\OOMMF\ programs, and is backwards compatible ! with the format used for problem submissions for the \htmladdnormallinkfoot{first \mumag\ standard problem}{http://www.ctcms.nist.gov/\~{}rdm/stdprob\_1.html}. --- 793,802 ---- \subsubsection{The \OVF\ 0.0 format}\label{sec:svfformat} ! The \OVF\ 0.0 format\index{file!vector~field} is a simple \ASCII\ text ! format supporting irregularly sampled data. It is intended as an aid ! for importing data from non-\OOMMF\ programs, and is backwards ! compatible with the format used for problem submissions for the \htmladdnormallinkfoot{first \mumag\ standard problem}{http://www.ctcms.nist.gov/\~{}rdm/stdprob\_1.html}. diff -crN oommf-1.1b0/doc/install-body.tex oommf/doc/install-body.tex *** oommf-1.1b0/doc/install-body.tex Tue Apr 4 06:18:20 2000 --- oommf/doc/install-body.tex Tue Oct 2 20:30:17 2001 *************** *** 8,16 **** \Windows\ 95/98/NT. \Tcl\ and \Tk\ must be installed before installing \OOMMF. ! \Tcl\ and \Tk\ are available for free download from ! \htmladdnormallinkfoot{Scriptics Corporation}{http://www.scriptics.com/} ! \index{Scriptics~Corporation}. We recommend the latest stable versions of \Tcl\ and \Tk\ concurrent with this release of \OOMMF. \OOMMF\ requires\index{requirement!Tcl/Tk} --- 8,18 ---- \Windows\ 95/98/NT. \Tcl\ and \Tk\ must be installed before installing \OOMMF. ! \Tcl\ and \Tk\ are available for free ! \htmladdnormallinkfoot{download ! }{http://purl.org/tcl/home/software/tcltk/choose.html} ! from the ! \htmladdnormallinkfoot{Tcl Developer Xchange}{http://purl.org/tcl/home/}. We recommend the latest stable versions of \Tcl\ and \Tk\ concurrent with this release of \OOMMF. \OOMMF\ requires\index{requirement!Tcl/Tk} *************** *** 43,48 **** --- 45,63 ---- access the loopback interface so that the host can talk to itself using TCP/IP. + \index{application!Xvfb|(} + \OOMMF\ applications that use \Tk\ require a windowing system and + a valid display. On Unix systems, this means that an X server must + be running. If you need to run \OOMMF\ applications on a Unix system + without display hardware or software, you may need start the + application with command line option + \hyperrefhtml{{\tt\bf -tk 0}}{{\tt\bf -tk0} (see Sec.~}{)}{sec:cll} + or use the + \htmladdnormallinkfoot{Xvfb + }{http://www.itworld.com/AppDev/1461/UIR000330xvfb/} + virtual frame buffer to stand in for the missing display. + \index{application!Xvfb|)} + \index{requirement!disk~space|(} The \OOMMF\ source distribution unpacks into a directory tree containing about 500 files and directories, occupying about 7 MB of storage. *************** *** 115,121 **** For the first format, unpack the distribution archive using gunzip and tar: \begin{verbatim} ! gunzip -c oommf11b0_20000404.tar.gz | tar xvf - \end{verbatim} For the other format(s), you will need a utility program to unpack the --- 130,136 ---- For the first format, unpack the distribution archive using gunzip and tar: \begin{verbatim} ! gunzip -c oommf11b1_20011002.tar.gz | tar xvf - \end{verbatim} For the other format(s), you will need a utility program to unpack the *************** *** 124,133 **** names not limited to the traditional MSDOS 8.3 format. Some very old versions of the pkzip utility do not have these properties. One utility program which is known to work is ! \htmladdnormallinkfoot{UnZip}{http://www.cdrom.com/pub/infozip/UnZip.html}. Using your utility, unpack the \fn{.zip} archive, e.g. \begin{verbatim} ! unzip oommf11b0_20000404.zip \end{verbatim} For either distribution format, the unpacking sequence creates a --- 139,148 ---- names not limited to the traditional MSDOS 8.3 format. Some very old versions of the pkzip utility do not have these properties. One utility program which is known to work is ! \htmladdnormallinkfoot{UnZip}{http://www.info-zip.org/pub/infozip/UnZip.html}. Using your utility, unpack the \fn{.zip} archive, e.g. \begin{verbatim} ! unzip oommf11b1_20011002.zip \end{verbatim} For either distribution format, the unpacking sequence creates a *************** *** 166,181 **** here is the typical output on a Linux/Alpha system: \begin{verbatim} $ tclsh oommf.tcl +platform ! <24537> platform info: ! OOMMF release 1.1.1.0 Platform Name: linalp C++ compiler: /usr/bin/g++ Tcl configuration file: /usr/local/lib/tclConfig.sh tclsh: /usr/local/bin/tclsh8.3 ! Tcl release: 8.3.0 (config) 8.3.0 (running) Tk configuration file: /usr/local/lib/tkConfig.sh wish: /usr/local/bin/wish8.3 ! Tk release: 8.3.0 (config) 8.3.0 (running) \end{verbatim} If \cd{oommf.tcl +platform} doesn't print a summary like that, it --- 181,196 ---- here is the typical output on a Linux/Alpha system: \begin{verbatim} $ tclsh oommf.tcl +platform ! <24537> oommf.tcl 1.1.1.1 info: ! OOMMF release 1.1.1.1 Platform Name: linalp C++ compiler: /usr/bin/g++ Tcl configuration file: /usr/local/lib/tclConfig.sh tclsh: /usr/local/bin/tclsh8.3 ! Tcl release: 8.3.3 (config) 8.3.3 (running) Tk configuration file: /usr/local/lib/tkConfig.sh wish: /usr/local/bin/wish8.3 ! Tk release: 8.3.3 (config) 8.3.3 (running) \end{verbatim} If \cd{oommf.tcl +platform} doesn't print a summary like that, it *************** *** 276,281 **** --- 291,301 ---- and OOMMF\_WISH\index{environment~variables!OOMMF\_WISH} may be used to tell \OOMMF\ where to find the \Tk\ configuration file and the \fn{wish} program, respectively. + + Finally, the output of \cd{oommf.tcl +platform} may include warnings + about possible problems with your \Tcl/\Tk\ installation. For example, + if you are missing important header files, or if your \Tcl/\Tk\ installation + is thread-enabled (which \OOMMF\ does not support). If \cd{oommf.tcl +platform} indicates problems with your \Tcl/\Tk\ installation, it may be easiest to re-install \Tcl/\Tk\, taking care to perform a diff -crN oommf-1.1b0/doc/localmods.perl oommf/doc/localmods.perl *** oommf-1.1b0/doc/localmods.perl Wed Sep 15 14:27:19 1999 --- oommf/doc/localmods.perl Thu May 10 18:14:54 2001 *************** *** 26,31 **** --- 26,41 ---- "OOMMF Documentation Team
$myTODAY"; } + # Next three routines customize the navigation panels. + # l2h doesn't properly generate an HTML Table of Contents + # when processing the \tableofcontents LaTeX command, so + # we do special processing so that the Contents button + # links to the first (Top) page with all the links. + # + # The actual \tableofcontents is wrapped in \begin{latexonly} section. + # + # Because we don't use l2h's broken TOC generation, we have to copy + # the Contents icon into the HTML directory ourselves -- see makerules.tcl sub my_get_contents_page { # This routine returns the HTML page holding the LaTeX label # "page:contents", to be used to set a link to be used as a Contents *************** *** 43,51 **** local($border) = (length($NAV_BORDER) ? "BORDER=\"$NAV_BORDER\"" : ""); local($url) = ($LOCAL_ICONS ? "" : "$ICONSERVER/"); local($loi_img) = ! "\"Identifiers\""; local($lor_img) = ! "\"Refinements\""; $GLOSSARY = &add_special_link($glossary_visible_mark, $gls_file, $file) if ($styles_loaded{'lips'} && $INDEX_IN_NAVIGATION); --- 53,61 ---- local($border) = (length($NAV_BORDER) ? "BORDER=\"$NAV_BORDER\"" : ""); local($url) = ($LOCAL_ICONS ? "" : "$ICONSERVER/"); local($loi_img) = ! "\"Identifiers\""; local($lor_img) = ! "\"Refinements\""; $GLOSSARY = &add_special_link($glossary_visible_mark, $gls_file, $file) if ($styles_loaded{'lips'} && $INDEX_IN_NAVIGATION); *************** *** 56,62 **** # "My" contents page local($contents_img) = ! "\"contents\""; local($contents_page) = &my_get_contents_page ; local($mycontents) = &add_special_link($contents_img,$contents_page,$file); --- 66,72 ---- # "My" contents page local($contents_img) = ! "\"contents\""; local($contents_page) = &my_get_contents_page ; local($mycontents) = &add_special_link($contents_img,$contents_page,$file); *************** *** 88,94 **** # "My" contents page local($border) = (length($NAV_BORDER) ? "BORDER=\"$NAV_BORDER\"" : ""); ! local($contents_img) = "\"Contents\""; local($contents_page) = &my_get_contents_page ; local($mycontents) = &add_special_link($contents_img,$contents_page,$file); --- 98,104 ---- # "My" contents page local($border) = (length($NAV_BORDER) ? "BORDER=\"$NAV_BORDER\"" : ""); ! local($contents_img) = "\"Contents\""; local($contents_page) = &my_get_contents_page ; local($mycontents) = &add_special_link($contents_img,$contents_page,$file); diff -crN oommf-1.1b0/doc/makerules.tcl oommf/doc/makerules.tcl *** oommf-1.1b0/doc/makerules.tcl Thu Oct 28 18:59:20 1999 --- oommf/doc/makerules.tcl Thu May 10 18:14:54 2001 *************** *** 22,28 **** -dependencies userguide.dvi -script { Oc_Exec Foreground latex2html userguide.tex ! file copy -force contents_motif.gif userguide file copy -force oommficon.gif userguide } } --- 22,28 ---- -dependencies userguide.dvi -script { Oc_Exec Foreground latex2html userguide.tex ! file copy -force contents.gif userguide file copy -force oommficon.gif userguide } } *************** *** 88,93 **** MakeRule Define { -targets upgrade ! -script {DeleteFiles biblio.tex} } --- 88,93 ---- MakeRule Define { -targets upgrade ! -script {DeleteFiles biblio.tex contents_motif.gif} } diff -crN oommf-1.1b0/doc/mmgraph-body.tex oommf/doc/mmgraph-body.tex *** oommf-1.1b0/doc/mmgraph-body.tex Thu Mar 30 17:06:53 2000 --- oommf/doc/mmgraph-body.tex Sat Sep 29 14:24:58 2001 *************** *** 34,40 **** \ssechead{Inputs} Input to \app{mmGraph} may come from either a file in the \hyperrefhtml{\ODT\ format}{\ODT\ format ! (Sec.~}{)}{sec:odtformat}\index{file!odt}\index{file!data~table}, or, when \cd{-net 1} (the default) is active, from a client application (typically a running solver). The \btn{File\pipe Open\ldots} dialog box is used to select an input file. --- 34,40 ---- \ssechead{Inputs} Input to \app{mmGraph} may come from either a file in the \hyperrefhtml{\ODT\ format}{\ODT\ format ! (Sec.~}{)}{sec:odtformat}\index{file!data~table}, or, when \cd{-net 1} (the default) is active, from a client application (typically a running solver). The \btn{File\pipe Open\ldots} dialog box is used to select an input file. *************** *** 59,65 **** already exists, then {\bf mmGraph} output is appended to that file. The output is in the tabular \hyperrefhtml{\ODT\ format}{\ODT\ format described in ! Sec.~}{}{sec:odtformat}\index{file!odt}\index{file!data~table}. The data are segmented into separate \cd{Table Start/Table End} blocks across each curve break record. --- 59,65 ---- already exists, then {\bf mmGraph} output is appended to that file. The output is in the tabular \hyperrefhtml{\ODT\ format}{\ODT\ format described in ! Sec.~}{}{sec:odtformat}\index{file!data~table}. The data are segmented into separate \cd{Table Start/Table End} blocks across each curve break record. diff -crN oommf-1.1b0/doc/overview-body.tex oommf/doc/overview-body.tex *** oommf-1.1b0/doc/overview-body.tex Wed Dec 29 19:14:18 1999 --- oommf/doc/overview-body.tex Thu Jun 1 17:36:18 2000 *************** *** 12,30 **** documented, flexible programmer's interface so that people developing new code can swap their own code in and out as desired. The main contributors to \OOMMF\ are ! \htmladdnormallink{Mike Donahue}{http://math.nist.gov/mcsd/Staff/MDonahue} and ! \htmladdnormallink{Don Porter}{http://math.nist.gov/mcsd/Staff/DPorter}. In order to allow a programmer not familiar with the code as a whole to add modifications and new functionality, we feel that an object oriented approach is critical, and have settled on C++ as a good compromise with respect to availability, functionality, and portability. In order to allow the code to run on a wide variety of ! systems, we are writing the interface and glue code in ! \htmladdnormallinkfoot{\Tcl/\Tk}{http://www.scriptics.com/}. This enables ! our code to operate across a wide range of Unix platforms, \Windows~NT, ! and \Windows~95/98. The code may actually be modified at 3 distinct levels. At the top level, individual programs interact via well-defined protocols across --- 12,29 ---- documented, flexible programmer's interface so that people developing new code can swap their own code in and out as desired. The main contributors to \OOMMF\ are ! \htmladdnormallink{Mike Donahue}{http://math.nist.gov/\~{}MDonahue} and ! \htmladdnormallink{Don Porter}{http://math.nist.gov/\~{}DPorter}. In order to allow a programmer not familiar with the code as a whole to add modifications and new functionality, we feel that an object oriented approach is critical, and have settled on C++ as a good compromise with respect to availability, functionality, and portability. In order to allow the code to run on a wide variety of ! systems, we are writing the interface and glue code in \Tcl/\Tk. ! This enables our code to operate across a wide range of Unix platforms, ! \Windows~NT, and \Windows~95/98. The code may actually be modified at 3 distinct levels. At the top level, individual programs interact via well-defined protocols across *************** *** 51,57 **** (Sec.~}{)}{sec:obs}}. The solver is based on a micromagnetic code that ! \htmladdnormallink{Mike Donahue}{http://math.nist.gov/mcsd/Staff/MDonahue} and \htmladdnormallink{Bob McMichael}{mailto:rmcmichael@nist.gov} had previously developed. It utilizes a heavily damped Landau-Lifshitz --- 50,56 ---- (Sec.~}{)}{sec:obs}}. The solver is based on a micromagnetic code that ! \htmladdnormallink{Mike Donahue}{http://math.nist.gov/\~{}MDonahue} and \htmladdnormallink{Bob McMichael}{mailto:rmcmichael@nist.gov} had previously developed. It utilizes a heavily damped Landau-Lifshitz diff -crN oommf-1.1b0/doc/trouble-body.tex oommf/doc/trouble-body.tex *** oommf-1.1b0/doc/trouble-body.tex Wed Mar 29 20:02:41 2000 --- oommf/doc/trouble-body.tex Mon Aug 27 15:28:15 2001 *************** *** 46,51 **** --- 46,74 ---- as well as user packages. Other platforms are unlikely to have this problem. + \item When + \hyperrefhtml{compiling}{compiling + (Sec.~}{)}{sec:install.compile} + the file \fn{ext/oc/oc.cc}, there is an error + indicating that exceptions are not supported. + + Parts of \OOMMF\ are written in C++, and exceptions have been part + of the C++ langauge for many years. If your compiler does not + support them, it is time to upgrade to one that does. \OOMMF\ 1.2 + will require a compiler capable of compiling source code which uses + C++ exceptions. + + \OOMMF\ 1.1 provides a workaround to support those old compilers + incapable of compiling exceptions. Edit the configuration file + for your platform, \fn{config/cache/{\em platform}.tcl}. Add the + following line somewhere in the ADVANCED CONFIGURATION section + of that file: + \begin{quote} + \begin{verbatim} + $config SetValue program_compiler_c++_property_no_exceptions 1 + \end{verbatim} + \end{quote} + \item On Solaris, gcc reports many errors like \begin{quote} \cd{ANSI C++ forbids declaration `XSetTransientForHint' with no type} *************** *** 77,82 **** --- 100,113 ---- The file \fn{ext/net/omfExport.tcl} may be missing from your \OOMMF\ installation. If necessary, download and install \OOMMF\ again. + + \item I ran out of memory! + + Are you using \hyperrefhtml{\app{mmGraph}}{\app{mmGraph} + (Sec.~}{)}{sec:mmgraph}\index{application!mmGraph} to monitor + a long-running simulation? All data sent to \app{mmGraph} is + kept in memory by default. See the documentation for \app{mmGraph} + about how to manage this problem. \end{enumerate} diff -crN oommf-1.1b0/doc/userguide.tex oommf/doc/userguide.tex *** oommf-1.1b0/doc/userguide.tex Tue Apr 4 06:18:20 2000 --- oommf/doc/userguide.tex Mon Jun 12 16:31:21 2000 *************** *** 21,27 **** User's Guide\\[2ex] {\today} {}\\[2ex] ! This manual documents release 1.1b0.\\[1ex] %WARNING: In this beta release, the %documentation may not be up to date. --- 21,27 ---- User's Guide\\[2ex] {\today} {}\\[2ex] ! This manual documents release 1.1b1.\\[1ex] %WARNING: In this beta release, the %documentation may not be up to date. diff -crN oommf-1.1b0/ext/if/if.cc oommf/ext/if/if.cc *** oommf-1.1b0/ext/if/if.cc Tue Mar 21 15:42:21 2000 --- oommf/ext/if/if.cc Wed Oct 11 15:48:11 2000 *************** *** 9,15 **** * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 2000/03/21 20:42:21 $ * Last modified by: $Author: dgp $ */ --- 9,15 ---- * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 2000/10/11 19:48:11 $ * Last modified by: $Author: dgp $ */ *************** *** 397,402 **** --- 397,407 ---- pib.offset[0]=((unsigned char*)&pix[0].Red) - (unsigned char*)pix; pib.offset[1]=((unsigned char*)&pix[0].Green) - (unsigned char*)pix; pib.offset[2]=((unsigned char*)&pix[0].Blue) - (unsigned char*)pix; + #if (TK_MAJOR_VERSION > 8) \ + || ((TK_MAJOR_VERSION == 8) && (TK_MINOR_VERSION >= 3)) + // Jan Nijtmans recommends this safe way to disable alpha processing + pib.offset[3]=pib.offset[0]; + #endif // Skip unrequested leading rows Tcl_Seek(chan,OffBits+startrow*FileRowSize,SEEK_SET); *************** *** 477,483 **** bmpFileReadProc, // File read routine NULL, // String read routine NULL, // File write routine ! NULL // String write routine }; #endif --- 482,489 ---- bmpFileReadProc, // File read routine NULL, // String read routine NULL, // File write routine ! NULL, // String write routine ! NULL, // NULL nextPtr to be overwritten by Tk }; #endif diff -crN oommf-1.1b0/ext/if/version.h oommf/ext/if/version.h *** oommf-1.1b0/ext/if/version.h Fri Feb 18 00:44:25 2000 --- oommf/ext/if/version.h Thu Apr 27 16:37:48 2000 *************** *** 4,10 **** * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 2000/02/18 05:44:25 $ * Last modified by: $Author: dgp $ */ --- 4,10 ---- * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 2000/04/27 20:37:48 $ * Last modified by: $Author: dgp $ */ *************** *** 19,24 **** #define IF_MAJOR_VERSION 1 #define IF_MINOR_VERSION 1 #define IF_RELEASE_LEVEL 1 ! #define IF_RELEASE_SERIAL 0 #endif /* _IF_VERSION */ --- 19,24 ---- #define IF_MAJOR_VERSION 1 #define IF_MINOR_VERSION 1 #define IF_RELEASE_LEVEL 1 ! #define IF_RELEASE_SERIAL 1 #endif /* _IF_VERSION */ diff -crN oommf-1.1b0/ext/nb/errhandlers.cc oommf/ext/nb/errhandlers.cc *** oommf-1.1b0/ext/nb/errhandlers.cc Tue May 4 18:33:54 1999 --- oommf/ext/nb/errhandlers.cc Tue Oct 3 15:55:30 2000 *************** *** 5,12 **** * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 1999/05/04 22:33:54 $ ! * Last modified by: $Author: donahue $ */ #include // For va_list declarations --- 5,12 ---- * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 2000/10/03 19:55:30 $ ! * Last modified by: $Author: dgp $ */ #include // For va_list declarations *************** *** 27,37 **** const char* ErrBadParam = "Bad parameter"; const char* ErrDispInit = "Unable to initialize display"; const char* ErrMisc = "Miscellaneous error"; ! const char* ErrNoMem = "Insufficent working memory"; const char* ErrOverflow = "Arithmetic overflow"; const char* ErrProgramming = "Programming error"; ! #define BigBufSize 4096 static char ErrorBuf[BigBufSize]; // Error & warning messages storage --- 27,37 ---- const char* ErrBadParam = "Bad parameter"; const char* ErrDispInit = "Unable to initialize display"; const char* ErrMisc = "Miscellaneous error"; ! const char* ErrNoMem = "Insufficient working memory"; const char* ErrOverflow = "Arithmetic overflow"; const char* ErrProgramming = "Programming error"; ! #define BigBufSize 8192 static char ErrorBuf[BigBufSize]; // Error & warning messages storage *************** *** 41,47 **** { va_list arg_ptr; va_start(arg_ptr,fmt); ! vsprintf(ErrorBuf,fmt,arg_ptr); va_end(arg_ptr); msg.Append(ErrorBuf,sizeof(ErrorBuf)); return 0; --- 41,47 ---- { va_list arg_ptr; va_start(arg_ptr,fmt); ! Oc_Vsnprintf(ErrorBuf,sizeof(ErrorBuf),fmt,arg_ptr); va_end(arg_ptr); msg.Append(ErrorBuf,sizeof(ErrorBuf)); return 0; *************** *** 62,80 **** { va_list arg_ptr; char *cptr; ! sprintf(ErrorBuf, "Fatal error occurred in %s::%s (File %s, line %d)\n" "Class revision/date: %s/%s\n" "Class maintainer: %s\nERROR: ", class_doc.classname,membername,filename,lineno, class_doc.revision,class_doc.revdate, class_doc.maintainer); ! cptr=strchr(ErrorBuf,'\0'); // Note: Return type of sprintf is OS dependent va_start(arg_ptr,fmt); ! vsprintf(cptr,fmt,arg_ptr); va_end(arg_ptr); - ErrorBuf[sizeof(ErrorBuf)-1]='\0'; // A wee bit of safety TkMessage(MSG_ERROR,ErrorBuf,errorcode); // We shouldn't get to here, but just in case... --- 62,79 ---- { va_list arg_ptr; char *cptr; ! Oc_Snprintf(ErrorBuf,sizeof(ErrorBuf), "Fatal error occurred in %s::%s (File %s, line %d)\n" "Class revision/date: %s/%s\n" "Class maintainer: %s\nERROR: ", class_doc.classname,membername,filename,lineno, class_doc.revision,class_doc.revdate, class_doc.maintainer); ! cptr=strchr(ErrorBuf,'\0'); va_start(arg_ptr,fmt); ! Oc_Vsnprintf(cptr,sizeof(ErrorBuf)-(cptr-ErrorBuf),fmt,arg_ptr); va_end(arg_ptr); TkMessage(MSG_ERROR,ErrorBuf,errorcode); // We shouldn't get to here, but just in case... *************** *** 86,95 **** { va_list arg_ptr; va_start(arg_ptr,fmt); ! vsprintf(ErrorBuf,fmt,arg_ptr); va_end(arg_ptr); - ErrorBuf[sizeof(ErrorBuf)-1]='\0'; // A wee bit of safety TkMessage(MSG_ERROR,ErrorBuf,errorcode); // We shouldn't get to here, but just in case... --- 85,93 ---- { va_list arg_ptr; va_start(arg_ptr,fmt); ! Oc_Vsnprintf(ErrorBuf,sizeof(ErrorBuf),fmt,arg_ptr); va_end(arg_ptr); TkMessage(MSG_ERROR,ErrorBuf,errorcode); // We shouldn't get to here, but just in case... *************** *** 105,123 **** { va_list arg_ptr; char *cptr; ! sprintf(ErrorBuf, "Nonfatal error occurred in %s::%s (File %s, line %d)\n" "Class revision/date: %s/%s\n" "Class maintainer: %s\nWARNING: ", class_doc.classname,membername,filename,lineno, class_doc.revision,class_doc.revdate, class_doc.maintainer); ! cptr=strchr(ErrorBuf,'\0'); // Note: Return type of sprintf is OS dependent va_start(arg_ptr,fmt); ! vsprintf(cptr,fmt,arg_ptr); va_end(arg_ptr); - ErrorBuf[sizeof(ErrorBuf)-1]='\0'; // A wee bit of safety TkMessage(MSG_WARNING,ErrorBuf,0); } --- 103,120 ---- { va_list arg_ptr; char *cptr; ! Oc_Snprintf(ErrorBuf,sizeof(ErrorBuf), "Nonfatal error occurred in %s::%s (File %s, line %d)\n" "Class revision/date: %s/%s\n" "Class maintainer: %s\nWARNING: ", class_doc.classname,membername,filename,lineno, class_doc.revision,class_doc.revdate, class_doc.maintainer); ! cptr=strchr(ErrorBuf,'\0'); va_start(arg_ptr,fmt); ! Oc_Vsnprintf(cptr,sizeof(ErrorBuf)-(cptr-ErrorBuf),fmt,arg_ptr); va_end(arg_ptr); TkMessage(MSG_WARNING,ErrorBuf,0); } *************** *** 129,147 **** { va_list arg_ptr; char *cptr; ! sprintf(ErrorBuf, "Message from %s::%s (File %s, line %d)\n" "Class revision/date: %s/%s\n" "Class maintainer: %s\n\n", class_doc.classname,membername,filename,lineno, class_doc.revision,class_doc.revdate, class_doc.maintainer); ! cptr=strchr(ErrorBuf,'\0'); // Note: Return type of sprintf is OS dependent va_start(arg_ptr,fmt); ! vsprintf(cptr,fmt,arg_ptr); va_end(arg_ptr); - ErrorBuf[sizeof(ErrorBuf)-1]='\0'; // A wee bit of safety TkMessage(MSG_INFO,ErrorBuf,0); } --- 126,143 ---- { va_list arg_ptr; char *cptr; ! Oc_Snprintf(ErrorBuf,sizeof(ErrorBuf), "Message from %s::%s (File %s, line %d)\n" "Class revision/date: %s/%s\n" "Class maintainer: %s\n\n", class_doc.classname,membername,filename,lineno, class_doc.revision,class_doc.revdate, class_doc.maintainer); ! cptr=strchr(ErrorBuf,'\0'); va_start(arg_ptr,fmt); ! Oc_Vsnprintf(cptr,sizeof(ErrorBuf)-(cptr-ErrorBuf),fmt,arg_ptr); va_end(arg_ptr); TkMessage(MSG_INFO,ErrorBuf,0); } *************** *** 152,170 **** { va_list arg_ptr; char *cptr; ! sprintf(ErrorBuf, "Debug info from %s::%s (File %s, line %d)\n" "Class revision/date: %s/%s\n" "Class maintainer: %s\n\n", class_doc.classname,membername,filename,lineno, class_doc.revision,class_doc.revdate, class_doc.maintainer); ! cptr=strchr(ErrorBuf,'\0'); // Note: Return type of sprintf is OS dependent va_start(arg_ptr,fmt); ! vsprintf(cptr,fmt,arg_ptr); va_end(arg_ptr); - ErrorBuf[sizeof(ErrorBuf)-1]='\0'; // A wee bit of safety TkMessage(MSG_DEBUG,ErrorBuf,0); } --- 148,165 ---- { va_list arg_ptr; char *cptr; ! Oc_Snprintf(ErrorBuf,sizeof(ErrorBuf), "Debug info from %s::%s (File %s, line %d)\n" "Class revision/date: %s/%s\n" "Class maintainer: %s\n\n", class_doc.classname,membername,filename,lineno, class_doc.revision,class_doc.revdate, class_doc.maintainer); ! cptr=strchr(ErrorBuf,'\0'); va_start(arg_ptr,fmt); ! Oc_Vsnprintf(cptr,sizeof(ErrorBuf)-(cptr-ErrorBuf),fmt,arg_ptr); va_end(arg_ptr); TkMessage(MSG_DEBUG,ErrorBuf,0); } *************** *** 173,182 **** { va_list arg_ptr; va_start(arg_ptr,fmt); ! vsprintf(ErrorBuf,fmt,arg_ptr); va_end(arg_ptr); - ErrorBuf[sizeof(ErrorBuf)-1]='\0'; // A wee bit of safety TkMessage(MSG_WARNING,ErrorBuf,0); } --- 168,176 ---- { va_list arg_ptr; va_start(arg_ptr,fmt); ! Oc_Vsnprintf(ErrorBuf,sizeof(ErrorBuf),fmt,arg_ptr); va_end(arg_ptr); TkMessage(MSG_WARNING,ErrorBuf,0); } *************** *** 185,194 **** { va_list arg_ptr; va_start(arg_ptr,fmt); ! vsprintf(ErrorBuf,fmt,arg_ptr); va_end(arg_ptr); - ErrorBuf[sizeof(ErrorBuf)-1]='\0'; // A wee bit of safety return TkMessage(MSG_INFO,ErrorBuf,0); } --- 179,187 ---- { va_list arg_ptr; va_start(arg_ptr,fmt); ! Oc_Vsnprintf(ErrorBuf,sizeof(ErrorBuf),fmt,arg_ptr); va_end(arg_ptr); return TkMessage(MSG_INFO,ErrorBuf,0); } *************** *** 199,217 **** switch(mt) { case MSG_DEBUG: ! sprintf(buf,"Oc_Log Log {%s} debug",msg); break; case MSG_INFO: ! sprintf(buf,"Oc_Log Log {%s} info",msg); break; case MSG_WARNING: ! sprintf(buf,"Oc_Log Log {%s} warning",msg); break; case MSG_ERROR: ! sprintf(buf,"Oc_Log Log {%s} panic",msg); break; default: ! sprintf(buf,"Oc_Log Log {Unknown MessageType (%d) detected" " in TkMessage(); Associated message: %s} panic", int(mt),msg); break; --- 192,210 ---- switch(mt) { case MSG_DEBUG: ! Oc_Snprintf(buf,sizeof(buf),"Oc_Log Log {%s} debug",msg); break; case MSG_INFO: ! Oc_Snprintf(buf,sizeof(buf),"Oc_Log Log {%s} info",msg); break; case MSG_WARNING: ! Oc_Snprintf(buf,sizeof(buf),"Oc_Log Log {%s} warning",msg); break; case MSG_ERROR: ! Oc_Snprintf(buf,sizeof(buf),"Oc_Log Log {%s} panic",msg); break; default: ! Oc_Snprintf(buf,sizeof(buf),"Oc_Log Log {Unknown MessageType (%d) detected" " in TkMessage(); Associated message: %s} panic", int(mt),msg); break; diff -crN oommf-1.1b0/ext/nb/functions.cc oommf/ext/nb/functions.cc *** oommf-1.1b0/ext/nb/functions.cc Mon Jan 24 18:02:43 2000 --- oommf/ext/nb/functions.cc Tue Oct 3 15:55:30 2000 *************** *** 4,11 **** * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 2000/01/24 23:02:43 $ ! * Last modified by: $Author: donahue $ */ #include --- 4,11 ---- * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 2000/10/03 19:55:30 $ ! * Last modified by: $Author: dgp $ */ #include *************** *** 33,40 **** char buf[1024]; Tcl_ResetResult(interp); if(argc!=3) { ! sprintf(buf,"Nb_Gcd must be called with 2 arguments, m and n" ! " (%d arguments passed)",argc-1); Tcl_AppendResult(interp,buf,(char *)NULL); return TCL_ERROR; } --- 33,40 ---- char buf[1024]; Tcl_ResetResult(interp); if(argc!=3) { ! Oc_Snprintf(buf,sizeof(buf),"Nb_Gcd must be called with 2 arguments," ! " m and n (%d arguments passed)",argc-1); Tcl_AppendResult(interp,buf,(char *)NULL); return TCL_ERROR; } *************** *** 42,54 **** int m=atoi(argv[2]); if(m<1 || n<1) { ! sprintf(buf,"Nb_Gcd input must be two positive integers (got %d, %d)", ! n,m); Tcl_AppendResult(interp,buf,(char *)NULL); return TCL_ERROR; } ! sprintf(buf,"%d",Nb_Gcd(m,n)); Tcl_AppendResult(interp,buf,(char *)NULL); return TCL_OK; } --- 42,54 ---- int m=atoi(argv[2]); if(m<1 || n<1) { ! Oc_Snprintf(buf,sizeof(buf),"Nb_Gcd input must be two positive integers" ! " (got %d, %d)", n,m); Tcl_AppendResult(interp,buf,(char *)NULL); return TCL_ERROR; } ! Oc_Snprintf(buf,sizeof(buf),"%d",Nb_Gcd(m,n)); Tcl_AppendResult(interp,buf,(char *)NULL); return TCL_OK; } *************** *** 104,111 **** char buf[1024]; Tcl_ResetResult(interp); if(argc!=3) { ! sprintf(buf,"Nb_RatApprox must be called with 2 arguments, x and steps" ! " (%d arguments passed)",argc-1); Tcl_AppendResult(interp,buf,(char *)NULL); return TCL_ERROR; } --- 104,111 ---- char buf[1024]; Tcl_ResetResult(interp); if(argc!=3) { ! Oc_Snprintf(buf,sizeof(buf),"Nb_RatApprox must be called with 2 arguments," ! " x and steps (%d arguments passed)",argc-1); Tcl_AppendResult(interp,buf,(char *)NULL); return TCL_ERROR; } *************** *** 115,121 **** int num,denom; Nb_RatApprox(x,steps,num,denom); ! sprintf(buf,"%d %d",num,denom); Tcl_AppendResult(interp,buf,(char *)NULL); return TCL_OK; } --- 115,121 ---- int num,denom; Nb_RatApprox(x,steps,num,denom); ! Oc_Snprintf(buf,sizeof(buf),"%d %d",num,denom); Tcl_AppendResult(interp,buf,(char *)NULL); return TCL_OK; } *************** *** 147,153 **** // temporary storage just large enough to hold the string. The // latter is a performance hit, so if it happens frequently one // should enlarge the size of statbuf. ! int exp_off=cptr-nptr; static char statbuf[256]; // I don't expect many numeric strings this long char *buf=statbuf; size_t num_len=strlen(nptr)+1; --- 147,153 ---- // temporary storage just large enough to hold the string. The // latter is a performance hit, so if it happens frequently one // should enlarge the size of statbuf. ! size_t exp_off=cptr-nptr; static char statbuf[256]; // I don't expect many numeric strings this long char *buf=statbuf; size_t num_len=strlen(nptr)+1; *************** *** 159,164 **** --- 159,196 ---- if(buf!=statbuf) delete[] buf; return result; + } + + ////////////////////////////////////////////////////////////////////////// + // Routines to detect IEEE floating point NAN's and infinities. + int Nb_IsFinite(REAL4 x) + { + // Inf's and nan's are indicated by all exponent bits (8) being set. + // The top bit is the sign bit. + unsigned char *cptr = (unsigned char *)(&x); + #if (BYTEORDER == 4321) // Little endian + unsigned int code = (((unsigned int)cptr[3])<<8) + ((unsigned int)cptr[2]); + #else // Otherwise assume big endian + unsigned int code = (((unsigned int)cptr[0])<<8) + ((unsigned int)cptr[1]); + #endif + unsigned mask = 0x7F80; + code &= mask; + return (code!=mask); + } + + int Nb_IsFinite(REAL8 x) + { + // Inf's and nan's are indicated by all exponent bits (11) being set. + // The top bit is the sign bit. + unsigned char *cptr = (unsigned char *)(&x); + #if (BYTEORDER == 4321) // Little endian + unsigned int code = (((unsigned int)cptr[7])<<8) + ((unsigned int)cptr[6]); + #else // Otherwise assume big endian + unsigned int code = (((unsigned int)cptr[0])<<8) + ((unsigned int)cptr[1]); + #endif + unsigned mask = 0x7FF0; + code &= mask; + return (code!=mask); } ////////////////////////////////////////////////////////////////////////// diff -crN oommf-1.1b0/ext/nb/functions.h oommf/ext/nb/functions.h *** oommf-1.1b0/ext/nb/functions.h Mon Jan 24 18:02:43 2000 --- oommf/ext/nb/functions.h Tue Oct 3 15:55:30 2000 *************** *** 4,11 **** * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 2000/01/24 23:02:43 $ ! * Last modified by: $Author: donahue $ */ #ifndef _NB_FUNCTIONS --- 4,11 ---- * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 2000/10/03 19:55:30 $ ! * Last modified by: $Author: dgp $ */ #ifndef _NB_FUNCTIONS *************** *** 29,34 **** --- 29,38 ---- // Portable case insensitive string comparison, modeled after // BSD's strcasecmp(). int Nb_StrCaseCmp(const char *s1, const char *s2); + + // Routines to detect IEEE floating point NAN's and infinities. + int Nb_IsFinite(REAL4 x); + int Nb_IsFinite(REAL8 x); // C interface to the Tcl 'file nativename' functionality. void Nb_TclNativeFilename(Tcl_Interp* interp,Nb_DString &filename); diff -crN oommf-1.1b0/ext/nb/version.h oommf/ext/nb/version.h *** oommf-1.1b0/ext/nb/version.h Fri Feb 18 00:44:25 2000 --- oommf/ext/nb/version.h Thu Apr 27 16:37:48 2000 *************** *** 4,10 **** * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 2000/02/18 05:44:25 $ * Last modified by: $Author: dgp $ */ --- 4,10 ---- * * NOTICE: Please see the file ../../LICENSE * ! * Last modified on: $Date: 2000/04/27 20:37:48 $ * Last modified by: $Author: dgp $ */ *************** *** 19,24 **** #define NB_MAJOR_VERSION 1 #define NB_MINOR_VERSION 1 #define NB_RELEASE_LEVEL 1 ! #define NB_RELEASE_SERIAL 0 #endif /* _NB_VERSION */ --- 19,24 ---- #define NB_MAJOR_VERSION 1 #define NB_MINOR_VERSION 1 #define NB_RELEASE_LEVEL 1 ! #define NB_RELEASE_SERIAL 1 #endif /* _NB_VERSION */ diff -crN oommf-1.1b0/ext/net/account.tcl oommf/ext/net/account.tcl *** oommf-1.1b0/ext/net/account.tcl Fri Mar 24 19:23:17 2000 --- oommf/ext/net/account.tcl Mon Oct 16 17:35:28 2000 *************** *** 246,259 **** catch {unset connection} $this DeregisterBadAccount "Can't create connection:\n$msg" } else { ! Oc_EventHandler New _ $connection Delete [list $this Delete] \ ! -oneshot 1 -groups [list $this] Oc_EventHandler New _ $connection Ready \ ! [list $this ConnectionReady] -oneshot 1 -groups [list $this] } } ! method ConnectionReady {} { Oc_EventHandler New _ $connection Readable \ [list $this VerifyOOMMFAccount] -oneshot 1 -groups [list $this] } --- 246,269 ---- catch {unset connection} $this DeregisterBadAccount "Can't create connection:\n$msg" } else { ! # Using [socket -async], it's possible that we haven't really ! # yet established a valid connection. So, until the connection ! # is "Ready", handle all Net_Connection destruction as though ! # caused by failure to connect. ! set h [Oc_EventHandler New _ $connection Delete \ ! [list $this DeregisterBadAccount \ ! "Connection to $hostname:$port failed"] \ ! -oneshot 1 -groups [list $this]] Oc_EventHandler New _ $connection Ready \ ! [list $this ConnectionReady $h] -oneshot 1 \ ! -groups [list $this] } } ! method ConnectionReady {handler} { ! $handler Delete ! Oc_EventHandler New _ $connection Delete [list $this Delete] \ ! -oneshot 1 -groups [list $this] Oc_EventHandler New _ $connection Readable \ [list $this VerifyOOMMFAccount] -oneshot 1 -groups [list $this] } diff -crN oommf-1.1b0/ext/net/link.tcl oommf/ext/net/link.tcl *** oommf-1.1b0/ext/net/link.tcl Mon Dec 6 17:17:25 1999 --- oommf/ext/net/link.tcl Fri May 5 16:19:34 2000 *************** *** 47,54 **** global tcl_platform if {[string match windows $tcl_platform(platform)] && [package vcompare [package provide Tcl] 8.0] <= 0} { ! global tcl_patchLevel ! if {[string compare 8.0.5 $tcl_patchLevel]} { # socket -async is broken. Do blocking open if {[catch {socket $hostname $port} msg]} { set msg "Can't connect to $hostname:$port:\n\t$msg" --- 47,59 ---- global tcl_platform if {[string match windows $tcl_platform(platform)] && [package vcompare [package provide Tcl] 8.0] <= 0} { ! ! # On Tcl for Alpha Windows NT platforms, [socket -async] appears to still ! # be broken in release 8.0.5. Rather than get in the business of tracking ! # machine dependencies, we'll assume use of [socket -async] needs to wait ! # until at least release 8.1 of Tcl. ! # global tcl_patchLevel ! # if {[string compare 8.0.5 $tcl_patchLevel]} { # socket -async is broken. Do blocking open if {[catch {socket $hostname $port} msg]} { set msg "Can't connect to $hostname:$port:\n\t$msg" *************** *** 57,63 **** set socket $msg after 0 $this ConfigureSocket return ! } } if {[catch {socket -async $hostname $port} msg]} { set msg "Can't connect to $hostname:$port:\n\t$msg" --- 62,68 ---- set socket $msg after 0 $this ConfigureSocket return ! # } } if {[catch {socket -async $hostname $port} msg]} { set msg "Can't connect to $hostname:$port:\n\t$msg" diff -crN oommf-1.1b0/ext/net/net.tcl oommf/ext/net/net.tcl *** oommf-1.1b0/ext/net/net.tcl Tue Mar 21 15:42:21 2000 --- oommf/ext/net/net.tcl Mon May 15 16:10:27 2000 *************** *** 5,11 **** # This extension provides a set of Oc_Classes which support networking # operations. # ! # Last modified on: $Date: 2000/03/21 20:42:21 $ # Last modified by: $Author: dgp $ # # When this version of the Net extension is selected by the 'package require' --- 5,11 ---- # This extension provides a set of Oc_Classes which support networking # operations. # ! # Last modified on: $Date: 2000/05/15 20:10:27 $ # Last modified by: $Author: dgp $ # # When this version of the Net extension is selected by the 'package require' *************** *** 20,26 **** Oc_CheckTclIndex Net # CVS ! package provide Net 1.1.1.0 # Set up for autoloading of Net extension commands set _net(library) [file dirname [info script]] --- 20,26 ---- Oc_CheckTclIndex Net # CVS ! package provide Net 1.1.1.1 # Set up for autoloading of Net extension commands set _net(library) [file dirname [info script]] *************** *** 31,36 **** # Load in any local modifications set local [file join [file dirname [info script]] local net.tcl] if {[file isfile $local] && [file readable $local]} { ! uplevel #0 source [list $local] } --- 31,36 ---- # Load in any local modifications set local [file join [file dirname [info script]] local net.tcl] if {[file isfile $local] && [file readable $local]} { ! uplevel #0 [list source $local] } diff -crN oommf-1.1b0/ext/net/pkgIndex.tcl oommf/ext/net/pkgIndex.tcl *** oommf-1.1b0/ext/net/pkgIndex.tcl Fri Feb 18 11:20:51 2000 --- oommf/ext/net/pkgIndex.tcl Mon May 15 16:10:27 2000 *************** *** 1,3 **** # FILE: pkgIndex.tcl # ! package ifneeded Net 1.1.1.0 [list uplevel #0 source [list [file join $dir net.tcl]]] --- 1,3 ---- # FILE: pkgIndex.tcl # ! package ifneeded Net 1.1.1.1 [list uplevel #0 [list source [file join $dir net.tcl]]] diff -crN oommf-1.1b0/ext/net/threadGui.tcl oommf/ext/net/threadGui.tcl *** oommf-1.1b0/ext/net/threadGui.tcl Thu Jul 29 13:15:13 1999 --- oommf/ext/net/threadGui.tcl Mon Jul 31 15:44:33 2000 *************** *** 1,10 **** # FILE: threadGui.tcl # Oc_Class Net_ThreadGui { const public variable winpath ! const public variable outer_frame_options = "-bd 4 -relief ridge" ! public variable thread private variable inputs private variable ctrl private variable cmdbtns --- 1,11 ---- # FILE: threadGui.tcl # + package require Tk + package require Ow Oc_Class Net_ThreadGui { const public variable winpath ! const public variable thread private variable inputs private variable ctrl private variable cmdbtns *************** *** 22,28 **** private array variable button = {} private variable status = "Status: " Constructor {args} { - package require Ow eval $this Configure -winpath .w$this $args toplevel $winpath wm group $winpath --- 23,28 ---- diff -crN oommf-1.1b0/ext/net/threads/account.tcl oommf/ext/net/threads/account.tcl *** oommf-1.1b0/ext/net/threads/account.tcl Fri Feb 25 13:39:02 2000 --- oommf/ext/net/threads/account.tcl Mon Nov 13 12:21:46 2000 *************** *** 35,44 **** # Try to keep going, even if controlling terminal goes down. Oc_IgnoreTermLoss - # Default timeout = 15 minutes * 1000 ~= a week - set master(timeout) 900000000 - Oc_Option Get Demon timeout master(timeout) - # Init portmap array set portmap {} --- 35,40 ---- *************** *** 115,121 **** return [list start [list 1 $thread not registered]] } $master(protocol) AddMessage start register {thread alias port} { ! global portmap expire_event master if {[info exists portmap($thread)]} { set existingport [lindex $portmap($thread) 1] if {[string match {} $existingport]} { --- 111,117 ---- return [list start [list 1 $thread not registered]] } $master(protocol) AddMessage start register {thread alias port} { ! global portmap if {[info exists portmap($thread)]} { set existingport [lindex $portmap($thread) 1] if {[string match {} $existingport]} { *************** *** 129,138 **** set ret [list start [list 0 [array set portmap [list $thread \ [list $alias $port $connection]]]]] } - if {[info exists expire_event] && [array size portmap]} { - after cancel $expire_event - unset expire_event - } Oc_EventHandler Generate Oc_Main NewThread -id $thread Oc_Log Log "portmap: [array get portmap]" status return $ret --- 125,130 ---- *************** *** 140,146 **** $master(protocol) AddMessage start deregister { thread port } { # Ought to call back for security -- and that will require # event-driven query-handling. ! global portmap expire_event master if {![info exists portmap($thread)]} { return [list start [list 1 $thread not registered]] } --- 132,138 ---- $master(protocol) AddMessage start deregister { thread port } { # Ought to call back for security -- and that will require # event-driven query-handling. ! global portmap if {![info exists portmap($thread)]} { return [list start [list 1 $thread not registered]] } *************** *** 148,158 **** return [list start [list 1 permission denied]] } set ret [list start [list 0 [unset portmap($thread)]]] - if {![array size portmap] && $master(timeout) - && ![info exists expire_event]} { - set expire_event [after $master(timeout) [list FatalError \ - "OOMMF account server expired"]] - } Oc_Log Log "portmap: [array get portmap]" status return $ret } --- 140,145 ---- *************** *** 291,297 **** Oc_Log Log "Called back $port" status catch { puts $s ""} ;# Seems to help close port ## on other side. -mjd 981009 ! close $s } } } --- 278,287 ---- Oc_Log Log "Called back $port" status catch { puts $s ""} ;# Seems to help close port ## on other side. -mjd 981009 ! catch {close $s} msg ! if {[string length $msg]} { ! return -code error "close error: $msg" ! } } } } *************** *** 328,344 **** exit } proc Cleanup {} { ! global portmap expire_event master foreach thread [array names portmap] { if {[catch {[lindex $portmap($thread) 2] Class}]} { # Net_Connection is dead -- remove from portmap unset portmap($thread) } - } - if {![array size portmap] && $master(timeout) - && ![info exists expire_event]} { - set expire_event [after $master(timeout) \ - [list FatalError "OOMMF account server expired"]] } # Repeat Cleanup every 20 minutes after 1200000 Cleanup --- 318,329 ---- exit } proc Cleanup {} { ! global portmap foreach thread [array names portmap] { if {[catch {[lindex $portmap($thread) 2] Class}]} { # Net_Connection is dead -- remove from portmap unset portmap($thread) } } # Repeat Cleanup every 20 minutes after 1200000 Cleanup diff -crN oommf-1.1b0/ext/net/threads/host.tcl oommf/ext/net/threads/host.tcl *** oommf-1.1b0/ext/net/threads/host.tcl Fri Feb 25 13:39:02 2000 --- oommf/ext/net/threads/host.tcl Mon Nov 13 12:21:46 2000 *************** *** 35,50 **** # Try to keep going, even if controlling terminal goes down. Oc_IgnoreTermLoss ! # Default timeout = 15 minutes * 1000 ~= a week ! set master(timeout) 900000000 ! Oc_Option Get Demon timeout master(timeout) ! ! # After idle for timeout period after all accounts deregister, die. ! proc Expire {} { global master $master(server) Delete $master(protocol) Delete ! Oc_Log Log "OOMMF host server expired" status exit } --- 35,45 ---- # Try to keep going, even if controlling terminal goes down. Oc_IgnoreTermLoss ! proc Die {} { global master $master(server) Delete $master(protocol) Delete ! Oc_Log Log "OOMMF host server died" status exit } *************** *** 60,75 **** } } $master(protocol) AddMessage start register {acct port} { ! global portmap expire_event if {[info exists portmap($acct)]} { return [list start \ [list 1 $acct already registered at port $portmap($acct)]] } set ret [list start [list 0 [array set portmap [list $acct $port]]]] - if {[info exists expire_event] && [array size portmap]} { - after cancel $expire_event - unset expire_event - } return $ret } $master(protocol) AddMessage start deregister { acct port } { --- 55,66 ---- } } $master(protocol) AddMessage start register {acct port} { ! global portmap if {[info exists portmap($acct)]} { return [list start \ [list 1 $acct already registered at port $portmap($acct)]] } set ret [list start [list 0 [array set portmap [list $acct $port]]]] return $ret } $master(protocol) AddMessage start deregister { acct port } { *************** *** 78,84 **** # # If this request comes in from a remote machine, it should not # be trusted without checking. ! global portmap expire_event master if {![info exists portmap($acct)]} { return [list start [list 1 $acct not registered]] } --- 69,75 ---- # # If this request comes in from a remote machine, it should not # be trusted without checking. ! global portmap if {![info exists portmap($acct)]} { return [list start [list 1 $acct not registered]] } *************** *** 86,94 **** return [list start [list 1 permission denied]] } set ret [list start [list 0 [unset portmap($acct)]]] - if {![array size portmap] && $master(timeout)} { - set expire_event [after $master(timeout) Expire] - } return $ret } $master(protocol) AddMessage start bye {} { --- 77,82 ---- *************** *** 100,109 **** set serviceport [lindex $argv 0] set startError [catch {$master(server) Start $serviceport} master(msg)] - if {$master(timeout)} { - set expire_event [after $master(timeout) Expire] - } - if {$startError} { after 2000 } --- 88,93 ---- *************** *** 120,126 **** Oc_Log Log "Called back $port" status catch { puts $s ""} ;# Seems to help close port ## on other side. -mjd 981009 ! close $s } elseif {$startError} { Oc_Log Log "Can't start OOMMF host server on port\ $serviceport:\n\t$master(msg)." status --- 104,113 ---- Oc_Log Log "Called back $port" status catch { puts $s ""} ;# Seems to help close port ## on other side. -mjd 981009 ! catch {close $s} msg ! if {[string length $msg]} { ! return -code error "close error: $msg" ! } } elseif {$startError} { Oc_Log Log "Can't start OOMMF host server on port\ $serviceport:\n\t$master(msg)." status *************** *** 137,143 **** # A Net_Connection is being destroyed. If it's the last one, # schedule our suicide if {[llength [Net_Connection Instances]] == 1} { ! after idle Expire } } --- 124,130 ---- # A Net_Connection is being destroyed. If it's the last one, # schedule our suicide if {[llength [Net_Connection Instances]] == 1} { ! after idle Die } } diff -crN oommf-1.1b0/ext/oc/bug.tcl oommf/ext/oc/bug.tcl *** oommf-1.1b0/ext/oc/bug.tcl Thu Jul 29 16:27:59 1999 --- oommf/ext/oc/bug.tcl Wed Jul 26 14:45:00 2000 *************** *** 2,8 **** # # Patches for all Tcl/Tk versions # ! # Last modified on: $Date: 1999/07/29 20:27:59 $ # Last modified by: $Author: dgp $ # # This file contains Tcl code which patches or enhances the commands of --- 2,8 ---- # # Patches for all Tcl/Tk versions # ! # Last modified on: $Date: 2000/07/26 18:45:00 $ # Last modified by: $Author: dgp $ # # This file contains Tcl code which patches or enhances the commands of *************** *** 36,43 **** # Starting in Tcl8.1, auto_mkindex has to be auto-loaded. catch {auto_mkindex} if {[llength [info commands auto_mkindex_old]]} { ! rename auto_mkindex {} ! rename auto_mkindex_old auto_mkindex } # Report that bug patches are done. --- 36,42 ---- # Starting in Tcl8.1, auto_mkindex has to be auto-loaded. catch {auto_mkindex} if {[llength [info commands auto_mkindex_old]]} { ! interp alias {} auto_mkindex {} auto_mkindex_old } # Report that bug patches are done. diff -crN oommf-1.1b0/ext/oc/bug75.tcl oommf/ext/oc/bug75.tcl *** oommf-1.1b0/ext/oc/bug75.tcl Fri Aug 20 10:00:09 1999 --- oommf/ext/oc/bug75.tcl Thu Jun 28 18:27:50 2001 *************** *** 2,8 **** # # Patches for Tcl 7.5 / Tk 4.1 # ! # Last modified on: $Date: 1999/08/20 14:00:09 $ # Last modified by: $Author: dgp $ # # This file contains Tcl code which when sourced in a Tcl 7.5 interpreter --- 2,8 ---- # # Patches for Tcl 7.5 / Tk 4.1 # ! # Last modified on: $Date: 2001/06/28 22:27:50 $ # Last modified by: $Author: dgp $ # # This file contains Tcl code which when sourced in a Tcl 7.5 interpreter *************** *** 22,58 **** # needed. rename file Tcl7.5_file proc file {option args} { ! switch -exact -- $option { ! c - ! co - ! cop - ! copy { # Translate -force into -f if {[string match -force [lindex $args 0]]} { set args [lreplace $args 0 0 -f] } uplevel exec cp $args } ! de - ! del - ! dele - ! delet - ! delete { if {[string match -force [lindex $args 0]]} { set args [lreplace $args 0 0 -f] } catch {uplevel exec rm $args} } ! mk - ! mkd - ! mkdi - ! mkdir { uplevel exec mkdir $args } ! ren - ! rena - ! renam - ! rename { if {[string match -force [lindex $args 0]]} { set args [lreplace $args 0 0 -f] } --- 22,57 ---- # needed. rename file Tcl7.5_file proc file {option args} { ! switch -glob -- $option { ! c* { ! if {[string first $option copy] != 0} { ! return [uplevel [list Tcl7.5_file $option] $args] ! } # Translate -force into -f if {[string match -force [lindex $args 0]]} { set args [lreplace $args 0 0 -f] } uplevel exec cp $args } ! de* { ! if {[string first $option delete] != 0} { ! return [uplevel [list Tcl7.5_file $option] $args] ! } if {[string match -force [lindex $args 0]]} { set args [lreplace $args 0 0 -f] } catch {uplevel exec rm $args} } ! mk* { ! if {[string first $option mkdir] != 0} { ! return [uplevel [list Tcl7.5_file $option] $args] ! } uplevel exec mkdir $args } ! ren* { ! if {[string first $option rename] != 0} { ! return [uplevel [list Tcl7.5_file $option] $args] ! } if {[string match -force [lindex $args 0]]} { set args [lreplace $args 0 0 -f] } *************** *** 92,137 **** return "" } ! # The subcommands remove was added to the Tk command 'grid' in Tk ! # version 4.1. The option -pad was also added to the subcommands ! # columnconfigure and rowconfigure. The syntax of the bbox ! # subcommand also changed in a backward compatible way. ! # Also, [grid ...