projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Updated the Lithuanian translation from http://translationproject.org.
[pspp]
/
src
/
output
/
html.c
diff --git
a/src/output/html.c
b/src/output/html.c
index 4a436cf53c34b8f171dfbadd2f2c409af1982be1..5aec959c740a16a69888d9f5da76ad2d56778528 100644
(file)
--- a/
src/output/html.c
+++ b/
src/output/html.c
@@
-103,7
+103,7
@@
html_create (const char *file_name, enum settings_output_devices device_type,
html->file = fn_open (html->file_name, "w");
if (html->file == NULL)
{
html->file = fn_open (html->file_name, "w");
if (html->file == NULL)
{
- error (0, errno, _("error opening output file
\"%s\"
"), html->file_name);
+ error (0, errno, _("error opening output file
`%s'
"), html->file_name);
goto error;
}
goto error;
}
@@
-116,8
+116,8
@@
html_create (const char *file_name, enum settings_output_devices device_type,
fputs ("<META http-equiv=\"Content-Style-Type\" content=\"text/css\">\n",
html->file);
fputs ("<META HTTP-EQUIV=\"Content-Type\" "
fputs ("<META http-equiv=\"Content-Style-Type\" content=\"text/css\">\n",
html->file);
fputs ("<META HTTP-EQUIV=\"Content-Type\" "
- "CONTENT=\"text/html; charset=
ISO-8859-1
\">\n", html->file);
- fputs ("<STYLE>\n"
+ "CONTENT=\"text/html; charset=
utf-8
\">\n", html->file);
+ fputs ("<STYLE
TYPE=\"text/css\"
>\n"
"<!--\n"
"body {\n"
" background: white;\n"
"<!--\n"
"body {\n"
" background: white;\n"
@@
-243,6
+243,7
@@
html_submit (struct output_driver *driver,
struct table_item *table_item = to_table_item (output_item);
html_output_table (html, table_item);
}
struct table_item *table_item = to_table_item (output_item);
html_output_table (html, table_item);
}
+#ifdef HAVE_CAIRO
else if (is_chart_item (output_item) && html->chart_file_name != NULL)
{
struct chart_item *chart_item = to_chart_item (output_item);
else if (is_chart_item (output_item) && html->chart_file_name != NULL)
{
struct chart_item *chart_item = to_chart_item (output_item);
@@
-252,10
+253,13
@@
html_submit (struct output_driver *driver,
html->chart_cnt++);
if (file_name != NULL)
{
html->chart_cnt++);
if (file_name != NULL)
{
- fprintf (html->file, "<IMG SRC=\"%s\"/>", file_name);
+ const char *title = chart_item_get_title (chart_item);
+ fprintf (html->file, "<IMG SRC=\"%s\" ALT=\"Chart: %s\">",
+ file_name, title ? title : _("No description"));
free (file_name);
}
}
free (file_name);
}
}
+#endif /* HAVE_CAIRO */
else if (is_text_item (output_item))
{
struct text_item *text_item = to_text_item (output_item);
else if (is_text_item (output_item))
{
struct text_item *text_item = to_text_item (output_item);
@@
-416,16
+420,16
@@
html_output_table (struct html_driver *html, struct table_item *item)
alignment = cell.options & TAB_ALIGNMENT;
if (alignment != TAB_LEFT)
alignment = cell.options & TAB_ALIGNMENT;
if (alignment != TAB_LEFT)
- fprintf (html->file, " ALIGN=
%s
",
+ fprintf (html->file, " ALIGN=
\"%s\"
",
alignment == TAB_RIGHT ? "RIGHT" : "CENTER");
colspan = table_cell_colspan (&cell);
if (colspan > 1)
alignment == TAB_RIGHT ? "RIGHT" : "CENTER");
colspan = table_cell_colspan (&cell);
if (colspan > 1)
- fprintf (html->file, " COLSPAN=
%d
", colspan);
+ fprintf (html->file, " COLSPAN=
\"%d\"
", colspan);
rowspan = table_cell_rowspan (&cell);
if (rowspan > 1)
rowspan = table_cell_rowspan (&cell);
if (rowspan > 1)
- fprintf (html->file, " ROWSPAN=
%d
", rowspan);
+ fprintf (html->file, " ROWSPAN=
\"%d\"
", rowspan);
/* Cell borders. */
n_borders = 0;
/* Cell borders. */
n_borders = 0;