home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World 1998 October
/
PCWorld_1998-10_cd.bin
/
software
/
prehled
/
komix
/
DATA.Z
/
diagramsec.tcl
< prev
next >
Wrap
Text File
|
1997-10-14
|
3KB
|
104 lines
#---------------------------------------------------------------------------
#
# (c) Cayenne Software Inc. 1996
#
# File: @(#)diagramsec.tcl /main/titanic/4
# Author: <generated>
# Description:
#---------------------------------------------------------------------------
# SccsId = @(#)diagramsec.tcl /main/titanic/4 14 Oct 1997 Copyright 1996 Cayenne Software Inc.
# Start user added include file section
# End user added include file section
require_module_file "filerefsec.tcl" docwriter
Class DiagramSection : {FileRefSection} {
constructor
method destructor
method promoter
method print
method preview
method updateDocDir
method docType
}
constructor DiagramSection {class this name document} {
set this [FileRefSection::constructor $class $this $name $document]
# Start constructor user section
# End constructor user section
return $this
}
method DiagramSection::destructor {this} {
# Start destructor user section
# End destructor user section
$this FileRefSection::destructor
}
method DiagramSection::promoter {this} {
$this operationClass import
}
method DiagramSection::print {this} {
# print the converted one
set cmd [list \
"[m4_var get M4_ps_printer] [$this docLocation]" \
[$this uiName] \
]
$this execute "$cmd"
}
method DiagramSection::preview {this} {
# preview the converted one
set cmd [list \
"previewer [$this docType]Section" \
[$this docLocation] \
[$this uiName] \
]
$this execute "$cmd" m4
}
method DiagramSection::updateDocDir {this} {
set fileV [$this referredFileVersion]
if [$fileV isNil] {
return 1
}
# start Print::exportDiagram for this section and put the output
# file in docLocation (in [$this docType] format)
set fid [open [$this docLocation] w]
close $fid
set confV [[$this document] configVersion]
set sysV [[$this referredSystem] selectedVersion $confV]
require "print.tcl"
if [catch {Print::exportDiagram \
-file [$this docLocation] \
-type [string toupper [$this docType]] \
-configVersion $confV \
-systemVersion $sysV \
-orientation portrait \
-autoScale 1 \
-pageWidth 6.0625\
-pageHeight 7.0625\
$fileV} reason] {
wmtkerror "Export diagram failed: $reason"
return 0
}
return 1
}
method DiagramSection::docType {this} {
# the type of this section in the document directory is Epsi
return Epsi
}
# Do not delete this line -- regeneration end marker