Commit 58f4dd19 authored by Jody Goldberg's avatar Jody Goldberg Committed by Jody Goldberg

Adjsut XL import of row height to include margins. Heights

should match exactly now.

2000-02-14  Jody Goldberg <jgoldberg@home.com>

	* src/format.c (format_value) : Empty formats produce empty cells.

	* src/workbook.c (workbook_menu_tools) : Move the plugins menu item to
	  the Tools menu.
parent a67a3eee
2000-02-14 Jody Goldberg <jgoldberg@home.com>
* src/format.c (format_value) : Empty formats produce empty cells.
* src/workbook.c (workbook_menu_tools) : Move the plugins menu item to
the Tools menu.
2000-02-14 Jukka-Pekka Iivonen <iivonen@iki.fi>
* src/dialogs/analysis-tools.glade, src/analysis-tools.c,
......
2000-02-14 Jody Goldberg <jgoldberg@home.com>
* src/format.c (format_value) : Empty formats produce empty cells.
* src/workbook.c (workbook_menu_tools) : Move the plugins menu item to
the Tools menu.
2000-02-14 Jukka-Pekka Iivonen <iivonen@iki.fi>
* src/dialogs/analysis-tools.glade, src/analysis-tools.c,
......
......@@ -17,8 +17,8 @@ Description Difficulty Integration
functions to samples/regress.gnumeric so we can be
sure that we are returning the right error code.
- libgladeify the pluging manager dialog and move it Low Low
into the dialogs directory.
- libgladeify the pluging manager dialog and move the Low Low
UI into the dialogs directory.
- Enhance plugin interface and manager to supply Medium Medium
descriptive information about the plugin, and allow
......@@ -27,6 +27,7 @@ Description Difficulty Integration
- Add tooltips for colours in
src/widgets/widget-color-combo.c Low Low.
Have a look at widget-pixmap-combo.c for an example.
- Save/Restore the values of the last selected colours Low Low.
from the toolbar for background or font.
......
2000-02-14 Jody Goldberg <jgoldberg@home.com>
* ms-excel-read.c (ms_excel_read_row) : heights are specified
including margins and 1 grid line. Do not use get_units_net_of_margins.
(get_units_net_of_margins) : Delete.
2000-02-13 Jody Goldberg <jgoldberg@home.com>
* ms-excel-read.c (ms_excel_read_workbook) : Adjust WINDOW size
......
......@@ -2445,28 +2445,6 @@ get_row_height_units (guint16 height)
return 1. / 20. * height;
}
/**
* get_units_net_of_margins:
* @units A dimension in points
* @cri A ColRowInfo for a row or column.
*
* Converts an external (with margins) row height/column width in
* points to an internal (without margins) height/width, as this is
* what the sheet_<foo>_set_{width|height}_units functions
* want. Returns internal dimension.
*/
static double
get_units_net_of_margins (double units, const ColRowInfo * cri)
{
/* Return an arbitary non 0 value on catastrophic failure */
g_return_val_if_fail (cri != NULL, 1.);
units -= (cri->margin_a + cri->margin_b + 1);
if (units < 0)
units = 1.;
return units;
}
/**
* ms_excel_read_row:
* @q A BIFF query
......@@ -2504,10 +2482,6 @@ ms_excel_read_row (BiffQuery *q, ExcelSheet *sheet)
*/
if (!is_std_height) {
double hu = get_row_height_units (height);
/* Subtract margins */
hu = get_units_net_of_margins
(hu, sheet_row_get_info (sheet->gnum_sheet, row));
sheet_row_set_size_pts (sheet->gnum_sheet, row, hu, TRUE);
}
......@@ -3901,6 +3875,9 @@ ms_excel_read_workbook (CommandContext *context, Workbook *workbook,
/* FIXME FIXME FIXME :
* We are sizing the window including the toolbars,
* menus, and notbook tabs. Excel does not.
*
* NOTE : This is the size of the MDI sub-window, not the size of
* the containing excel window.
*/
workbook_view_set_size (wb->gnum_wb,
.5 + width *
......
......@@ -1338,9 +1338,11 @@ format_value (StyleFormat *format, const Value *value, StyleColor **color)
}
}
if (entry.format [0] == 0)
is_general = 1;
else if (strcmp (entry.format, "General") == 0) {
/* Empty formats should be ignored */
if (entry.format [0] == '\0')
return g_strdup ("");
if (strcmp (entry.format, "General") == 0) {
entry.format += 7;
is_general = 1;
}
......
......@@ -585,10 +585,8 @@ item_bar_event (GnomeCanvasItem *item, GdkEvent *e)
gnome_canvas_request_redraw (
canvas, 0, 0, INT_MAX, INT_MAX);
}
else if (ITEM_BAR_IS_SELECTING (item_bar))
} else if (ITEM_BAR_IS_SELECTING (item_bar))
{
element = get_col_from_pos (item_bar, pos);
gtk_signal_emit (
......@@ -597,8 +595,7 @@ item_bar_event (GnomeCanvasItem *item, GdkEvent *e)
element, 0);
set_cursor (item_bar, pos);
}
else
} else
set_cursor (item_bar, pos);
break;
......
......@@ -3651,9 +3651,9 @@ void
sheet_row_set_default_size_pts (Sheet *sheet, double height_pts,
gboolean thick_a, gboolean thick_b)
{
/* Why XL chooses to be asymetric I don't know */
int a = 1; /* FIXME : This should be 3 */
int b = 0;
/* There are an addition few pixels above due the the fonts ascent */
int a = 1;
int b = 0; /* Why XL chooses to be asymetric I don't know */
if (thick_a) ++a;
if (thick_b) ++b;
......
......@@ -1048,11 +1048,6 @@ static GnomeUIInfo workbook_menu_file [] = {
GNOMEUIINFO_SEPARATOR,
{ GNOME_APP_UI_ITEM, N_("Plu_g-ins..."), N_("Gnumeric plugins"),
plugins_cmd },
GNOMEUIINFO_SEPARATOR,
GNOMEUIINFO_MENU_PRINT_SETUP_ITEM(print_setup_cmd, NULL),
GNOMEUIINFO_MENU_PRINT_ITEM(file_print_cmd, NULL),
{ GNOME_APP_UI_ITEM, N_("Print pre_view"), N_("Print preview"),
......@@ -1248,6 +1243,11 @@ static GnomeUIInfo workbook_menu_format [] = {
/* Tools menu */
static GnomeUIInfo workbook_menu_tools [] = {
{ GNOME_APP_UI_ITEM, N_("Plu_g-ins..."), N_("Gnumeric plugins"),
plugins_cmd },
GNOMEUIINFO_SEPARATOR,
{ GNOME_APP_UI_ITEM, N_("Auto _Correct..."), N_("Auto Correct"),
autocorrect_cmd },
{ GNOME_APP_UI_ITEM, N_("_Auto Save..."), N_("Auto Save"),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment