source: trunk/ToBeReviewed/WIDGET/AUTOUR_de_XXX/createhistory.pro @ 69

Last change on this file since 69 was 69, checked in by smasson, 18 years ago

debug + new xxx

  • Property svn:eol-style set to native
  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
File size: 1.6 KB
Line 
1PRO createhistory, base, small
2;
3;-------------------------------------------------------------
4; we save globalcommand in globaloldcommand
5   widget_control,base, get_uvalue = top_uvalue
6   globalcommand = extractatt(top_uvalue, 'globalcommand')
7   *top_uvalue[1, findline(top_uvalue, 'globaloldcommand')] = globalcommand
8; portrait or landscape ???
9   options = extractatt(top_uvalue, 'options')   
10   optionsflag = extractatt(top_uvalue, 'optionsflag')
11   portrait = (optionsflag[where(options EQ 'Portrait/Landscape'), 0])[0]
12; composition du text contennu ds history.pro
13   texte = ['@common' $
14            , ' ' $
15            , 'if keyword_set(postscript) then begin'  $
16            , '    noerase = 1' $
17            , '    openps, infowidget = infowidget, portrait = ' + strtrim(portrait, 2) $
18            , 'endif' $
19            , ' ' $
20            , '; beginning of 1' $
21            , ';' $
22            , '; end of 1']
23   if small[0]*small[1] GT 1 then begin
24      for draw = 1, small[0]*small[1]-1  do begin
25         texte = [texte $
26                  , '; beginning of '+strtrim(draw+1, 2) $
27                  , 'noerase=1' $
28                  , '; end of '+strtrim(draw+1, 2)]
29      endfor
30   ENDIF
31   texte = [texte $
32            , 'if keyword_set(postscript) then begin' $
33            , '    closeps, infowidget = infowidget' $
34            , '    printps' $
35            , 'endif']
36; the new globalcommand
37   *top_uvalue[1, findline(top_uvalue, 'globalcommand')] = texte
38;-------------------------------------------------------------
39;  for i = 0, n_elements(texte)-1 do print, texte[i]
40;-------------------------------------------------------------
41   return
42end
Note: See TracBrowser for help on using the repository browser.