Ticket #3065: mc-3065-italic.patch

File mc-3065-italic.patch, 6.7 KB (added by egmont, 5 years ago)

Italic patch, updated

  • doc/man/mc.1.in

    diff --git a/doc/man/mc.1.in b/doc/man/mc.1.in
    index 79cad29..c5f8398 100644
    a b color16 to color255, or as rgb000 to rgb555 and gray0 to gray23. Example: 
    36093609base_color=normal=white,default:marked=magenta,default 
    36103610.fi 
    36113611.PP 
    3612 Attributes can be any of bold, underline, reverse and blink, appended by a 
     3612Attributes can be any of bold, italic, underline, reverse and blink, appended by a 
    36133613plus sign if more than one are desired.  The special word "none" means no 
    36143614attributes, without attempting to fall back to base_color.  Example: 
    36153615.PP 
  • doc/man/mcedit.1.in

    diff --git a/doc/man/mcedit.1.in b/doc/man/mcedit.1.in
    index f92ffc8..0a3044a 100644
    a b uses the color before the slash. See cooledit(1) for supported 
    439439.B cooledit 
    440440colors. 
    441441.PP 
    442 Attributes can be any of bold, underline, reverse and blink, appended by a 
     442Attributes can be any of bold, italic, underline, reverse and blink, appended by a 
    443443plus sign if more than one are desired. 
    444444.PP 
    445445Comments may be put on a separate line starting with the hash sign (#). 
  • doc/man/ru/mc.1.in

    diff --git a/doc/man/ru/mc.1.in b/doc/man/ru/mc.1.in
    index cb3c052..ebbec83 100644
    a b lightgray и white. Для прозрачного фона используют 
    39993999base_color=normal=white,default:marked=magenta,default 
    40004000.fi 
    40014001.PP 
    4002 Атрибуты обозначаются словами "bold", "underline", "reverse" и "blink". 
     4002Атрибуты обозначаются словами "bold", "italic", "underline", "reverse" и "blink". 
    40034003Чтобы использовать несколько атрибутов, их надо перечислить через символ "+". 
    40044004The special word "none" menas no attributes, without attempting to fall back 
    40054005to base_color. Пример: 
  • lib/tty/color-internal.c

    diff --git a/lib/tty/color-internal.c b/lib/tty/color-internal.c
    index 530313f..5ae389a 100644
    a b mc_tty_color_table_t const color_table[] = { 
    8383 
    8484mc_tty_color_table_t const attributes_table[] = { 
    8585    {"bold", A_BOLD}, 
     86#ifdef A_ITALIC                 /* available since ncurses-5.9-20130831 / slang-pre2.3.0-107 */ 
     87    {"italic", A_ITALIC}, 
     88#endif /* A_ITALIC */ 
    8689    {"underline", A_UNDERLINE}, 
    8790    {"reverse", A_REVERSE}, 
    8891    {"blink", A_BLINK}, 
  • lib/tty/color-slang.h

    diff --git a/lib/tty/color-slang.h b/lib/tty/color-slang.h
    index 86c79f0..a1a8d55 100644
    a b  
    1111/*** typedefs(not structures) and defined constants **********************************************/ 
    1212 
    1313/* When using Slang with color, we have all the indexes free but 
    14  * those defined here (A_BOLD, A_UNDERLINE, A_REVERSE, A_BLINK) 
     14 * those defined here (A_BOLD, A_ITALIC, A_UNDERLINE, A_REVERSE, A_BLINK) 
    1515 */ 
    1616 
    1717#ifndef A_BOLD 
    1818#define A_BOLD SLTT_BOLD_MASK 
    1919#endif /* A_BOLD */ 
     20#ifdef SLTT_ITALIC_MASK         /* available since slang-pre2.3.0-107 */ 
     21#ifndef A_ITALIC 
     22#define A_ITALIC SLTT_ITALIC_MASK 
     23#endif /* A_ITALIC */ 
     24#endif /* SLTT_ITALIC_MASK */ 
    2025#ifndef A_UNDERLINE 
    2126#define A_UNDERLINE SLTT_ULINE_MASK 
    2227#endif /* A_UNDERLINE */ 
  • misc/skins/sand256.ini

    diff --git a/misc/skins/sand256.ini b/misc/skins/sand256.ini
    index 5783e2d..83af5d1 100644
    a b  
    4747# 
    4848# Following the foreground and background colors, the third (optional) value 
    4949# can specify special attributes to enable. Valid values are bold, underline, 
    50 # reverse and blink. Append more with a plus sign, e.g. "underline+bold". 
     50# italic, reverse and blink. Append more with a plus sign, e.g. "bold+italic". 
    5151# Leaving the field empty makes it fall back to the attributes of _default_. 
    5252# Use any other word (e.g. "none") to prevent fallback and disable all flags. 
     53# 
     54# Italic support requires a recent enough ncurses (>= 5.9.20130831) or slang 
     55# (>= 2.3). All attributes are subject to support by the terminal emulator. 
    5356 
    5457[skin] 
    5558    description = Sand skin using 256 colors 
     
    8184[core] 
    8285    _default_ = black;rgb554 
    8386    selected = ;rgb452 
    84     marked = rgb400 
    85     markselect = rgb400;rgb452 
     87    marked = rgb400;;italic 
     88    markselect = rgb400;rgb452;italic 
    8689    gauge = ;rgb452 
    8790    input = ;rgb452 
    8891    inputunchanged = gray;rgb452 
     
    9093    disabled = gray;rgb553 
    9194    reverse = ;rgb452 
    9295    commandlinemark = white;gray 
    93     header = red 
     96    header = red;;italic 
    9497 
    9598[dialog] 
    9699    _default_ = black;rgb553 
    97100    dfocus = ;rgb452 
    98101    dhotnormal = ;;underline 
    99102    dhotfocus = ;rgb452;underline 
    100     dtitle = ;;underline 
     103    dtitle = ;;italic+underline 
    101104 
    102105[error] 
    103106    _default_ = rgb554;rgb320;bold 
     
    105108    errdfocus = rgb000;rgb452;bold 
    106109    errdhotnormal = ;;bold+underline 
    107110    errdhotfocus = rgb000;rgb452;bold+underline 
    108     errdtitle = ;;bold+underline 
     111    errdtitle = ;;bold+italic+underline 
    109112 
    110113[filehighlight] 
    111114    directory = 
     
    126129    database = rgb421 
    127130 
    128131[menu] 
    129     _default_ = black;rgb452 
     132    _default_ = black;rgb452;italic 
    130133    menusel = ;rgb551 
    131     menuhot = ;;underline 
    132     menuhotsel = ;rgb551;underline 
     134    menuhot = ;;italic+underline 
     135    menuhotsel = ;rgb551;italic+underline 
    133136    menuinactive = 
    134137 
    135138[popupmenu] 
    136139    _default_ = black;rgb553 
    137140    menusel = ;rgb452;underline 
    138     menutitle = ;;underline 
     141    menutitle = ;;italic+underline 
    139142 
    140143[buttonbar] 
    141     hotkey = black;rgb554 
    142     button = black;rgb452 
     144    hotkey = black;rgb554;italic 
     145    button = black;rgb452;italic 
    143146 
    144147[statusbar] 
    145     _default_ = black;rgb452 
     148    _default_ = black;rgb452;italic 
    146149 
    147150[help] 
    148151    _default_ = black;rgb553 
    149     helpitalic = green 
    150     helpbold = red 
     152    helpitalic = green;;italic 
     153    helpbold = red;;bold 
    151154    helplink = blue;;underline 
    152155    helpslink = blue;;reverse 
    153156    helptitle = ;;underline 
     
    155158[editor] 
    156159    _default_ = black;rgb554 
    157160    editbold = rgb400 
    158     editmarked = ;rgb452 
     161    editmarked = ;rgb452;italic 
    159162    editwhitespace = rgb400;rgb553 
    160163    editlinestate = ;rgb553 
    161164    bookmark = ;rgb551 
  • src/args.c

    diff --git a/src/args.c b/src/args.c
    index 300a3b0..e77be21 100644
    a b mc_args_new_color_group (void) 
    369369                                                    "Extended colors, when 256 colors are available:\n" 
    370370                                                    "   color16 to color255, or rgb000 to rgb555 and gray0 to gray23\n\n" 
    371371                                                    "Attributes:\n" 
    372                                                     "   bold, underline, reverse, blink; append more with '+'\n") 
     372                                                    "   bold, italic, underline, reverse, blink; append more with '+'\n") 
    373373                                                    ); 
    374374/* *INDENT-ON* */ 
    375375