1

Midnight Commander supports skins, where custom colors can be defined. I have created my own skin with custom colors. However, I am unable to change the color for the internal viewer (mcview). Whatever I define, my colors are being ignored and default colors are used instead.

snippet from my skin .ini file is below:

[core]
    _default_=lightgray;blue
    selected=black;cyan
    marked=yellow;blue
    .....

.....

[viewer]
    _default_=lightgray;black
    viewbold=yellow;blue
    viewunderline=brightred;blue
    viewselected=yellow;cyan

.....

The _default_ parameter in the [viewer] section is completely ignored. Whatever I put there, the displayed colors will be the ones defined in the '[core]' section (lightgray;blue). In other words, I am unable to override the default colors in mcview.

Can somebody please advise, how I can define different colors for the internal viewer?

Martin Vegter
  • 69
  • 66
  • 195
  • 326
  • 1
    Presuming everyone defines `_default_` first, `grep -C 3 _default_ /usr/share/mc/skins/*.ini | egrep -A 2 "viewer|core"` implies none of the stock skins try to set `viewer` differently than `core` here -- you could file it as a bug report. – goldilocks May 01 '14 at 11:44

2 Answers2

1

mcview has ugly blue/grey colors. It is possible to have better view with '-b' option. I added to my ~/.bash_aliases

alias mc='mc -b'

and this makes mcview to show text in black and white mode.

youni
  • 26
  • 3
  • This does not provide an answer to the question. Once you have sufficient [reputation](https://unix.stackexchange.com/help/whats-reputation) you will be able to [comment on any post](https://unix.stackexchange.com/help/privileges/comment); instead, [provide answers that don't require clarification from the asker](https://meta.stackexchange.com/questions/214173/why-do-i-need-50-reputation-to-comment-what-can-i-do-instead). - [From Review](/review/late-answers/440755) – Peregrino69 Mar 18 '23 at 14:31
0

Yes, mcview does not react on color settings (it is a bug). Use another viewer, disable internal viewer in the Menu: Options (F9) -> Configuration -> uncheck Use internal view or type ~/.config/mc/ini and find line 'use_internal_view=' and type 'false' there.

Your external viewer it is "VIEWER" environment variable which you can set up in .bashrc like 'VIEWER=vim' or run mc like this: 'VIEWER=vim' mc

How to set default editor/viewer for Midnight Commander to Sublime

znavko
  • 43
  • 1
  • 6