LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-13-2011, 10:41 AM   #1
Tim Johnson
Member
 
Registered: Oct 2004
Location: Palmer, Alaska
Distribution: ubuntu 10.04, Slack 13.0/32-bit
Posts: 206

Rep: Reputation: 30
Howto to use ImageMagick as default Jpeg viewer for Midnight Commander


I'm using Midnight Commander mc 4.7.0.6 on a new Mint 10
install. On my previous distro (ubuntu 10.04) - imagemagick was the
default viewer for image files. I would like to have the same
configuration, as opposed to the current set which uses evince
I'm more familiar with the use of mailcap as opposed to mc.ext.
Looking at /etc/mailcap, I see the following entry
Code:
image/jpeg; display 'jpeg:'%s''; test=test -n "$DISPLAY"
Looking at /etc/mc/mc.ext, I see the following
Code:
type/^JPEG
    View=%view{ascii} identify %f; test -x /usr/bin/exif && echo && exif %f 2>/dev/null
    Include=image
Note display is the command that launches ImageMagick
I've tried changing view to display in the entry above,
but with no different result.
Any and all ideas would be appreciated.
thanks
tim

Last edited by Tim Johnson; 02-13-2011 at 10:42 AM. Reason: Type in title
 
Click here to see the post LQ members have rated as the most helpful post in this thread.
Old 02-13-2011, 10:47 AM   #2
Xeratul
Senior Member
 
Registered: Jun 2006
Location: UNIX
Distribution: FreeBSD
Posts: 2,659

Rep: Reputation: 255Reputation: 255Reputation: 255
Quote:
Originally Posted by Tim Johnson View Post
I'm using Midnight Commander mc 4.7.0.6 on a new Mint 10
install. On my previous distro (ubuntu 10.04) - imagemagick was the
default viewer for image files. I would like to have the same
configuration, as opposed to the current set which uses evince
I'm more familiar with the use of mailcap as opposed to mc.ext.
Looking at /etc/mailcap, I see the following entry
Code:
image/jpeg; display 'jpeg:'%s''; test=test -n "$DISPLAY"
Looking at /etc/mc/mc.ext, I see the following
Code:
type/^JPEG
    View=%view{ascii} identify %f; test -x /usr/bin/exif && echo && exif %f 2>/dev/null
    Include=image
Note display is the command that launches ImageMagick
I've tried changing view to display in the entry above,
but with no different result.
Any and all ideas would be appreciated.
thanks
tim

I cannot help much, since mc is not my experience. I use a lot tuxcmd.
I wish i could contribute to help your issue
 
0 members found this post helpful.
Old 07-31-2011, 08:46 PM   #3
zhangweiwu
LQ Newbie
 
Registered: Jun 2006
Posts: 1

Rep: Reputation: 0
I have the same question but using Ubuntu 10.10. I bookmarked this question in case there is an answer.
 
Old 08-01-2011, 12:48 AM   #4
Diantre
Member
 
Registered: Jun 2011
Distribution: Slackware
Posts: 515

Rep: Reputation: 234Reputation: 234Reputation: 234
What's needed is the Open keyword:

Code:
type/^JPEG
        Open=display %f
        View=%view{ascii} identify %f; test -x /usr/bin/exif && echo && exif %f 2>/dev/null
        Include=image
The View command is used when F3 is pressed. Note that editing /etc/mc/mc.ext sets the system-wide configuration. For individual user settings, use F9 -> Command -> Edit extension file.

Hope that helps.
 
2 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
midnight commander peterb Ubuntu 1 10-14-2010 09:22 AM
[SOLVED] Midnight-commander new2nagios Linux - Software 4 08-05-2009 10:55 AM
Midnight Commander 4.6.2 guanx Slackware 8 02-07-2009 03:53 AM
midnight commander enigma1 Linux - Software 6 12-10-2003 02:47 PM
Midnight Commander XPediTioN Slackware 2 07-12-2003 11:45 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:18 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration