--- test/html-webhacc/WebHACC/Result.pm 2008/08/14 15:50:42 1.9 +++ test/html-webhacc/WebHACC/Result.pm 2008/08/15 12:11:56 1.12 @@ -52,6 +52,7 @@ my ($self, %opt) = @_; my $out = $self->output; + $out->has_error (1); my $error_level = $opt{level}; if (not defined $error_level) { @@ -80,8 +81,6 @@ $error_layer = 'syntax'; ## NOTE: Unknown - an error of the implementation } - my $error_type_text = $opt{type}; - my $class = qq[level-$error_level layer-$error_layer]; ## Line & column numbers (prepare values) @@ -193,7 +192,7 @@ } unless ($has_location) { - $out->text ('Unknown location'); + $out->nl_text ('Unknown location'); } } @@ -204,10 +203,11 @@ $out->text (': '); ## Error message + my $error_type_text = $opt{type}; $out->nl_text ($error_type_text, node => $opt{node}, text => $opt{text}); ## Additional error description - if (defined $opt{text}) { + if (defined $opt{text}) { ## TODO: Remove this block once all errors are put into the catalog. $out->html (' ('); $out->text ($opt{text}); $out->html (')'); @@ -287,22 +287,22 @@ $out->start_tag ('th', colspan => 7, scope => 'col'); $out->nl_text ('Main document'); }, - {label => 'Transfer', status => $self->{layers}->{transfer}, + {label => 'Transfer L.', status => $self->{layers}->{transfer}, target => 'transfer-errors', score_base => 20, parent_status => $maindoc_status}, - {label => 'Encode', status => $self->{layers}->{encode}, - score_base => 10, + {label => 'Encode L.', status => $self->{layers}->{encode}, + target => 'parse-errors', score_base => 10, parent_status => $maindoc_status}, - {label => 'Charset', status => $self->{layers}->{charset}, + {label => 'Char L.', status => $self->{layers}->{charset}, score_base => 10, parent_status => $maindoc_status}, - {label => 'Syntax', status => $self->{layers}->{syntax}, + {label => 'Syntax L.', status => $self->{layers}->{syntax}, target => 'parse-errors', score_base => 20, parent_status => $maindoc_status}, - {label => 'Structure', status => $self->{layers}->{structure}, + {label => 'Structure L.', status => $self->{layers}->{structure}, target => 'document-errors', score_base => 20, parent_status => $maindoc_status}, - {label => 'Semantics', status => $self->{layers}->{semantics}, + {label => 'Semantics L.', status => $self->{layers}->{semantics}, score_base => 20, parent_status => $maindoc_status}, );