Sfoglia il codice sorgente

Apply patch from Colin Watson to fix #139781; dselect had a
hard-coded maximum window width of 179 chars for some things,
when COLS is easily available.

Scott James Remnant 22 anni fa
parent
commit
0b40f4d5c4
4 ha cambiato i file con 11 aggiunte e 0 eliminazioni
  1. 6 0
      ChangeLog
  2. 1 0
      debian/changelog
  3. 2 0
      dselect/methlist.cc
  4. 2 0
      dselect/pkgdisplay.cc

+ 6 - 0
ChangeLog

@@ -1,3 +1,9 @@
+Mon Mar  8 10:14:27 GMT 2004 Colin Watson <cjwatson@debian.org>
+ 
+  * dselect/methlist.cc, dselect/pkgdisplay.cc: Set the total display width
+  to the maximum of TOTAL_LIST_WIDTH and COLS, improving display on wide
+  terminals.
+
 Thu Mar  4 13:28:11 GMT 2004 Scott James Remnant <scott@netsplit.com>
 
   * lib/tarfn.c: Copy the Name and LinkName elements and ensure they

+ 1 - 0
debian/changelog

@@ -3,6 +3,7 @@ dpkg (1.10.19) unstable; urgency=low
   * Distinguish unmet build dependencies from build conflicts.
     Closes: #217943, #235266.
   * Force NULL-termination of all tar file entry names.  Closes: #232025.
+  * Allow dselect to use the full window width.  Closes: #139781.
 
  -- Scott James Remnant <scott@netsplit.com>  UNRELEASED
 

+ 2 - 0
dselect/methlist.cc

@@ -67,6 +67,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;
 }
 

+ 2 - 0
dselect/pkgdisplay.cc

@@ -186,6 +186,8 @@ void packagelist::setwidths() {
   }
     
   total_width= TOTAL_LIST_WIDTH;
+  if (total_width < COLS)
+    total_width= COLS;
   description_width= total_width - description_column;
 }