/usr/share/savi/tcl/helpfile.tcl is in savi 1.5.1-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 | #
######################################################
#
# SaVi by Lloyd Wood (lloydwood@users.sourceforge.net),
# Patrick Worfolk (worfolk@alum.mit.edu) and
# Robert Thurman.
#
# Copyright (c) 1997 by The Geometry Center.
# Also Copyright (c) 2017 by Lloyd Wood.
#
# This file is part of SaVi. SaVi is free software;
# you can redistribute it and/or modify it only under
# the terms given in the file COPYRIGHT which you should
# have received along with this file. SaVi may be
# obtained from:
# http://savi.sourceforge.net/
# http://www.geom.uiuc.edu/locate/SaVi
#
######################################################
#
# textfile.tcl
# $Id: helpfile.tcl,v 1.22 2017/01/02 06:11:33 lloydwood Exp $
proc helpfile(build) {helpfile} {
global helpfile_name helpfile_text
if {[eval window(raise) helpfile]} {
helpfile(load) $helpfile
return
}
set name [build_Toplevel helpfile]
wm protocol $name WM_DELETE_WINDOW helpfile(dismiss)
build_Title $name "help"
build_DismissButtonbar $name dbbar helpfile(dismiss) \
{"Introduction" "helpfile(build) README"} \
{"Bugs" "helpfile(build) BUGS"} \
{"Texturemapping" "helpfile(build) README-COVERAGE-TEXTUREMAP"} \
{"Copyright" "helpfile(build) COPYRIGHT"}
set cmd [build_CmdFrame $name cmd]
build_Label $cmd on "Help from $helpfile_name"
set helpfile_name $cmd.on
$helpfile_name.label configure -font *-times-medium-i-normal--*-140-*-*-*-*-*-* \
-fg blue
set helpfile_text [build_Scrollingtext $cmd text 60 25]
$helpfile_text configure -font *-courier-i-normal--*-12-*-*-*-*-*-* \
helpfile(load) $helpfile
pack $cmd.text -side left -anchor w -ipadx 15m -ipady 2m
pack $cmd -anchor w -expand 1 -fill both
}
proc helpfile(dismiss) {} {
destroy .helpfile
}
proc helpfile(load) {helpfile} {
global helpfile_name helpfile_text
set helpfile_file $helpfile
if {[string compare "" $helpfile] == 0} {
# special case starting SaVi without a constellation loaded.
set file_text "\nThis is a simple low-Earth-orbiting equatorial example satellite."
} elseif {![file exists $helpfile]} {
set file_text "\nThe $helpfile textfile is not available to SaVi.\n\n$helpfile may have been removed or moved. SaVi may have been packaged incorrectly by a third party.\n\nPlease install the full version of SaVi, which includes $helpfile, from: http://savi.sf.net/"
} else {
set f [open "$helpfile" r]
set file_text ""
while {[gets $f line] >= 0} {
if {[string index $line 0] != "$"} {
set file_text "$file_text\n$line "
}
}
close $f
}
$helpfile_name.label configure -text "Help from $helpfile"
$helpfile_text delete 1.0 end
$helpfile_text insert end $file_text
}
|