Show
Ignore:
Timestamp:
2000-06-16 03:21:34 (8 years ago)
Author:
Thomas Roessler <roessler@…>
Branch:
HEAD
Message:

patch-1.3.3.tlr.change_charset.1

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • compose.c

    r1903 r1915  
    387387} 
    388388 
    389 static int change_attachment_charset (BODY *b) 
    390 { 
    391   char buff[SHORT_STRING]; 
    392   iconv_t cd; 
    393  
    394   if (!mutt_is_text_type (b->type, b->subtype)) 
    395   { 
    396     mutt_error _("Can't change character set for non-text attachments!"); 
    397     return 0; 
    398   } 
    399  
    400   mutt_get_send_charset (buff, sizeof(buff), b, 0); 
    401    
    402   if (mutt_get_field (_("Enter character set: "), buff, sizeof(buff), 0) == -1) 
    403     return 0; 
    404  
    405   if ((cd = mutt_iconv_open (buff, "us-ascii")) == (iconv_t)-1) 
    406   { 
    407     mutt_error (_("Character set %s is unknown."), buff); 
    408     return 0; 
    409   } 
    410   else 
    411     iconv_close (cd); 
    412    
    413   mutt_set_body_charset (b, buff); 
    414   return REDRAW_CURRENT; 
    415 } 
    416389 
    417390/*  
     
    870843        break; 
    871844 
    872       case OP_COMPOSE_CHANGE_CHARSET: 
    873         CHECK_COUNT; 
    874         menu->redraw = change_attachment_charset(idx[menu->current]->content); 
    875         break; 
    876  
    877845#define CURRENT idx[menu->current]->content 
    878846