[w3m-dev 03577] incorrect table width

* table.c (dv2sv): fix move direction
	(set_integered_width): ditto
	(check_table_height): ditto
	(feed_table_tag): ditto
From: Hironori SAKAMOTO <hsaka@mth.biglobe.ne.jp>
This commit is contained in:
Fumitoshi UKAI
2002-12-17 16:17:28 +00:00
parent aec3cd7cc6
commit 4e52a4adb4
2 changed files with 18 additions and 10 deletions
+9 -1
View File
@@ -1,3 +1,11 @@
2002-12-18 Hironori SAKAMOTO <hsaka@mth.biglobe.ne.jp>
* [w3m-dev 03577] incorrect table width
* table.c (dv2sv): fix move direction
(set_integered_width): ditto
(check_table_height): ditto
(feed_table_tag): ditto
2002-12-17 Hironori SAKAMOTO <hsaka@mth.biglobe.ne.jp> 2002-12-17 Hironori SAKAMOTO <hsaka@mth.biglobe.ne.jp>
* [w3m-dev 03576] Re: news support * [w3m-dev 03576] Re: news support
@@ -5889,4 +5897,4 @@ a * [w3m-dev 03276] compile error on EWS4800
* release-0-2-1 * release-0-2-1
* import w3m-0.2.1 * import w3m-0.2.1
$Id: ChangeLog,v 1.626 2002/12/16 15:41:03 ukai Exp $ $Id: ChangeLog,v 1.627 2002/12/17 16:17:28 ukai Exp $
+9 -9
View File
@@ -1,4 +1,4 @@
/* $Id: table.c,v 1.36 2002/12/06 16:50:41 ukai Exp $ */ /* $Id: table.c,v 1.37 2002/12/17 16:17:30 ukai Exp $ */
/* /*
* HTML table * HTML table
*/ */
@@ -252,8 +252,8 @@ dv2sv(double *dv, short *iv, int size)
i = bsearch_double(x, edv, indexarray, k); i = bsearch_double(x, edv, indexarray, k);
if (k > i) { if (k > i) {
int ii; int ii;
for (ii = i; ii < k; ii++) for (ii = k; ii > i; ii--)
indexarray[ii + 1] = indexarray[ii]; indexarray[ii] = indexarray[ii - 1];
} }
indexarray[i] = k; indexarray[i] = k;
} }
@@ -1007,8 +1007,8 @@ set_integered_width(struct table *t, double *dwidth, short *iwidth)
i = bsearch_double(x, mod, indexarray, k); i = bsearch_double(x, mod, indexarray, k);
if (k > i) { if (k > i) {
int ii; int ii;
for (ii = i; ii < k; ii++) for (ii = k; ii > i; ii--)
indexarray[ii + 1] = indexarray[ii]; indexarray[ii] = indexarray[ii - 1];
} }
indexarray[i] = k; indexarray[i] = k;
} }
@@ -1594,8 +1594,8 @@ check_table_height(struct table *t)
cell.height[cell.maxcell] = 0; cell.height[cell.maxcell] = 0;
if (cell.maxcell > k) { if (cell.maxcell > k) {
int ii; int ii;
for (ii = k; ii < cell.maxcell; ii++) for (ii = cell.maxcell; ii > k; ii--)
cell.indexarray[ii + 1] = cell.indexarray[ii]; cell.indexarray[ii] = cell.indexarray[ii - 1];
} }
cell.indexarray[k] = cell.maxcell; cell.indexarray[k] = cell.maxcell;
} }
@@ -2727,8 +2727,8 @@ feed_table_tag(struct table *tbl, char *line, struct table_mode *mode,
cell->fixed_width[cell->maxcell] = 0; cell->fixed_width[cell->maxcell] = 0;
if (cell->maxcell > k) { if (cell->maxcell > k) {
int ii; int ii;
for (ii = k; ii < cell->maxcell; ii++) for (ii = cell->maxcell; ii > k; ii--)
cell->index[ii + 1] = cell->index[ii]; cell->index[ii] = cell->index[ii - 1];
} }
cell->index[k] = cell->maxcell; cell->index[k] = cell->maxcell;
} }