惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

月光博客
月光博客
IT之家
IT之家
Hugging Face - Blog
Hugging Face - Blog
J
Java Code Geeks
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - 叶小钗
MyScale Blog
MyScale Blog
G
Google Developers Blog
Microsoft Azure Blog
Microsoft Azure Blog
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
大猫的无限游戏
大猫的无限游戏
博客园 - 三生石上(FineUI控件)
Google DeepMind News
Google DeepMind News
Engineering at Meta
Engineering at Meta
The Cloudflare Blog
Martin Fowler
Martin Fowler
酷 壳 – CoolShell
酷 壳 – CoolShell
N
Netflix TechBlog - Medium
MongoDB | Blog
MongoDB | Blog
I
InfoQ
WordPress大学
WordPress大学
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
H
Help Net Security

jdhao's digital space

Conversion between base64 and OpenCV or PIL Image 腾讯云对象存储博客图床开启 CDN 加速(不需要购买额外域名) Search and Replace in Multiple Files in Vim/Neovim Change Table Column Width in LaTeX Image or Table Side by Side in LaTeX LaTeX 并排显示图像或表格 Firenvim: Neovim inside Your Browser Content inside HTML tags missing in Latest Hugo? Creating Markdown Front Matter with Ultisnips Labelme JSON 标注格式转 voc XML 格式 Nifty Nvim Techniques That Make My Life Easier -- Series 6 macOS 下如何为视频制作字幕 Running Command Asynchronously inside Neovim Resolving Merge Conflict after Git Stash Pop Pylint: command not found? A Hands-on Experience with Neovim's Built-in LSP Support How to Convert PDF to Images with Imagemagick 互联网上常用缩略语集锦 File Backup in Neovim Converting PDF Pages to Images with Poppler Nifty Nvim Techniques That Make My Life Easier -- Series 5 Neovim Configuration for System-wide Use How to sort a list of tuple or list in Python -- lambda or itemgetter? Building A Vim Statusline from Scratch 人类第一颗原子弹爆炸始末 Distributed Training in PyTorch with Horovod Learning Expect Programming Essential Knowledge about SSH Nifty LaTeX Techniques -- Series 1 更改 Adsense 邮寄地址,重新寄送 PIN
IrfanView Settings
2020-06-20 · via jdhao's digital space

IrfanView is a lightweight, fast and powerful image viewer for Windows. Here are some settings to make it more useful.

Auto-jump to next file after deleting current one#

By default, IrfanView will not jump to next image if you delete the current one. To enable this, click Options --> Properties/Settings... --> File Handling. Under the delete section, check the following box:

Jump to the next file after deleting/moving

Fit image to window size when viewing#

When we are viewing images in a directory, it is annoying that window size changes as image sizes vary. To keep the window size and fit the image to window, go to View --> Display options (window mode) and choose Fit images to window.

Ref:

Do not exit program when pressing ESC#

By default, Irfanview will exit immediately if we press ESC when we are viewing an image, which is really annoying. To disable this behavior, go to Options --> Properties/Settings, in the popup window, click Start / Exit options. In the Exit options section, check the box Warning on ESC program exit. Do not forget to click OK button to save your settings.

Ref:

Skip txt files when viewing files in a directory#

By default, ifranview will also show text files, which is annoying. Here is how to disable this behavior. Go to Options -> Properties/Settings -> Extentions:

  • Check the boxes for the file extensions that we want irfanview to open
  • Select the option “Load only associated types while moving through directory”.

Ref:

Copy current image path quickly#

When I check an image with irfanview, often I want to copy the image path to use in command line. Currently, I have to press i (show image properties), then copy the full image path. This is boring and cumbersome. I found from the irfanview forum the following AutoHotKey script to automate this process:

Click to show the code.
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.

; If IV is running, then the script will modify the key combination Ctrl+Shift+C to
; copy file path (oposed to set image as desktop background)

; OPTIONAL: Following code ensure that script terminates when IV close. Delete (or comment out)
; line 10 - 19 for letting the script run until manually stopped by user.
SetTimer, check_window, 500
return
check_window:
IfWinNotExist, ahk_class IrfanView
{
TrayTip, "IrfanView check", IrfanView har being closed. Script terminate.
Sleep 3000
ExitApp, 1
}
return


; RESTRICT HOTKEY TO IRFANVIEW ONLY <BEGIN>
; Ensures that hotkey manipulation works ONLY when IrfanView program window is active (most foremost)
#IfWinActive ahk_class IrfanView
^+c::

WinWait, ahk_class IrfanView, , 5

if errorlevel
{
MsgBox, 0, venter  vindu, IrfanView ikke funnet  5 sekunder - avslutter
ExitApp, 1
}

; Remove any existing content on clipboard.
clipboard =

WinActivate, ahk_class IrfanView

Sleep 300

; Simulate key press "i" to open image properties dialog box (ipdb).
Send, i
WinWaitActive, IrfanView - Image properties, , 2

; If ipdb for some reason fail to open, user get an error message and script terminate.
if errorlevel
{
MsgBox, 0, Waiting, Image properties window didn't appear. Script terminates now.
ExitApp, 1
}

; Hit tab three times
Send, {TAB 3}
; COpy text (image path) to clipboard
Send, {CTRLDOWN}c{CTRLUP}
; Waiting until clipboard contains data (in most cases this command could be ommitted without any effect)
ClipWait
; Quits the ipdb
Send, {ALTDOWN}o{ALTUP}


; OPTIONAL - Make a tray tip (baloon) appear. User should be confident that image path is actually copied to clipboard
TrayTip, Image path:, %clipboard%, 4
Sleep 4000
HideTrayTip()

HideTrayTip() {
    TrayTip  ; Attempt to hide it the normal way.
    if SubStr(A_OSVersion,1,3) = "10." {
        Menu Tray, NoIcon
        Sleep 200  ; It may be necessary to adjust this sleep.
        Menu Tray, Icon
    }
}

; RESTRICT HOTKEY TO IRFANVIEW ONLY <END>
#IfWinActive

First, we need to install autohotkey. Save the above script in a directory and name it copy_im_path_irfanview.ahk. Open the irfanview window, then double click the script file to run this script.

When you are viewing an image, press Ctrl-Shift-C to copy the image path. A tooltip will also pop up on the bottom right corner to show the image path copied. Unfortunately, Ctrl-shift-C is also used by Irfanview to set the desktop wallpaper. You may want to change to other shortcut (change the line ^+c:: to what you want, for example ^!C::, i.e., Ctrl-Alt-C1).