Problem with Companion Files in 1.91.6

Ask for help and post your question on how to use XnView Classic.

Moderators: XnTriq, xnview

andrewj
Posts: 59
Joined: Sat Sep 01, 2007 2:46 pm
Location: UK
Contact:

Problem with Companion Files in 1.91.6

Post by andrewj » Sat Nov 24, 2007 12:56 pm

I have just upgraded to 1.91.6, but I can't get the new companion files feature working, and the default companion file handling (which was fine in 1.914) seems to be disabled.

Firstly, I want to move/copy .JPG files when I move/copy the RAW file (.CR2). This was default behaviour before, but seems to have stopped working.

Secondly, I'd ideally like to move, at the same time, the Bibble Pro sidecar file (which will have an extension of .CR2.bib). Can this be done?

Thanks
Andrew

:?:

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

Re: Problem with Companion Files in 1.91.6

Post by xnview » Mon Nov 26, 2007 7:08 am

andrewj wrote:I have just upgraded to 1.91.6, but I can't get the new companion files feature working, and the default companion file handling (which was fine in 1.914) seems to be disabled.

Firstly, I want to move/copy .JPG files when I move/copy the RAW file (.CR2). This was default behaviour before, but seems to have stopped working.

Secondly, I'd ideally like to move, at the same time, the Bibble Pro sidecar file (which will have an extension of .CR2.bib). Can this be done?
Do you have tried to change the CompanionFile in xnview.ini?
Pierre.

andrewj
Posts: 59
Joined: Sat Sep 01, 2007 2:46 pm
Location: UK
Contact:

Post by andrewj » Mon Nov 26, 2007 5:58 pm

Dear Pierre,

Yes, I tried the following entries under [File]
Companion_00=cr2:jpg
Companion_01=cr2:cr2.bib

Is this right? I couldn't get it working.
Thanks
Andrew

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

Post by xnview » Mon Nov 26, 2007 7:35 pm

andrewj wrote:Dear Pierre,

Yes, I tried the following entries under [File]
Companion_00=cr2:jpg
Companion_01=cr2:cr2.bib

Is this right? I couldn't get it working.
Thanks
Andrew
Perhaps the bug that i have fixed for next release. If you want i can send you a test version to check?
Pierre.

andrewj
Posts: 59
Joined: Sat Sep 01, 2007 2:46 pm
Location: UK
Contact:

Post by andrewj » Mon Nov 26, 2007 10:20 pm

Yes, please. I'd be happy to test it.
Andrew

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

Post by xnview » Tue Nov 27, 2007 7:06 am

andrewj wrote:Yes, please. I'd be happy to test it.
Andrew
Send me your email by PM
Pierre.

andrewj
Posts: 59
Joined: Sat Sep 01, 2007 2:46 pm
Location: UK
Contact:

Post by andrewj » Tue Nov 27, 2007 8:30 pm

Dear Pierre,

I'm sorry, I still can't get it working, for either the jpg or bib files. My entries, in the [File] section of xnview.ini, are

Companion_00=CR2:jpg
Companion_01=CR2:CR2.bib

Have I mis-spelt something? Are the entries case-sensistive (I've tried several combinations, but not all).

Thanks
Andrew

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

Post by xnview » Wed Nov 28, 2007 8:18 am

andrewj wrote:Dear Pierre,

I'm sorry, I still can't get it working, for either the jpg or bib files. My entries, in the [File] section of xnview.ini, are

Companion_00=CR2:jpg
Companion_01=CR2:CR2.bib

Have I mis-spelt something? Are the entries case-sensistive (I've tried several combinations, but not all).

Thanks
Andrew
Right a problem if you have 2 extensions... i'll fix it
Pierre.

andrewj
Posts: 59
Joined: Sat Sep 01, 2007 2:46 pm
Location: UK
Contact:

Post by andrewj » Tue Dec 04, 2007 7:15 pm

Dear Pierre,
I'm trying to use the latest test version, and I've come across a problem. If I pick up and drag the .CR2 file, I want it to take the .JPG and the .CR2.BIB with it. This works fine.

However, if I pick up the .JPG I don't want to move the other files. This allows me to move this to a different output directory from the originals if I want to.

I've currently got the following two entries in the ini file:
Companion_00=cr2:jpg
Companion_01=cr2:cr2.bib
I've got rid of the line mapping jpg to cr2.

Logically this should give me the behaviour I want. Can we fix this?
Thanks

Andrew

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

Post by xnview » Tue Dec 04, 2007 7:38 pm

andrewj wrote:Dear Pierre,
I'm trying to use the latest test version, and I've come across a problem. If I pick up and drag the .CR2 file, I want it to take the .JPG and the .CR2.BIB with it. This works fine.

However, if I pick up the .JPG I don't want to move the other files. This allows me to move this to a different output directory from the originals if I want to.

I've currently got the following two entries in the ini file:
Companion_00=cr2:jpg
Companion_01=cr2:cr2.bib
I've got rid of the line mapping jpg to cr2.

Logically this should give me the behaviour I want. Can we fix this?
Thanks

Andrew
Ok right. Currently i check cr2=>jpg AND jpg=>cr2!
Pierre.

andrewj
Posts: 59
Joined: Sat Sep 01, 2007 2:46 pm
Location: UK
Contact:

Problems Solved - Need to Update Help File

Post by andrewj » Sat Dec 15, 2007 3:41 pm

:D
Pierre - thanks for fixing this. It works like a dream now.

I suggest we need a couple of lines of instruction added to the "companion files" page in the help file. If it helps, I've drafted the following as a starter:
XnView allows you full control over how companion files are managed. You turn companion file handling on and off in the "File Operations" tab under Tools/Options.../"General". The detail behaviour then depends on lines in the [File] section of XnView.ini

For each pair of file types, you need a line like:

Code: Select all

Companion_00=cr2:jpg
This means that file operations such as move, copy and delete on a Canon RAW file with extension .CR2 will also affect the companion file with extension .JPG

You can have up to 100 associations, but each line must have a different number before the "=" sign.

The system can also accomodate files where a new extension is appended to the original one. E.g. Bibble adds .bib to the RAW filename, so you need a line like the following:

Code: Select all

Companion_01=cr2:cr2.bib
The associations only work one way. E.g. the above only work if you act on the .CR2 file. This makes it easy to manage output files separately from the other associated files. If you want the associations to work both ways you will need lines mapping the other way, e.g.:

Code: Select all

Companion_02=cr2:jpg

User avatar
JohnFredC
XnThusiast
Posts: 2010
Joined: Wed Mar 17, 2004 8:33 pm
Location: Sarasota Florida

Post by JohnFredC » Sun Dec 16, 2007 3:05 am

This is very helpful text. Thanks for it!
John

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

Post by helmut » Sun Dec 16, 2007 11:45 am

Thanks for this good, explaining text, Andrew. Perhaps Ty can add this to the XnView online help.

User avatar
Peter2
XnThusiast
Posts: 1136
Joined: Thu Nov 24, 2005 3:07 pm
Location: CH

Re: Problems Solved - Need to Update Help File

Post by Peter2 » Sat Mar 13, 2010 7:40 am

andrewj wrote:...to work both ways you will need lines mapping the other way, e.g.:

Code: Select all

Companion_02=cr2:jpg
Other way? The code is the same as in the first example. I thought that this example is right:

Code: Select all

Companion_02=jpg:cr2
Peter
XnView 2.48 German, Win 7 x64 Prof. / Win 10

sternenfall
Posts: 6
Joined: Sun Oct 02, 2011 12:20 pm

Re: Problem with Companion Files in 1.91.6

Post by sternenfall » Mon Mar 26, 2012 11:34 am

Just a note for "Companion_xx". To represent the relationships between JPG/TIFF/ORF/CR2 I have to use 30 entries in XnView:

Code: Select all

Companion_00=jpg:tiff
Companion_01=tiff:jpg
Companion_02=jpeg:tiff
Companion_03=tiff:jpeg
Companion_04=jpg:tif
Companion_05=tif:jpg
Companion_06=jpeg:tif
Companion_07=tif:jpeg
Companion_08=cr2:jpg
Companion_09=jpg:cr2
Companion_10=cr2:jpeg
Companion_11=jpeg:cr2
Companion_12=orf:jpg
Companion_13=jpg:orf
Companion_14=orf:jpeg
Companion_15=jpeg:orf
Companion_16=cr2:tiff
Companion_17=tiff:cr2
Companion_18=cr2:jpeg
Companion_19=jpeg:cr2
Companion_20=orf:tiff
Companion_21=tiff:orf
Companion_22=cr2:tif
Companion_23=tif:cr2
Companion_24=cr2:jpeg
Companion_25=jpeg:cr2
Companion_26=orf:tif
Companion_27=tif:orf
Companion_28=orf:jpeg
Companion_29=jpeg:orf
Apparantly the reason for the inflationary application of "Companion_xx" is that "JPEG"/"JPG" and "TIFF"/"TIF" are separate extensions. Also the declaration is only one-way. Suggestions:
  • use "::" instead of ":" to indicate bidirectional binding
  • use ";" to separate multiple extensions
For example:

Code: Select all

Companion_00=jpg;jpeg::tif;tiff
could replace 8 definitions:

Code: Select all

Companion_00=jpg:tiff
Companion_01=tiff:jpg
Companion_02=jpeg:tiff
Companion_03=tiff:jpeg
Companion_04=jpg:tif
Companion_05=tif:jpg
Companion_06=jpeg:tif
Companion_07=tif:jpeg
Another problem is that XnViewMP 0.39 seems not so supprt "Companion_xx".
This might by natural, however, since its ini-file not even has a "[File]" section. :)
Greetings, Andreas

Post Reply