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 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012
  
     | 
    
      % ======================================================================
% komabug.tex
% Copyright (c) Markus Kohm, 1995-2009
%
% This file is part of the LaTeX2e KOMA-Script bundle.
%
% This work may be distributed and/or modified under the conditions of
% the LaTeX Project Public License, version 1.3c of the license.
% The latest version of this license is in
%   http://www.latex-project.org/lppl.txt
% and version 1.3c or later is part of all distributions of LaTeX
% version 2005/12/01 or later and of this work.
%
% This work has the LPPL maintenance status "author-maintained".
%
% The Current Maintainer and author of this work is Markus Kohm.
%
% This work consists of all files listed in manifest.txt.
% ----------------------------------------------------------------------
% komabug.tex
% Copyright (c) Markus Kohm, 1995-2009
%
% Dieses Werk darf nach den Bedingungen der LaTeX Project Public Lizenz,
% Version 1.3c, verteilt und/oder veraendert werden.
% Die neuste Version dieser Lizenz ist
%   http://www.latex-project.org/lppl.txt
% und Version 1.3c ist Teil aller Verteilungen von LaTeX
% Version 2005/12/01 oder spaeter und dieses Werks.
%
%
% Dieses Werk hat den LPPL-Verwaltungs-Status "author-maintained"
% (allein durch den Autor verwaltet).
%
% Der Aktuelle Verwalter und Autor dieses Werkes ist Markus Kohm.
%
% Dieses Werk besteht aus den in manifest.txt aufgefuehrten Dateien.
% ======================================================================
%%
%% @ is a letter
%%
\catcode`\@=11
%%
%% Grab the initex file list
%%
%% If this file is called via
%%     latex "\input{latexbug}" or some
%% similar command sequence rather than
%%     latex latexbug
%% then the debugging info in \reserved@a will already have been lost.
%% This might not matter, but if it does we may ask the user to resubmit
%% the report.
\ifx\reserved@b\@undefined
  \ifx\reserved@a\@gobble
    \def\@inputfiles{NONE}
  \else
    \let\@inputfiles\reserved@a
  \fi
\else
  \def\@inputfiles{LOST}
\fi
%%
%% Output stream to produce the bug report template.
%%
\newif\ifinteractive\interactivetrue
\newwrite\@msg
\immediate\openout\@msg=\jobname.msg
\immediate\write\@msg{%
An fatal error occured before writing anything to the message file.^^J%
You should have a look at \jobname.log to see the reason of the error.^^J%
^^J%
Maybe you didn't use an interactive terminal to run ``latex komabug''.^^J%
At this case you should try an interactive terminal or add^^J%
\space\space\space\space\string\interactivefalse^^J%
to your local ``komabug.cnf'' to create an empty message.^^J%
You have to edit that message file after creating the empty message.^^J%
}
\immediate\closeout\@msg\let\msg\m@ne
%%
%% We have no end line char (so we have no paragraphs)
%%
\endlinechar=-1
%%
%% Check that LaTeX2e is being used.
%%
\ifx\undefined\newcommand
 \newlinechar`\^^J%
 \immediate\write17{^^J%
    You must use LaTeX2e to generate the bug report!^^J^^J%
    Sie muessen LaTeX2e verwenden, um die Fehlermeldung zu erzeugen!}%
 \let\relax\end
\else
 \def\@tempa{LaTeX2e}\ifx\@tempa\fmtname\else
  \immediate\write17{^^J%
   You must use LaTeX2e to generate the bug report!^^J^^J%
   Aeltere Versionen von LaTeX werden nicht unterstuetzt.^^J%
   Sie muessen LaTeX2e verwenden, um die Fehlermeldung zu erzeugen!}%
  \let\relax\@@end
\fi\fi
%%
%% \wmsg writes to the terminal, and the .msg file
%% \wmsg* just writes to the .msg file
%% \typeout just writes to the terminal
%%
\def\wmsg{%
  \ifnum\msg<0\relax\let\msg\@msg\immediate\openout\msg=\jobname.msg\fi
  \begingroup
    \@ifstar {\interactivefalse\@wmsg}{\@wmsg}
}
\def\@wmsg#1{%
    \ifinteractive\immediate\write17{#1}\fi%
    \immediate\write\msg{#1}%
  \endgroup
}
%%
%% Prompt for an answer from the user, if the answer is not
%% provided by the cfg file.
%%
\def\readifnotknown#1{%
 \@ifundefined{#1}%
    {{\message{#1> }%
     \catcode`\^^I=12 \let\do\@makeother\dospecials
     \global\read\m@ne t\expandafter o\csname#1\endcsname}}%
    {\message{\csname#1\endcsname}}}
%%
%% Get number
%% #1 = message
%% #2 = max value
%% --> \answer
%%
\def\scannumber#1{\@tempswatrue
  \typeout{`#1'}%
  \def\@tempa{\expandafter\@scannumber\expandafter0#1\@nil}%
  \edef\@tempa{\@tempa}%
  \count@\@tempa\relax
  \if@tempswa\else\count@\z@\relax\fi
}%
\def\@scannumber#1{%
  \ifx\@nil#1\else
    \if 0#1#1\else
      \ifnum 0<0#1 #1\else
        \noexpand\@tempswafalse%
      \fi
    \fi
    \expandafter\@scannumber
  \fi
}%
\def\ReadNumber#1#2{%
  \typeout{#1}%
  \ifenglish
    \message{Input the corresponding number between 1 and #2:  }%
  \else
    \message{Geben Sie die betreffende Zahl zwischen 1 und #2 ein:  }%
  \fi
  \count@=\z@\relax
  \read\m@ne to \answer
  \scannumber{\answer}%
  \ifnum\count@>\number#2\relax
    \count@=\z@\relax
  \fi
%  \typeout{\the\count@ > 0?}%
  \ifnum\count@>\z@\relax
%    \typeout{YES}%
    \advance\count@ by \m@ne
    \edef\answer{\the\count@}%
    \message{^^J}%
  \else
%    \typeout{NO}%
    \ifenglish
      \typeout{Value not valid!}%
    \else
      \typeout{Wert nicht im erlaubten Bereich!}%
    \fi
    \pause
    \def\@tempa{\ReadNumber{#1}{#2}}%
    \expandafter\@tempa
  \fi
}
%%
%% Get Yes or No
%% #1 Question
%% --> \if@tempswa (yes is true, no is false)
%%
\def\ReadYesNo#1{%
  \typeout{#1}%
  \ifenglish
    \message{Answer `yes' or `no':  }%
    \read\m@ne to \answer
  \else
    \message{Antworten Sie bitte mit `ja' oder `nein': }%
    \read\m@ne to \answer
    \edef\answer{\uccode`\expandafter\@car\answer\@nil}
    \ifnum \answer=`J \def\answer{\uccode`Y}\fi
  \fi
  \def\@tempa{\message{^^J}}%
  \ifnum \answer=`Y \@tempswatrue
  \else
    \ifnum \answer=`N \@tempswafalse
    \else
      \ifenglish
        \typeout{Answer not valid!}%
      \else
        \typeout{Antwort unverstaendlich!}%
      \fi
      \def\@tempa{\ReadYesNo{#1}}%
    \fi
  \fi
  \@tempa
}
%%
%% Pause so messages do not scroll off screen.
%%
\def\pause{%
  \ifinteractive
    \ifenglish
      \message{Press <return> to continue. }%
    \else
      \message{Mit der <Return>-Taste geht es weiter. }%
    \fi
    \read\m@ne to \@tempa
    \message{^^J}%
  \fi
}
%%
%% german or english report generator
%%
\newif\ifenglish\englishfalse
%%
%% Opening Banner.
%%
\InputIfFileExists{komabug.cfg}{%
  \ifenglish
    \typeout{** using komabug.cfg **}%
  \else
    \typeout{** komabug.cfg wird verwendet **}%
  \fi
}{}
\ifenglish
  \typeout{^^J%
    ============================================================^^J%
    ^^J%
    KOMA bug report generator^^J%
    =========================^^J%
    Running this file through LaTeX generates a formular ``\jobname.msg''^^J%
    containing a bug report to KOMA-Script bundle.^^J^^J%
    * Please use german, if possible.^^J \space
      If you're not able to use german, write the report in english.^^J%
    * Please write a short report not a large one.^^J%
    * Please tell me everything, which may be important.^^J}
  \pause
\else
  \typeout{^^J%
    ============================================================^^J%
    ^^J%
    KOMA-Script Fehlermeldungsgenerator^^J%
    ===================================^^J%
    Die Bearbeitung dieser Datei mit LaTeX erzeugt das Formular \jobname.msg,^^J%
    um Fehlermeldungen zum KOMA-Script-Paket zu melden.^^J^^J%
    * Schreiben Sie Ihre Meldung nach Moeglichkeit in Deutsch.^^J \space
      Notfalls ist auch Englisch moeglich.^^J%
    * Bitte fassen Sie sich kurz.^^J%
    * Bitte halten Sie keine Information zurueck, die moeglicherweise^^J \space
    wichtig sein koennte.^^J}%
  \typeout{%
    If you prefere english, you may write a file ``komabug.cfg'' with\space 
    contents:^^J\space
    \string\englishtrue^^J%
    at same folder as ``komabug.tex'' and restart ``latex komabug.tex''.^^J}%
  \englishtrue\pause\englishfalse
\fi
%%
%% if \interactivefalse just make a blank template.
%%
\ifinteractive
  \ifenglish
    \ReadYesNo{%
      There are two kinds of using this generator.^^J%
      At the interactive mode, you have to answer questions. At the other^^J%
      mode an empty formular will be generated, you have to fill using^^J%
      an editor.^^J^^J%
      Do you want an interactive session?
    }%
  \else
    \ReadYesNo{%
      Dieser Generator kann auf zwei Arten verwendet werden.^^J%
      Im interaktiven Betrieb, werden Ihnen Fragen zur direkten
      Beantwortung^^J%
      gestellt. Ansonsten wird ein leeres Formular erzeugt, das Sie dann
      mit^^J% 
      einem Editor ausfuellen muessen.^^J^^J%
      Wollen Sie eine interaktive Sitzung?
    }%
  \fi
  \if@tempswa\interactivetrue\else\interactivefalse\fi
\fi
%%
%% Fatal error
%%
\def\fatalerror#1{%
  \ifenglish
    \errhelp{This error is fatal! You cannot continue.^^J%
      You should terminate using `x' and restart ``latex komabug''.}%
    \errmessage{#1}%
  \else
    \errhelp{Dieser Fehler erlaubt keine Fortsetzung der Bearbeitung.^^J%
      Sie sollten mit `x' abbrechen und ``latex komabug'' neu starten.}%
    \errmessage{#1}%
  \fi
  \batchmode\csname @@end\endcsname
  \fatalerror{#1}%
}
%%
%% Try to get Version
%%
\def\GetFileVersionWithExtend#1#2{%
  \def\ProvidesFile##1{\@ifnextchar [{\@P@F}{\@P@F[1996/10/31 ]}}%
  \def\@P@F[##1 ##2]{\xdef\komaversion{##1}\csname endinput\endcsname}%
  \let\ProvidesClass\ProvidesFile
  \let\ProvidesPackage\ProvidesFile
  \InputIfFileExists{#1#2}{}{%
    \ifenglish
      \def\noscrclass{%
        ! File ``#1#2'' not found!^^J%
        ! The file must be at the same folder like ``komabug.tex''^^J%
        ! or must be readable by LaTeX to get the version information!}%
    \else
      \def\noscrclass{%
        ! Die Datei ``#1#2'' konnte nicht gefunden werden!^^J%
        ! Zur Bestimmung der aktuellen Version ist es unbedingt^^J%
        ! erforderlich, dass diese Datei sich im selben Verzeichnis^^J%
        ! wie ``komabug.tex'' befindet oder zumindest von LaTeX^^J%
        ! gefunden werden kann!}%
    \fi
    \errmessage{\noscrclass}
    \ifenglish
      \errhelp{Terminate TeX using `x' and restart komabug}
    \else
      \errhelp{Beenden Sie TeX mit `x' und starten Sie komabug neu}
    \fi
  }%
}
\def\GetVersion#1{%
  \GetFileVersionWithExtend{#1}\@empty
}
\ifinteractive
  \ifenglish
    \ReadNumber{%
      There are several categories, related to several parts and files^^J%
      of the KOMA-Script bundle:^^J^^J
      1) Installation of KOMA-Script^^J
      2) KOMA-Script manual^^J
      3) Basics (scrbook, scrreprt, scrartcl, scrlttr2, typearea, scrlfile)^^J
      4) Pagestyle definition (scrpage2)^^J
      5) Time or date (scrtime, scrdate)^^J
      6) Address file handling (scraddr)^^J
      7) Obsolete (scrlettr, scrpage)^^J%
    }{7}%
  \else
    \ReadNumber{%
      Verschiedene Bereiche werden von diesem Generator unterstuetzt, die^^J%
      sich auf verschiedene Dateien im KOMA-Script-Paket beziehen:^^J^^J
      1) Auspacken und Installieren von KOMA-Script^^J
      2) KOMA-Script-Anleitung^^J
      3) Grundfunktion (scrbook, scrreprt, scrartcl, scrlttr2, typearea,
      scrlfile)^^J
      4) Definition von Seitenstilen (scrpage2)^^J
      5) Zeit oder Datum (scrtime, scrdate)^^J
      6) Umgang mit Adressdateien (scraddr)^^J
      7) Obsoletes (scrlettr, scrpage)^^J%
    }{7}%
  \fi
  \ifcase\expandafter\number\answer
    % 1
    \def\category{Installation}\GetVersion{scrkernel-version.dtx}
    \let\categoryversion\komaversion
  \or
    % 2
    \def\category{Manual}\GetVersion{scrartcl.cls}
    \let\categoryversion\komaversion
  \or
    % 3
    \def\category{Basics}\GetVersion{scrartcl.cls}
    \let\categoryversion\komaversion
  \or
    % 4
    \def\category{Addons, scrpage2}\GetVersion{scrpage2.sty}%
    \let\categoryversion\komaversion\GetVersion{scrartcl.cls}
  \or
    % 5
    \def\category{Addons, scrtime/date}\GetVersion{scrtime.sty}%
    \let\categoryversion\komaversion\GetVersion{scrartcl.cls}
  \or
    % 6
    \def\category{Addons, scraddr}\GetVersion{scraddr.sty}%
    \let\categoryversion\komaversion\GetVersion{scrartcl.cls}
  \or
    % 7
    \ifenglish
      \typeout{These obsolete parts of KOMA-Script are unsupported!^^J%
        You should use scrlttr2 instead of scrlettr and scrpage2 instead of
        scrpage.}
    \else
      \typeout{Fuer diese obsoleten Teile von KOMA-Script gibt es keinen
        Support mehr!^^J%
        Sie sollten scrlttr2 an Stelle von scrlettr bzw. scrpage2 an Stelle
        von^^J%
        scrpage verwenden.}
    \fi
    \batchmode\csname @@end\endcsname
  \fi
\else% \ifinteractive
  \ifenglish
    \def\category{<PLEASE REPLACE BY ONE OF `Installation', `Manual',
      `Basics', `Addons, scrpage2', `Addons, scrtime/date', `Addons,
      scraddr'.>}
    \def\categoryversion{<PLEASE REPLACE BY VERSION DATE FROM USED CLASS OR
      PACKAGE.>}
  \else
    \def\category{<BITTE DURCH EINE DER ANGABEN `Installation', `Manual',
      `Basics', `Addons, scrpage2', `Addons, scrtime/date', `Addons,
      scraddr' ERSETZEN.>}
    \def\categoryversion{<BITTE DURCH DAS VERSIONSDATUM AUS DER ENTSPRECHENDEN
      KLASSE BZW. DEM ENTSPRECHENDEN PAKET ERSETZEN.>}
  \fi
  \GetVersion{scrartcl.cls}
\fi
\ifinteractive
  \ifenglish
    \typeout{^^J%
      ===========================================================^^J%
      ^^J%
      Please give a one line description (< 50 chars) of your problem.%
      ^^J^^J%
      If your using email for sending the report, please use this^^J%
      description as subject, too:%
      ^^J \@spaces\@spaces\space
      |<------------------------------------------------>|}
  \else
    \typeout{^^J%
      ============================================================^^J%
      ^^J%
      Bitte eine einzeilige (< 50 Zeichen) Beschreibung des Problems.%
      ^^J^^J%
      Wenn Sie fuer die Meldung eMail verwenden, setzen Sie diese
      Beschreibung^^J%
      bitte auch als Betreff (`Subject') der eMail ein:%
      ^^J \@spaces\@spaces\space
      |<------------------------------------------------>|}
  \fi
  \loop
    \let\synopsis\relax
    \readifnotknown{synopsis}
    \ifx\synopsis\@empty
  \repeat
\else%\ifinteractive
  \ifenglish
    \def\synopsis{<PLEASE REPLACE BY SHORT ONE-LINE DESCRIPTION.>}
  \else
    \def\synopsis{<BITTE DURCH EINE KURZE, EINZEILIGE BESCHREIBUNG ERSETZEN.>}
  \fi
\fi
%%
%% Header in the msg file.
%%
\ifenglish
  \wmsg*{^^J%
    KOMA bug report.^^J%
    \ifinteractive Interactive \else Formular \fi
    generated using komabug.tex at
    \space\number\year-\two@digits\month-\two@digits\day.^^J%
    ^^J
    You may send this message to komascript@gmx.info.^^J%
    If you do so, please use subject:^^J%
    \space KOMA-BUG:\space\synopsis^^J%
    ============================================================^^J
  }
\else
  \wmsg*{^^J%
    KOMA-Fehlermeldung.^^J%
    \ifinteractive Interaktiv \else Formular \fi
    erzeugt mit komabug.tex am
    \space\number\year-\two@digits\month-\two@digits\day.^^J%
    ^^J%
    Die Meldung kann per E-Mail an komascript@gmx.info^^J%
    verschickt werden.^^J%
    Bitte verwenden Sie dabei als Betreff:^^J%
    \space KOMA-BUG:\space\synopsis^^J%
    ============================================================^^J
  }
\fi
%%
%% Category of bug, obtained earlier but put out now, after the header.
%%
\wmsg{>Bereich: \category}
\wmsg{>Version: \categoryversion}
%%
%% synopsis of bug, obtained earlier but put out now, after the header.
%%
\wmsg{>Betreff: \synopsis}
\begingroup
 \global\let\format\@empty
 \gdef\hyphenation{standard}
 \def\immediate#1#{\xdef\hyphenation}
 \def\typeout#1{\xdef\format{\format#1}}
 \the\everyjob
\endgroup
\wmsg{>Format: \format}
\wmsg{>KOMA-Script: \komaversion}
\ifinteractive
%%
%% if interactive, \wread reads a line (verbatim) and write it to the
%% .msg file, until a blank line is entered.
%%
  \def\wread{{%
      \catcode`\^^I=12
      \let\do\@makeother\dospecials
      \let\lastanswer\answer
      \message{=> }\read\m@ne to \answer
      \ifx\lastanswer\@empty
        \let\lastanswer\answer
      \fi
      \ifx\lastanswer\@empty
      \else
        \immediate\write\msg{\answer}
        \expandafter\wread
      \fi
    }%
  }
\else
%%
%% If non-interactive, \wread just writes a blank line to the .msg file,
%% and \wmsg does not write to the terminal.
%%
  \def\wread{\wmsg{}}
\fi
%%
%% \copytomsg copies the contents of a file into the .msg file.
%% (at least it does it as well as TeX can, so there may be
%% transcription problems with 8-bit characters).
%%
%% It does a line count, and complains if the test file is
%% too large.
\chardef\inputfile=15
\newcount\linecount
\def\copytomsg#1{{%
    \endlinechar=-1
    \def\do##1{\catcode`##1=11}%
    \dospecials
    \global\linecount\z@
    \openin\inputfile#1\relax
    \def\thefile{#1}%
    \@copytomsg
    \closein\inputfile}}
\def\@copytomsg{%
   \ifeof\inputfile
      \typeout{*** \thefile\space Zeilen = \the\linecount}
   \else
      \global\advance\linecount\@ne
      \read\inputfile to \inputline
      \ifx\inputline\@empty
         \wmsg*{}
      \else
         \wmsg*{\inputline}
      \fi
      \expandafter\@copytomsg
   \fi}
%%
%% Test the age of the current format.
%%
\def\getage#1/#2/#3\@nil{%
  \count@\year
  \advance\count@-#1\relax
  \multiply\count@ by 12\relax
  \advance\count@\month
  \advance\count@-#2\relax}
%
\expandafter\getage\fmtversion\@nil
%%
%% \count@ should now be the age of the format in months.
%%
\ifnum\count@>24
  \ifenglish
    \def\oldformat{^^J%
      ! Your LaTeX installation is older than two years.^^J%
      ! Updating woul dbe a good idea before sending this report.^^J%
      ! You should compare the date of the package with the date of^^J
      ! the used LaTeX version. If LaTeX is more than two years older^^J
      ! than KOMA-Script, this could be the reason of the problem.}
    \errhelp{If you want to continue, press <return>.}
  \else
    \def\oldformat{^^J%
      ! Ihre LaTeX-Installation ist ueber zwei Jahre alt.^^J%
      ! Bitte denken Sie ueber ein Update nach, ehe Sie diese Meldung^^J%
      ! abschicken.^^J%
      ! Vergleichen Sie wenigstens das Datum des Paketes mit dem Datum^^J%
      ! der LaTeX-Version. LaTeX sollte nicht mehr als zwei Jahre aelter^^J%
      ! als KOMA-Script sein. Ansonsten koennte der Fehler in einer^^J%
      ! Unvertraeglichkeit zwischen Format- und Paketversion liegen.}
%%
%% Put the message in a macro to improve the look of the error mesage.
%%
%
    \errhelp{Wenn Sie dennoch fortfahren wollen, druecken Sie einfach <Return>.}
  \fi
  \errmessage{\oldformat}
\fi
%
\expandafter\getage\komaversion\@nil
\ifnum\count@>18
  \ifenglish
    \def\oldversion{^^J%
      ! Your KOMA-Script installation is older than one year.^^J%
      ! You should check for an update, bevor you're sending this message.^^J
      ! You should compare the date of the package with the date of^^J
      ! the used LaTeX version. If LaTeX is years younger than KOMA-Script,^^J
      ! this could be the reason of the problem.}
    \errhelp{If you want to continue, press <return>.}
  \else
    \def\oldversion{^^J%
      ! Ihre KOMA-Script-Version ist ueber ein Jahr alt.^^J%
      ! Bitte denken Sie ueber ein Update nach, ehe Sie diese Meldung^^J%
      ! abschicken.^^J%
      ! Vergleichen Sie wenigstens das Datum des Paketes mit dem Datum^^J%
      ! der LaTeX-Version. LaTeX sollte nicht Jahre juenger als KOMA-Script sein.^^J%
      ! Ansonsten koennte der Fehler in einer Unvertraeglichkeit zwischen^^J%
      ! Format- und Paketversion liegen.}
    \errhelp{Wenn Sie dennoch fortfahren wollen, druecken Sie einfach <Return>.}
  \fi
  \errmessage{\oldversion} 
\fi
%%
%% Now use \wmsg and \wread for each of the multi-line fields
%% in the form. Currently one-line fields use \read directly.
%%
\ifinteractive
  \ifenglish
    \typeout{^^JYour name:}
  \else
    \typeout{^^JIhr Name:}
  \fi
  \readifnotknown{name}
\else
  \ifx\name\undefined
    \ifenglish
      \def\name{<REPLACE THIS BY YOUR NAME>}
    \else
      \def\name{<GEBEN SIE IHREN NAMEN EIN>}
    \fi
  \fi
\fi
\ifinteractive
  \ifenglish
    \typeout{^^JYour address (email if possible):}
  \else
    \typeout{^^JIhre Adresse (eMail bevorzugt):}
  \fi
  \readifnotknown{address}
\else
  \ifx\address\undefined
    \ifenglish
      \def\address{<PEPLACE THIS BE YOUR (EMAIL-)ADDRESS>}
    \else
      \def\address{<GEBEN SIE IHRE (EMAIL-)ADRESSE EIN>}
    \fi
  \fi
\fi
\ifinteractive
  \ifenglish
    \typeout{^^JYour computer system (z. B. Atari, Linux, Mac, Win98SE):}
  \else
    \typeout{^^JDas verwendete Computersystem (z. B. Atari, Linux, Mac, Win98SE):}
  \fi
  \readifnotknown{computersystem}
\else
  \ifx\computersystem\undefined
    \ifenglish
      \def\computersystem{<REPLACE THIS BY YOUR COMPUTERSYSTEM>}
    \else
      \def\computersystem{<GEBEN SIE IHR VERWENDETES COMPUTERSYSTEM EIN>}
    \fi
  \fi
\fi
\wmsg*{>Adresse: \name\space<\address>}
%%
%% >Organisation: is really a GNATS multiline field
%% but we treat it as a one-line field.
%%
\wmsg*{>Organisation: \ifx\organisation\undefined
                        \ifx\organization\undefined\else
                           \organization
                        \fi
                       \else
                         \organisation
                       \fi}
%%
%% Test which format is being used. These fields are completed
%% automatically even if the blank template is being produced.
%%
\wmsg*{>Voraussetzungen:}
\wmsg*{ \string\@TeXversion: \meaning\@TeXversion
        \ifx\@TeXversion\@@undefined
         \space (Standardeinstellung fuer TeX3.141 und spaeter)\fi}
\wmsg*{ \string\@currdir: \meaning\@currdir}
\wmsg*{ \string\input@path: \meaning\input@path
        \ifx\input@path\@@undefined
         \space (Standardeinstellung)\fi}
\wmsg*{ System: \computersystem}
\wmsg*{>Beschreibung:}
\ifinteractive
  \ifenglish
    \typeout{%
      Description of your problem:^^J^^J%
      \@spaces You can use multiple lines (each is askes by the prompt^^J%
      \@spaces ``=>'').^^J%
      \@spaces Use two blank lines to finish your answer.}
  \else
    \typeout{%
      Beschreibung des Problems:^^J^^J%
      \@spaces Die Beantwortung dieser Frage kann mehrere Zeilen^^J%
      \@spaces einnehmen (jede wird durch die Eingabeaufforderung^^J%
      \@spaces ``=>'' eingeleitet).^^J%
      \@spaces Durch zwei aufeinanderfolgende Leerzeilen wird die^^J%
      \@spaces Antwort beenden.}
  \fi
\else
  \ifenglish
    \wmsg{<REPLACE THIS BY YOUR DESCRIPTION OF THE PROBLEM>}
  \else
    \wmsg{<GEBEN SIE HIER IHRE PROBLEMBESCHREIBUNG EIN>}
  \fi
\fi
\wread
%%
%% insertion of the test file
%%
\ifinteractive
  \ifenglish
    \typeout{^^J%
      Name of a short self describing file, which shows the problem^^J%
      (file should be as short as possible, not more than 60 lines):^^J^^J%
      If the file is not at current directory please enter the hole^^J%
      name (directory inclusive), so LaTeX may load it.^^J^^J%
      If no testfile exists, because your not reporting a bug at a class^^J%
      or package, simply press <return>.}
  \else
    \typeout{^^J%
      Name einer KURZEN, SELBSTERKLAERENDEN Datei, bei der das Problem^^J%
      auftritt (die Datei sollte wirklich so kurz wie moeglich sein,^^J%
      nicht mehr als 60 Zeilen):^^J^^J%
      Damit LaTeX diese Datei einlesen kann, geben Sie bitte den kompletten^^J%
      Namen einschliesslich des Verzeichnisses an, falls die Datei nicht im^^J%
      aktuellen Verzeichnis zu finden ist.^^J^^J%
      Falls Sie keinen Fehler in einer der Klassen oder Pakete melden und^^J%
      daher keine Testdatei existiert, druecken Sie einfach <Return>.}
  \fi
  \message{filename> }\read\m@ne to \filename
\else
   \let\filename\@empty
\fi
%%
%% Try to find the .tex file and .log file
%%
\ifx\filename\@empty
  \ifinteractive
    \ifenglish
      \ReadNumber{^^J^^JNo Testfile.^^J^^J%
        Three kinds of reports are possible:^^J^^J%
        1) SW bug:^^J\@spaces
        Software bug, you have to add a test file!^^J
        2) DOC bug:^^J\@spaces
        Bug at manual or you do not understand the manual.^^J
        3) Ask for change:^^J\@spaces
        Not a bug, but you'd like a change or simply help.^^J}{3}
    \else
      \ReadNumber{^^J^^JKeine Testdatei.^^J^^J%
        Drei Arten von Meldungen werden unterstuetzt:^^J^^J%
        1) SW-Fehler:^^J\@spaces
        Software-Fehler, unbedingt eine Testdatei beilegen!^^J
        2) DOC-Fehler:^^J\@spaces
        Fehler in oder unverstaendliche Anleitung.^^J
        3) Aenderungswunsch:^^J\@spaces
        Kein Fehler sondern eine Frage nach Aenderung oder Hilfe.^^J}{3}
    \fi
  \else
    \def\answer{0}%
  \fi
\else
  \def\answer{0}%
  \filename@parse\filename
  \IfFileExists{\filename}{\edef\samplefile{\filename}%
    \IfFileExists{\filename@area\filename@base.log}{%
      \edef\logfile{\filename@area\filename@base.log}%
    }{%
      \IfFileExists{\filename@area\filename@base.lis}{%
        \edef\logfile{\filename@area\filename@base.lis}%
      }{%
        \ifenglish
          \typeout{^^J%
            Log file ``\filename@area\filename@base.log'' not found.^^J%
            Please add the log file at ``\jobname.msg''.}%
        \else
          \typeout{^^J%
            Logdatei ``\filename@area\filename@base.log'' nicht gefunden.^^J%
            Bitte ergaenzen Sie das Beispiel in ``\jobname.msg''.}%
        \fi
        \pause
      }%
    }%
  }{%
    \ifenglish
      \typeout{^^J%
        Test file ``\filename'' not found.^^J%
        Please add the test file at ``\jobname.msg''.}
    \else
      \typeout{^^J%
        Beispieldatei ``\filename'' nicht gefunden.^^J%
        Bitte ergaenzen Sie das Beispiel in ``\jobname.msg''.}
    \fi
    \pause
  }%
\fi
\ifcase\expandafter\number\answer
  \ifinteractive\wmsg{>Unterbereich: SW-Fehler}\fi
  \wmsg*{%
    Beispieldatei, die das Problem verdeutlicht:^^J%
    ============================================}
  \ifx\samplefile\undefinedcommand
    \ifenglish
      \typeout{^^J! 
        Please add test file and log file at your report message!}% 
    \else
      \typeout{^^J! 
        Bitte ergaenzen Sie Beispiel- und LOG-Datei in der Meldung!}%
    \fi
    \pause
    \ifenglish
      \wmsg*{<REPLACE THIS BY YOUR TEST FILE>}
    \else
      \wmsg*{<HIER TESTDATEI EINFUEGEN>}
    \fi
  \else
    %%
    %% The example file goes here:
    %%
    \copytomsg{\samplefile}
    \ifnum\linecount>60
      \ifenglish
        \typeout{%
          ^^J%
          !!! Your test file has \the\linecount\space lines.^^J%
          !!! Large test files make it difficult to find the cause of the
          problem:^^J% 
          !!! ^^J%
          !!! Please decrease your test file as much as possible.^^J}
      \else
        \typeout{%
          ^^J%
          !!! Ihre Testdatei ist \the\linecount\space Zeilen lang.^^J%
          !!! So grosse Testdateien erschweren die Ursachenfindung:^^J%
          !!! ^^J%
          !!! Bitte verkleinern Sie Ihre Testdatei, soweit das ueberhaupt^^J%
          !!! moeglich ist, so dass das Problem gerade noch auftritt.^^J}
      \fi
      \pause
    \fi
  \fi
  \wmsg*{^^J%
    LOG-Datei vom LaTeX-Lauf der Beispieldatei:^^J%
    ===========================================}
  \ifx\logfile\undefinedcommand
    \ifenglish
      \typeout{^^J%
        Log file of your test file not found.^^J%
        Please add the log file of your test file at ``\jobname.msg''.}
     \wmsg*{<REPLACE THIS BY THE LOG OF YOUR TEST FILE>}
    \else
      \typeout{^^J%
        Log-Datei zur Testdatei nicht gefunden.^^J%
        Bitte ergaenzen Sie die LOG-Datei in ``\jobname.msg''.}
      \wmsg*{<HIER LOG ZUR TESTDATEI EINFUEGEN >}
    \fi
    \pause
  \else
    \copytomsg{\logfile}
  \fi
\or
  \wmsg{>Unterbereich: DOC-Fehler}
 \or
  \wmsg{>Unterbereich: Aenderungswunsch}
\fi
%%
%% Closing Banner.
%%
\typeout{^^J%
============================================================}
\ifinteractive
  \ifenglish
    \typeout{^^J%
      You may edit file ``\jobname.msg'' for additional changes.}
  \else
    \typeout{^^J%
      Weiteren Aenderungen koennen sie direkt in der Datei^^J%
      ``\jobname.msg'' mit Hilfe eines Editors vornehmen.}
  \fi
\else
  \ifenglish
    \typeout{^^J%
      The formular of the report will be saved to ``\jobname.msg''.^^J%
      Please use an editor to replace all information fields, before^^J%
      sending it.}
  \else
    \typeout{^^J%
      Das Formular fuer die Erstellung der Meldung wurde in die^^J%
      Datei ``\jobname.msg'' geschrieben, die Sie bitte mit Hilfe^^J%
      eines Editors ergaenzen, bevor Sie sie abschicken.}
  \fi
\fi
\let\ifinteractivetrue\iftrue
\ifenglish
  \typeout{^^J%
    Please send ``\jobname.msg'' to komascript@gmx.info using subject:^^J%
    \@spaces ``KOMA-BUG:\space\synopsis''^^J%
    ^^J%
    Thank you for spending time for a bug report.}
\else
  \typeout{^^J%
    Wenn Sie ueber eMail verfuegen, so senden Sie ``\jobname.msg''^^J%
    bitte an komascript@gmx.info.^^J%
    Verwenden Sie dabei bitte als Betreff (Subject):^^J%
    \@spaces ``KOMA-BUG:\space\synopsis''^^J%
    ^^J%
    Danke, dass Sie sich die Zeit genommen haben.}
\fi
\wmsg*{^^J%
  ============================================================^^J
  Ende der KOMA-Fehlermeldung.^^J%
  ============================================================}
%%
%% Close the .msg output stream.
%%
\immediate\closeout\msg
%%
%% This is the TeX primitive \end command.
%%
\@@end
%%% Local Variables: 
%%% mode: latex
%%% TeX-master: t
%%% End: 
 
     |