Corretta la lettura della sezione general di un form:
chiamava popkey() anziche' key(), per cui sbagliava se effettuava piu' di un ciclo. git-svn-id: svn://10.65.10.50/trunk@3393 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
9b719fb694
commit
bd3fef754a
@ -3128,36 +3128,27 @@ bool TForm::parse_general(TScanner &scanner)
|
||||
{
|
||||
while (scanner.pop() != "END")
|
||||
{
|
||||
if (scanner.popkey() == "OF") // Offsets
|
||||
if (scanner.key() == "OF") // Offsets
|
||||
{
|
||||
_x = scanner.integer();
|
||||
_y = scanner.integer();
|
||||
}
|
||||
else scanner.push();
|
||||
if (scanner.popkey() == "FO") // Font name
|
||||
if (scanner.key() == "FO") // Font name
|
||||
_fontname = scanner.string();
|
||||
else scanner.push();
|
||||
if (scanner.popkey() == "SI") // Font size
|
||||
if (scanner.key() == "SI") // Font size
|
||||
_fontsize = scanner.integer();
|
||||
else scanner.push();
|
||||
if (scanner.popkey() == "CA") // Carattere di posizionamento
|
||||
if (scanner.key() == "CA") // Carattere di posizionamento
|
||||
_char_to_pos = scanner.string()[0];
|
||||
else scanner.push();
|
||||
if (scanner.popkey() == "IN") // Riga e colonna del posizionamento iniziale
|
||||
if (scanner.key() == "IN") // Riga e colonna del posizionamento iniziale
|
||||
{
|
||||
_ipx = scanner.integer();
|
||||
_ipy = scanner.integer();
|
||||
}
|
||||
else scanner.push();
|
||||
if (scanner.popkey() == "FI") // Riga e colonna del posizionamento finale
|
||||
{
|
||||
if (scanner.key() == "FI") // Riga e colonna del posizionamento finale
|
||||
_fpx = scanner.integer();
|
||||
}
|
||||
else scanner.push();
|
||||
|
||||
if (scanner.popkey() == "GR") // Carattere di posizionamento
|
||||
if (scanner.key() == "GR") // Carattere di posizionamento
|
||||
set_fincatura(scanner.string());
|
||||
else scanner.push();
|
||||
|
||||
extended_parse_general(scanner); // Parse non-standard parameters
|
||||
}
|
||||
@ -4245,6 +4236,7 @@ void TForm::read(
|
||||
|
||||
// read base form
|
||||
TFilename n(_name); n.ext("frm");
|
||||
if (!fexist(n)) fatal_box("Il file %s non esiste.",(const char *) n);
|
||||
TScanner scanner(n);
|
||||
|
||||
bool ok = TRUE;
|
||||
|
Loading…
x
Reference in New Issue
Block a user