Bug#139781: dpkg: Screen width limited to 179 chars
On Mon, Mar 25, 2002 at 01:31:37AM +0100, Jeroen T. Vermeulen wrote:
> Package: dpkg
> Version: 1.9.20
> Severity: minor
> File: /usr/bin/dselect
>
> The dselect text UI doesn't seem to use the full width of the window
> it's running in beyond the first 179 characters.
Here's a patch:
Index: methlist.cc
===================================================================
RCS file: /cvs/dpkg/dpkg/dselect/methlist.cc,v
retrieving revision 1.11
diff -p -u -r1.11 methlist.cc
--- methlist.cc 2 Sep 2002 06:51:14 -0000 1.11
+++ methlist.cc 19 Feb 2004 17:47:39 -0000
@@ -66,6 +66,8 @@ void methodlist::setwidths() {
description_column= name_column + name_width + gap_width;
total_width= TOTAL_LIST_WIDTH;
+ if (total_width < COLS)
+ total_width= COLS;
description_width= total_width - description_column;
}
Index: pkgdisplay.cc
===================================================================
RCS file: /cvs/dpkg/dpkg/dselect/pkgdisplay.cc,v
retrieving revision 1.12
diff -p -u -r1.12 pkgdisplay.cc
--- pkgdisplay.cc 2 Sep 2002 06:51:14 -0000 1.12
+++ pkgdisplay.cc 19 Feb 2004 17:47:39 -0000
@@ -185,6 +185,8 @@ void packagelist::setwidths() {
}
total_width= TOTAL_LIST_WIDTH;
+ if (total_width < COLS)
+ total_width= COLS;
description_width= total_width - description_column;
}
Cheers,
--
Colin Watson [cjwatson@flatline.org.uk]
Reply to: