]> git.pld-linux.org Git - packages/mutt.git/blobdiff - mutt-folder_columns.patch
- add mutt-long-lines.patch to allow reading mails with long lines
[packages/mutt.git] / mutt-folder_columns.patch
index 59ffc402c07f891487317f595b06ba6142c23a10..c4648244fbeeb4874c7b2aa2233b626b842f186c 100644 (file)
@@ -1,16 +1,6 @@
---- mutt-1.3.23-orig/mutt_menu.h       Sun Oct 28 19:35:26 2001
-+++ mutt-1.3.23/mutt_menu.h    Tue Oct 30 16:45:06 2001
-@@ -45,6 +45,7 @@
-   int menu;   /* menu definition for keymap entries. */
-   int offset; /* which screen row to start the index */
-   int pagelen;        /* number of entries per screen */
-+  int columns;  /* number of columns in menu */
-   int tagprefix;
-   /* Setting dialog != NULL overrides normal menu behaviour. 
---- mutt-1.3.23-orig/init.h    Sun Oct 28 19:35:26 2001
-+++ mutt-1.3.23/init.h Tue Oct 30 22:49:46 2001
-@@ -499,6 +499,12 @@
+--- mutt-1.4-orig/init.h       2002-04-25 15:26:37.000000000 +0200
++++ mutt-1.4/init.h    2003-01-26 19:33:40.000000000 +0100
+@@ -519,6 +519,12 @@
    ** you use `+' or `=' for any other variables since expansion takes place
    ** during the `set' command.
    */
@@ -23,9 +13,9 @@
    { "folder_format",  DT_STR,  R_INDEX, UL &FolderFormat, UL "%2C %t %N %F %2l %-8.8u %-8.8g %8s %d %f" },
    /*
    ** .pp
---- mutt-1.3.23-orig/globals.h Sun Oct 28 19:35:26 2001
-+++ mutt-1.3.23/globals.h      Tue Oct 30 22:44:42 2001
-@@ -138,6 +138,7 @@
+--- mutt-1.4-orig/globals.h    2002-01-03 21:57:19.000000000 +0100
++++ mutt-1.4/globals.h 2003-01-26 19:34:05.000000000 +0100
+@@ -143,6 +143,7 @@
  WHERE unsigned short Counter INITVAL (0);
  
  WHERE short ConnectTimeout;
  WHERE short HistSize;
  WHERE short PagerContext;
  WHERE short PagerIndexLines;
---- mutt-1.3.23-orig/browser.c Sun Oct 28 19:35:26 2001
-+++ mutt-1.3.23/browser.c      Tue Oct 30 22:44:18 2001
-@@ -476,12 +476,13 @@
+--- mutt-1.4-orig/mutt_menu.h  2001-09-11 13:20:34.000000000 +0200
++++ mutt-1.4/mutt_menu.h       2003-01-26 19:33:01.000000000 +0100
+@@ -45,6 +45,7 @@
+   int menu;   /* menu definition for keymap entries. */
+   int offset; /* which screen row to start the index */
+   int pagelen;        /* number of entries per screen */
++      int columns;  /* number of columns in menu */
+   int tagprefix;
+   /* Setting dialog != NULL overrides normal menu behaviour. 
+--- mutt-1.4-orig/browser.c    2002-03-19 10:54:00.000000000 +0100
++++ mutt-1.4/browser.c 2003-01-26 19:35:34.000000000 +0100
+@@ -476,12 +476,14 @@
  }
  
  static void init_menu (struct browser_state *state, MUTTMENU *menu, char *title,
    char path[_POSIX_PATH_MAX];
  
    menu->max = state->entrylen;
--
-+  menu->columns = columns;  
-+  
++  menu->columns = columns;
++      
    if(menu->current >= menu->max)
      menu->current = menu->max - 1;
    if (menu->current < 0)
-@@ -634,7 +635,7 @@
+@@ -636,7 +638,7 @@
    menu->help = mutt_compile_help (helpstr, sizeof (helpstr), MENU_FOLDER,
      FolderHelp);
  
@@ -60,7 +60,7 @@
  
    FOREVER
    {
-@@ -765,7 +766,7 @@
+@@ -767,7 +769,7 @@
            }
            menu->current = 0; 
            menu->top = 0; 
@@ -69,7 +69,7 @@
            break;
          }
        }
-@@ -863,7 +864,7 @@
+@@ -865,7 +867,7 @@
          menu->data = state.entry;
          menu->current = 0; 
          menu->top = 0; 
@@ -78,7 +78,7 @@
          MAYBE_REDRAW (menu->redraw);
        }
        break;
-@@ -893,7 +894,7 @@
+@@ -895,7 +897,7 @@
                    sizeof (struct folder_file) * (state.entrylen - (nentry+1)));
              state.entrylen--;
              mutt_message _("Mailbox deleted.");
@@ -87,7 +87,7 @@
              MAYBE_REDRAW (menu->redraw);
            }
          }
-@@ -933,7 +934,7 @@
+@@ -935,7 +937,7 @@
            menu->data = state.entry;
            menu->current = 0; 
            menu->top = 0; 
@@ -96,7 +96,7 @@
          }
          else
  #endif
-@@ -947,7 +948,7 @@
+@@ -949,7 +951,7 @@
              {
                menu->current = 0; 
                menu->top = 0; 
              }
              else
              {
-@@ -1010,12 +1011,12 @@
+@@ -1012,12 +1014,12 @@
              state.imap_browse = 1;
              imap_browse (LastDir, &state);
              menu->data = state.entry;
            else
            {
              mutt_error _("Error scanning directory.");
-@@ -1099,7 +1100,7 @@
+@@ -1101,7 +1103,7 @@
  #endif
        else if (examine_directory (menu, &state, LastDir, prefix) == -1)
          goto bail;
        break;
  
        case OP_BROWSER_NEW_FILE:
---- mutt-1.3.23-orig/menu.c    Sun Oct 28 19:35:26 2001
-+++ mutt-1.3.23/menu.c Wed Oct 31 09:30:28 2001
-@@ -126,14 +126,14 @@
+--- mutt-1.4.2.1/menu.c.orig   2004-02-14 17:54:37.148495120 +0100
++++ mutt-1.4.2.1/menu.c        2004-02-14 17:55:46.357973680 +0100
+@@ -148,7 +148,7 @@
      menu->make_entry (s, l, menu, i);
  }
  
--void menu_pad_string (char *s, size_t l)
-+void menu_pad_string (MUTTMENU *menu, char *s, size_t l)
+-void menu_pad_string (char *s, size_t n)
++void menu_pad_string (MUTTMENU *menu, char *s, size_t n)
  {
-   size_t n = mutt_strlen (s);
    int shift = option (OPTARROWCURSOR) ? 3 : 0;
-   
-   l--; /* save room for the terminal \0 */
--  if (l > COLS - shift)
--    l = COLS - shift;
-+  if (l > (COLS / menu->columns) - shift)
-+    l = (COLS / menu->columns) - shift;
-   /* Let's just pad the string anyway ... */
-   mutt_format_string (s, INT_MAX, l, l, 0, ' ', s, n, 1);
-@@ -191,69 +191,89 @@
+   int cols = COLS - shift;
+@@ -196,69 +196,89 @@
    menu->redraw &= ~REDRAW_STATUS;
  }
  
 -        addstr ("->");
 -          attrset (menu->color (i));
 -        addch (' ');
+-      }
+-      else
+-        move (i - menu->top + menu->offset, 3);
 +              menu_item_pos(menu, i, &row, &col);
 +              if (i < menu->max)
 +          {
 +                      menu_make_entry (buf, sizeof (buf), menu, i);
 +                      menu_pad_string (menu, buf, sizeof (buf));
-+
+-        print_enriched_string (menu->color(i), (unsigned char *) buf, 1);
+-        SETCOLOR (MT_COLOR_NORMAL);          
+-      }
+-      else
+-      {
+-      if (i == menu->current)
+-      {
+-        SETCOLOR (MT_COLOR_INDICATOR);
+-        BKGDSET (MT_COLOR_INDICATOR);
 +                      if (option (OPTARROWCURSOR))
 +                      {
 +                              attrset (menu->color (i));
 +                      }
 +              }
        }
--      else
--        move (i - menu->top + menu->offset, 3);
--
--        print_enriched_string (menu->color(i), (unsigned char *) buf, 1);
--        SETCOLOR (MT_COLOR_NORMAL);          
--      }
--      else
--      {
--      if (i == menu->current)
--      {
--        SETCOLOR (MT_COLOR_INDICATOR);
--        BKGDSET (MT_COLOR_INDICATOR);
--      }
 -        else
 -          attrset (menu->color (i));
 -            
    SETCOLOR (MT_COLOR_NORMAL);
    BKGDSET (MT_COLOR_NORMAL);
  
-@@ -265,16 +285,18 @@
+@@ -270,16 +290,18 @@
  
      if (menu->redraw & REDRAW_MOTION_RESYNCH)
      {
      SETCOLOR (MT_COLOR_INDICATOR);
      addstr ("->");
      SETCOLOR (MT_COLOR_NORMAL);
-@@ -283,17 +305,19 @@
+@@ -288,17 +310,19 @@
    {
      /* erase the current indicator */
      attrset (menu->color (menu->oldcurrent));
      print_enriched_string (menu->color(menu->current), (unsigned char *) buf, 0);
      SETCOLOR (MT_COLOR_NORMAL);
      BKGDSET (MT_COLOR_NORMAL);
-@@ -304,21 +328,22 @@
+@@ -309,21 +333,22 @@
  void menu_redraw_current (MUTTMENU *menu)
  {
    char buf[STRING];
      print_enriched_string (menu->color(menu->current), (unsigned char *) buf, 1);
      SETCOLOR (MT_COLOR_NORMAL);
    }
-@@ -326,7 +351,7 @@
+@@ -331,7 +356,7 @@
    {
      SETCOLOR (MT_COLOR_INDICATOR);
      BKGDSET (MT_COLOR_INDICATOR);
      print_enriched_string (menu->color(menu->current), (unsigned char *) buf, 0);
      SETCOLOR (MT_COLOR_NORMAL);
      BKGDSET (MT_COLOR_NORMAL);
-@@ -355,18 +380,18 @@
+@@ -360,18 +385,18 @@
  
  void menu_check_recenter (MUTTMENU *menu)
  {
      menu->redraw |= REDRAW_INDEX;
    }
    else if (menu->current < menu->top)
-@@ -375,7 +400,7 @@
+@@ -380,7 +405,7 @@
        menu->top = menu->current;
      else
      {
        if (menu->top < 0)
        menu->top = 0;
      }
-@@ -666,6 +691,7 @@
+@@ -671,6 +696,7 @@
    p->pagelen = PAGELEN;
    p->color = default_color;
    p->search = menu_search_generic;
This page took 0.048059 seconds and 4 git commands to generate.