Info about XnView's settings (store & load)

Frequently Asked Questions regarding XnView (including Answers)

Moderators: XnTriq, xnview

User avatar
helmut
Posts: 8116
Joined: Sun Oct 12, 2003 6:47 pm
Location: Frankfurt, Germany

Info about XnView's settings (store & load)

Postby helmut » Mon Jan 24, 2005 7:45 pm

XnView settings are for example position and size at startup, recent file lists, or the options which you set in the options dialog. All these settings have to be stored when exiting the program and restored when starting. Normally, you use XnView and change settings in the options, and you do not have to worry how they are stored and where they are stored.

In some cases, it's still good to know and understand, where XnView stores its settings. Below you will find various info on XnView's settings.

Where are settings stored?
XnView will store its settings in .ini files or in the Windows Registry. The place where your settings are stored depends on the option "Save options", which you can find by selecting menu "Tools > Options", category "System integration".

A - Settings stored in .ini files
By default all your XnView settings/options are stored in two files:
- xnview.ini
- bookmark.ini

bookmark.ini contains the bookmarks that you can set using the toolbar in the browser ("New bookmark"). xnview.ini contains all the rest, i.e. setting of options, recent file and directory list, ... If you want to have the same settings on another PC or want to make a backup of your settings, it's sufficient to copy the two .ini files.

Location of .ini files
The setting "Save options" (see above) also controls the location of the .ini file:
    * User - User's Application directory
    * Program - Program directory of XnView
    * Windows - Windows directory
The full path of the .ini files is displayed in the About dialog (menu "Info > About...").

Resetting XnView to default settings
XnView has internal default settings which are used if no settings file or registry entry is available. If you want to reset all your settings to back default, just delete (or rename) the "xnview.ini" file. Please note that your bookmarks won't be deleted, since they are stored in a separate file "bookmark.ini".

B - Settings stored in Windows Registry
If you have activated the option "Use registry to save options", all the XnView settings will be stored in your registry under the key "HKEY_CURRENT_USER\Software\XnView" and you can use "regedit" to export and import the settings. But this is for advanced PC users, only.

Settings and XnView update
When updating XnView, you typically uninstall your current version and then install the new version.
The two .ini files 'xnview.ini' and 'bookmark.ini' which are used to store the settings and the bookmarks of XnView, are not part of installation and deinstallation and will not be changed or deleted. So when updating, the settings will be untouched and won't be lost.

Editing settings manually
The .ini files are normal text files which can be opened using any text editor. All settings stored in the .ini file can be changed using XnView's option dialog ("Tools > Options"), so normally there should be no need to edit and change the settings manually.
Editing .ini files can be done, but when doing so each user should know what he/she does and it's at own risk: Normally XnView is forgiving, but in rare cases wrong entries might even cause GPFs at start-up. Make sure that you exit XnView before editing the settings manually, otherwise your changes will be overwritten by XnView when exiting.

User avatar
oops66
XnThusiast
Posts: 1998
Joined: Tue Jul 17, 2007 1:17 am
Location: France

Postby oops66 » Mon Sep 24, 2007 4:47 pm

FYI: In case of personal tool bar, this configuration file must be saved too : default.bar

So personal files setting , xnwiew.ini, bookmark.ini, default.bar, must be saved and restored if needed.
( and if the folders structure is the same (same directories and files names), category.db and XnView.db can be saved or transfered too)
XnViewMP 0.82 Linux X64 - Ubuntu 16.04 LTS - X64

bigcoyote
Posts: 2
Joined: Tue Sep 18, 2012 8:34 pm

Re: Info about XnView's settings (store & load)

Postby bigcoyote » Tue Sep 18, 2012 8:42 pm

Hello,

I am using xnview 1.98.7 with quite a lot of specific settings (for example, label information set in the option menu, desactivatd cachefor thumbnails)
I installed 1.99.1 in a separate folder on the same computer and tried to copy the settings but it does not seem to work. All the configurations I made in the "tools/options" menus were not copied. The cache of thumbnails is for example still activated ...

Any advice ?

Thank you !

Eric

User avatar
xnview
Author of XnView
Posts: 27352
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Info about XnView's settings (store & load)

Postby xnview » Wed Sep 19, 2012 7:31 am

You can see the full path of xnview.ini used in About dialog (menu "Info > About...").
Pierre.

bigcoyote
Posts: 2
Joined: Tue Sep 18, 2012 8:34 pm

Re: Info about XnView's settings (store & load)

Postby bigcoyote » Wed Sep 19, 2012 1:05 pm

Yesterday, I just copied - paste the xnview.ini in the 1.99.1 folder and it did not work.
But this morning, after having restarted my computer, everything works well !

So I don't know how but it works as I wanted and I am pleased :)

Thnak you again for this really good software.

User avatar
helmut
Posts: 8116
Joined: Sun Oct 12, 2003 6:47 pm
Location: Frankfurt, Germany

Re: Info about XnView's settings (store & load)

Postby helmut » Mon Oct 01, 2012 8:53 am

Good to read that everything works fine, now, Eric.

bigcoyote wrote:...So I don't know how but it works as I wanted and I am pleased :)...

XnView reads settings on startup and writes all its settings on exit (regardless whether settings have been changed or not). So make sure that you exit all running instances of XnView before copying settings (.ini files).

Hugh TasH
Posts: 3
Joined: Sat Feb 14, 2015 1:50 pm

Re: Info about XnView's settings (store & load)

Postby Hugh TasH » Sat Feb 14, 2015 2:36 pm

I made this post to sum up the facts about XnView backup / restore process.

XnView stores settings depending on user choice.
Depending on user choice, XnView stores settings in .ini files or in your registry under the key HKEY_CURRENT_USER\Software\XnView

Depending on user choice, XnView can store settings in .ini files on these locations:

• %AppData%\XnView folder

• C:\Program Files (x86)\XnView

• C:\Windows


By default, XnView stores settings in .ini files on %AppData%\XnView folder.

xnview.ini contains most of settings, i.e. most Tools – Options settings, Recent files, Directory list.

bookmark.ini contains favorites (bookmarks) that you can set in XnView Browser by going to Favourites – Add favourites… If you have no favourites, bookmark.ini won’t exist.

default.bar contains settings of XnView tool bar. Therefore, if you have personalized toolbar you should backup default.bar too.

• If folders structure is the same (same directories and files names), category.db and XnView.db can be backed up / restored too.

In order to see what .ini settings file XnView is using, go to Info – About…

To make backing up easier, you can simply backup whole %AppData%\XnView folder.


In order to Backup XnView settings

1. Backup %AppData%\XnView folder


In order to Restore XnView settings

1. XnView reads settings when you open XnView and writes all its settings when you exit XnView (regardless whether settings have been changed or not). So make sure that you exit all running instances of XnView before backing up and especially when restoring XnView settings (copying .ini files).

2. Copy xnview.ini, bookmark.ini, default.bar to %AppData%\XnView folder. If you’re restoring XnView on the same PC, that uses the same directories and files names that were present when you backed up XnView, you can copy category.db and XnView.db too.



Also the Wiki about XnView settings saving, backing up and restoring should be a little bit updated, because now settings saving options are located in Tools > Options, category "System integration", not "Install". Also it seems that in Browser UI, Bookmarks were renamed to Favourites:
http://www.xnview.com/wiki/index.php/Se ... _Ini_Files

Also it would be nice to get an approval from other users of XnView that this method of backing up / restoring XnView settings is still optimal and relevant for current versions of XnView as of year 2015.

User avatar
omniplex
Posts: 122
Joined: Thu Feb 10, 2011 1:52 pm
Location: Hamburg
Contact:

Re: Info about XnView's settings (store & load)

Postby omniplex » Wed Mar 18, 2015 11:26 am

Hugh TasH wrote:I made this post to sum up the facts about XnView backup / restore process.

Thanks, very useful, I second your request to get an account on the Wiki. You owe me a reciprocal second. :P

User avatar
XnTriq
Moderator & Librarian
Posts: 4917
Joined: Sun Sep 25, 2005 3:00 am
Location: Ref Desk

Re: Info about XnView's settings (store & load)

Postby XnTriq » Wed Mar 18, 2015 6:00 pm

XnTriq (Ho! Ho! Ho! - Santa's Suggestions) wrote:
The settings for XnView's shell extension are stored in the registry:

    HKEY_CURRENT_USER\Software\XnView\ShellEx\
These are the files that hold XnView's configuration:

  • xnwiew.ini (main settings)
  • XnView.db (thumbnail cache and database for ratings + color labels + tags)
  • category.db (database for categories) &
    category.bak (backup of category.db)
  • iptc.def (IPTC Keywords)
  • default.bar (default toolbars)
  • foo.bar (customized toolbars)
  • bookmark.ini (favorites)
  • XPaint.ini (Paint add-on)
  • XFlash.ini (Flash export add-on)
  • XPNGout.ini (PNGout export add-on)
The location of these files depends on your preferences:

  1. Info » About... » INI file location
  2. Tools » Options... » System integration » Integration
    • Save options
      • as INI in folder: [ User | XnView | Windows ]
      • in registry
    • Folder used for other files: [ User | XnView | Custom ]

  • %appdata%\XnView\XFTP.ini
  • %programfiles%\XnView\AddOn\ftp.log
  • %temp%\listing.txt (Create » File Listing...)
  • xnview.export (Create » Export files...)
  • HKEY_LOCAL_MACHINE\SOFTWARE\Classes\.sld
  • HKEY_LOCAL_MACHINE\SOFTWARE\Classes\XnView.Image
  • HKEY_LOCAL_MACHINE\SOFTWARE\Classes\XnView.Slide
  • HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Applications\xnview.exe
  • HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Directory\shell\XnView
  • HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Drive\shell\XnView
  • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\xnview.exe
  • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\StillImage\Registered Applications
  • HKEY_CURRENT_USER\Software\SoftGold (CADSoftTools plug-in)

See also: Backup and restore

User avatar
XnTriq
Moderator & Librarian
Posts: 4917
Joined: Sun Sep 25, 2005 3:00 am
Location: Ref Desk

Re: Info about XnView's settings (store & load)

Postby XnTriq » Sun Mar 22, 2015 11:30 pm

Hugh TasH wrote:Also the Wiki about XnView settings saving, backing up and restoring should be a little bit updated, because now settings saving options are located in Tools > Options, category "System integration", not "Install". Also it seems that in Browser UI, Bookmarks were renamed to Favourites:
http://www.xnview.com/wiki/index.php/Se ... _Ini_Files

Thanks for the heads-up! The page has now been updated.


Return to “XnView - FAQ”

Who is online

Users browsing this forum: No registered users and 1 guest