# Mattenliste Österreich
name(i30,"reihe") ;
name(i31,"spalte");
name(i32,"blatnr");
name(r30,"abstx");
name(r31,"absty");

name(i40,"penrah");
name(i41,"penpos");
name(i42,"penlb") ;
name(i43,"penbez");
name(r40,"txhvau");
name(r41,"txhpos");
name(r42,"txhlb") ;
name(r43,"txhbez");
name(r44,"mastab");

penrah = 2 ;           # Farbe fuer den Rahmen               0=Nicht zeichnen
txhvau = 0.0 ;         # Texthoehe fuer den Auszug darunter  0.0 = nicht
penpos = 4;
txhpos = 17.5;         # Farbe+Texthoehe Positionsnummer in Matte
penlb  = 1;
txhlb  = 10.0;         # Farbe+Texthoehe Laenge/Breite
penbez = 3;
txhbez = 17.5;         # fuer Bezeichnung ueber der Matte

mastab = 2.0;
mbwbiegevor(mastab,penrah,penpos,penlb,penbez,txhvau,txhpos,txhlb,txhbez);


    write("Einfügepunk Liste:");
    read(p1);

    gst_height(12.5);
    gst_color(4);
    gst_rotation(0.0);

    insert("A_MBW1","AUSTRIA",p1,50.0,50.0,0.0);
    
    p2=p1;
    p2.y = p2.y - 268.0 ;

    blatnr = 1;
    reihe  = 0;

    for i88 = 1 to mbwanzposi do
      begin
      p3 = p2 ;
    
	  p3.x = p2.x + 100.0  ;    
      mbwliste(i88,"POS","-3",s1);
      text(p3,s1);

      p3.x = p2.x + 190.0 ;
      mbwliste(i88,"STUECK","-3",s1);
      text(p3,s1);

      p3.x = p2.x + 260.0 ;
      mbwliste(i88,"MATTYP","",s1);
      text(p3,s1);

      p3.x = p2.x + 440.0 ;
      mbwliste(i88,"LAENGE","-4.2",s1);
      string_to_real(r10,s1);
      # Ausgabe in CM  ohne Nachkommastelle
      string_copy(s1,"");
	  r15 = r10 * 100.0
      string_cat(s1,r15,".0");
      string_cat(s1,"  x ","");
      text(p3,s1);

      p3.x = p2.x + 550.0 ;
      mbwliste(i88,"BREITE","-4.2",s1);
      string_to_real(r11,s1);
      # Ausgabe in CM ohne Nachkommastelle
      string_copy(s1,"");
 	  r15 = r11 * 100.0
      string_cat(s1,r15,".0");
	  text(p3,s1);	
  	  
     r12 = r10 * r11 ;
	  string_copy(s1,"");
      string_cat(s1,r12,".2");
      r12 = r10 * r11;
	  p3.x = p2.x + 737.0 ;
	  text(p3,s1);

      p3.x = p2.x + 845.0 ;
      mbwliste(i88,"LM_KG_MATTE","-4.2",s1);
      text(p3,s1);

      p3.x = p2.x + 952.0 ;
      mbwliste(i88,"LM_KG_POS","-4.2",s1);
      text(p3,s1);
      
      p2.y = p2.y - 30.0  ;
      reihe = reihe + 1;

      if( reihe = 39) then
       begin
        reihe  = 0 ;
        p1.x = p1.x + 1100.0;
        insert("A_MBW1","AUSTRIA",p1,50.0,50.0,0.0);
        p2=p1;
        p2.y = p2.y - 268.0 ;
       end # fi reihe = 39

   end

	 p3 = p1;
	 p3.x = p3.x + 850.0 ;
     p3.y = p3.y - 1460.0 ;
     mbwliste(1,"GESGEW","7.2",s1);
     text(p3,s1);

END.

