T.R | Title | User | Personal Name | Date | Lines |
---|
1270.1 | May need any special icons as well. | BSYBEE::EGOLF | John C. Egolf LKG2-2/T02 x226-7874 | Fri Jul 19 1991 15:42 | 7 |
| If the maps sent to you use any "non-standard" icons or
re-defined icons, they would have to be sent as well, right?
The map file indicated the name of the icon used, not the
actual bitmap.
JCE
|
1270.2 | | TOOK::F_MESSINGER | | Fri Jul 19 1991 16:24 | 4 |
|
...Right.
Fred
|
1270.3 | If needed I'll ask for them. | CLARID::HOFSTEE | Take a RISC, buy a VAX | Mon Jul 22 1991 04:50 | 22 |
|
> If the maps sent to you use any "non-standard" icons or
> re-defined icons, they would have to be sent as well, right?
Yep. Now since the utility is supposed to run on the system where the map
was created, all icons normally should be there. However for test purposes
I would indeed need the 'special' icon files.
At the moment , what I intend to do if I cannot find the iconfile or if
the icon_file label is missing, is to print some predefined 'unknown'
symbol. Maybe Fred can send me the symbol he is using in such a case.
> The map file indicated the name of the icon used, not the
> actual bitmap.
What do you mean exactly with this? As far as I know, the icon_file LABEL
in the map file *.MCC_MAP_Whatever should always point to a file in mcc_icons
that contains a description (in some way) of the bitmap to be used for the
icon.
|
1270.4 | | TOOK::F_MESSINGER | | Mon Jul 22 1991 10:36 | 9 |
|
As far as I know, the icon_file LABEL
in the map file *.MCC_MAP_Whatever should always point to a file in mcc_icons
that contains a description (in some way) of the bitmap to be used for the
icon.
>> Correct. I'll send the "unknown" icon via mail.
Fred
|
1270.5 | test results? | TOOK::CALLANDER | Jill Callander DTN 226-5316 | Wed Jul 24 1991 18:40 | 3 |
| so how were your test results? could you post a pointer to your print
application?
|
1270.6 | basically working. Still some testing to do | CLARID::HOFSTEE | Take a RISC, buy a VAX | Thu Jul 25 1991 05:18 | 19 |
|
I have been able to produce a postscript file for all maps that have been send
to me. Thanks to all.
So basically the utility is working. However, I still have to do some testing.
I still have to code in some qualifiers and do some testing with very large
maps. (Thanks John). Than I have to write some doc. As an example a will
post in the next reply a map of the "BAHTAT_CLUSTER" that was send to me
by BAHTAT::BOND. Notice that some icons are replaced with question marks,
since the icon files that are used in this map (MCC_DOMAIN_PHONE_ICON.DAT and
MCC_DOMAIN_CHIPCOM_ICON.DAT) are not on my system. However, when the utility is
run on the system where the map is created it should come out with the right
icons.
It'll probably take another week or two before I can release the first version.
Timo
|
1270.7 | mcc_graph example. extr/nohead and print | CLARID::HOFSTEE | Take a RISC, buy a VAX | Thu Jul 25 1991 05:23 | 325 |
| %!Ps
/inch {72 mul} def % converts postscript units to inch
/leftmargin 0.5 inch def % sets leftmargin
/botmargin 0.25 inch def % sets bottom margin
/shadeback
{
newpath
0 0 moveto % draw the area to be shaded
0 pageheight rlineto
pagewidth 0 rlineto
0 pageheight neg rlineto
closepath
gsave
0.8 setgray % set shading factor
fill % and fill the page
grestore
}def
/straightline
{
newpath
moveto
lineto
setlinewidth
stroke
}def
/text
{
moveto
/Helvetica-Bold findfont 15 scalefont setfont
show
}def
/icon
{
newpath
/sub_name exch def
/icon_h exch def
/icon_w exch def
/icon_y exch def
/icon_x exch def
gsave
icon_x icon_y translate
icon_w icon_h scale
icon_w icon_h 1 [icon_w 0 0 icon_h neg 0 icon_h] {sub_name cvx exec} image
grestore
}def
/drawverticalline
{
/x exch def
newpath
0.1 setlinewidth
x 0 moveto
0 pageheight rlineto
stroke
}def
/drawhorizontalline
{
/y exch def
newpath
0.1 setlinewidth
0 y moveto
pagewidth 0 rlineto
stroke
}def
/setclipping
{
newpath
leftmargin botmargin moveto % goto (leftmargin,botmargin)
0 pageheight rlineto % draw rectangle made up by pageheight and
pagewidth 0 rlineto % pagewidth
0 pageheight neg rlineto
closepath clip % clip the regiom
leftmargin botmargin translate % set the origin (0,0) on location
% (leftmargin,botmargin)
}def
/pagecutnr
{
% define the newwidth as the pagewidth plus
% twice the leftmargin
/newwidth
pagewidth leftmargin add
leftmargin add def
% idem for the newheight
/newheight
pageheight botmargin add
botmargin add def
gsave % set the origin back to (0,0)
leftmargin neg botmargin neg translate
newpath
0 0 moveto % define the new clipping region
0 newheight rlineto
newwidth 0 rlineto
0 newheight neg rlineto
closepath clip
newpath
%draw the frame if showpagecut equals 1
showpagecut 1 eq
{
leftmargin botmargin moveto
0 pageheight rlineto
pagewidth 0 rlineto
0 pageheight neg rlineto
closepath
0 setgray
2 setlinewidth % draw a thick frame
stroke
} if
showpagenr 1 eq % show the pagenr if showpagenr equals 1
{
/str 4 string def % reserve space for a 4 character string
leftmargin botmargin moveto % goto the origin
pagewidth 0 rmoveto % goto the right hand bottom corner
-20 3 rmoveto % go a little bit left and up
/pagenumber % calculate the pagenumber from the row
row nrofpageshor mul % and column. row 0, column 0 = page 1
col add 1 add def % pagenr=row*nof_pages_horizontal+column+1
/Helvetica-Bold findfont 7 scalefont setfont
pagenumber str cvs % convert the pagenumber into a string
show % and show it
}if
showconnections 1 eq
{
/curpage
row nrofpageshor mul
col add 1 add def
/uppage curpage nrofpageshor add def
/downpage curpage nrofpageshor sub def
downpage 0 gt
{
newpath
leftmargin 7 add botmargin 3 add moveto
4 5 rlineto
-3 0 rlineto
0 10 rlineto
-2 0 rlineto
0 -10 rlineto
-3 0 rlineto
closepath
gsave
0 setgray
fill
grestore
leftmargin botmargin moveto
12 3 rmoveto
/Helvetica-Bold findfont 7 scalefont setfont
downpage str cvs % convert the pagenumber into a string
show % and show it
}if
uppage totalnofpages le
{
newpath
leftmargin 7 add botmargin pageheight add 3 sub moveto
-4 -5 rlineto
3 0 rlineto
0 -10 rlineto
2 0 rlineto
0 10 rlineto
3 0 rlineto
closepath
gsave
0 setgray
fill
grestore
leftmargin 12 add botmargin pageheight add 18 sub moveto
/Helvetica-Bold findfont 7 scalefont setfont
uppage str cvs % convert the pagenumber into a string
show % and show it
}if
}if
setclipping % set the clipping back
grestore
}def
/printpage %stack row col
{
/row exch def % get info from the stack
/col exch def
/totalpictureproc exch def
shade 2 eq {shadeback} if % call procedure shadeback if shade equals 2
shade 1 eq % set variable componentshade to 0.8 if shade=1
{/componentshade 0.8 def} % else set it to 1 (= white)
{/componentshade 1 def} ifelse
grid 1 eq % draw the grid if grid=1
{
0 setgray % set black
[4 4] 1 setdash % define the dash pattern
0 gridwidth pagewidth
{drawverticalline} for % draw all vertical lines
0 gridheight pageheight
{drawhorizontalline} for % and all horizontal ones
[] 0 setdash % set line pattern back to solid line
} if
/tmp showpagecut showpagenr add showconnections add def
tmp 0 gt
{pagecutnr} if % call pagecutnr if showpagecut OR showpagenr
% equals 1. (or both)
gsave
pagewidth col mul neg % move origin to (-col*pagewidth,-row*pageheigh
pageheight row mul neg % this will map page (col,row) onto the origin
translate
totalpictureproc % draw the complete picture. Only the part that
% maps onto the origin will appear on the paper
gsave showpage grestore % put it all on paper
grestore
}def
/printlan
{
/rows exch def % get the number of rows (=number of vertical
/columns exch def % pages) , columns and name of the procedure
/bigpictureproc exch def % that prints the complete lan, from the stack
newpath
0 1 rows 1 sub % for row_nr=0 to (rows-1) step 1 do
{
/rowcount exch def % define rowcount.This is the running value
% of rows
0 1 columns 1 sub % for col_nr=0 to (columns-1) step 1 do
{/colcount exch def % define colcount
{bigpictureproc} % cal procedure printpage with the three
colcount % variables
rowcount printpage
}for
}for
}def
/MCC_NODE4_ICON
<
00000000003ffffffffc
40000000005ffffffff8
5ffffffff85f800000f8
5f7ffffcf85efffff8f8
5dfffff0f858000000f8
5bffffe0f85bffffe0f8
5bffffe0f85b8e38e0f8
5b8e38e0f85b8e38e0f8
5b8e38e0f85b8e38e0f8
5b8e38e0f85b8e38e0f8
5bffffe0f85bffffe0f8
5bffffe0f85bff3fe0f8
5bfe3fe0f85bfc3fe0f8
5bfd3fe0f85bf93fe0f8
5bfb3fe0f85bf33fe0f8
5bf01fe0f85bff3fe0f8
5bfe1fe0f85bffffe150
5bffffe2a85800000aa8
5ffffffff84000000000
00000000000000000000
>def
/MCC_UNKNOWN_ICON
<
00000000003ffffffffc40000000005ffffffff85ffffffff85ffffffff8
5ffffffff85ffffffff85ffffffff85ffffffff85ffffffff85fffc1fff8
5fff98fff85fff1c7ff85fff1c7ff85fffbc7ff85ffff87ff85ffff0fff8
5ffff1fff85fffe3fff85fffe7fff85fffe7fff85ffffffff85ffffffff8
5fffe7fff85fffc3fff85fffc3fff85fffe7fff85ffffffff85ffffffff8
5ffffffff85ffffffff85ffffffff85ffffffff85ffffffff85ffffffff8
5ffffffff8400000000000000000000000000000
>def
/draw_lines
{
11.2500 475.0520 2354.4695 761.9540 2207.9000 straightline
4.0000 761.9540 2207.9000 761.9540 2126.8184 straightline
4.0000 945.9460 2154.8855 945.9460 2155.3855 straightline
4.0000 362.7860 2431.3924 475.0520 2354.4695 straightline
4.0000 573.8045 2431.3924 475.0520 2354.4695 straightline
11.2500 475.0520 2208.9396 475.0520 2354.4695 straightline
11.2500 181.9125 2220.3734 475.0520 2354.4695 straightline
4.0000 164.2410 2208.9396 164.2410 2129.9369 straightline
4.0000 475.0520 2208.9396 475.0520 2128.8974 straightline
8.7500 99.7920 2126.8184 899.1685 2126.8184 straightline
( Computer Room Ethernet Segment
) 354.4700 2089.3965 text
}def
/draw_icons
{
741.9540 2187.9000 40 40 ( MCC_NODE4_ICON ) icon
( .DNA_NODE.CRUSHA ) 790.0210 2196.7771 text
553.8045 2411.3924 40 40 ( MCC_UNKNOWN_ICON ) icon
( HSC002 ) 602.3910 2423.9080 text
342.7860 2411.3924 40 40 ( MCC_UNKNOWN_ICON ) icon
( HSC001 ) 288.4615 2428.0660 text
455.0520 2334.4695 40 40 ( MCC_UNKNOWN_ICON ) icon
( BAHTAT_STAR_COUPLER ) 506.2370 2345.9456 text
455.0520 2188.9396 40 40 ( MCC_NODE4_ICON ) icon
( .DNA_NODE.ERIC ) 508.3160 2200.9349 text
144.2410 2188.9396 40 40 ( MCC_NODE4_ICON ) icon
( .DNA_NODE.MILBRN ) 196.4655 2201.9744 text
}def
/lan
{
0.6382 0.6382 scale
-99.7920 -2089.3962 translate
draw_lines
draw_icons
1 1 scale
}def
/pageheight 3.2086 inch def
/pagewidth 7.5000 inch def
/showpagecut 1 def
/showpagenr 0 def
/showconnections 0 def
/shade 0 def
/nrofpageshor 1 def
/totalnofpages 1 def
setclipping
/grid 1 def
/gridwidth 4.7864 inch def
/gridheight 7.0200 inch def
{lan} 1 1 printlan
erasepage
initgraphics
|
1270.8 | do you need some more maps?
| RIGI::SCHNEIDERR | | Thu Jul 25 1991 08:07 | 5 |
| Timo,
Do you need some more maps, or are you finished with your testings?
Roland
|