Style Editor: conditional text element inside the component

Animus A. shared this question 3 months ago
Answered

I had to create a new style, which uses transliterated data from several custom fields. For instance, my style uses transliterated editors' names from the 'Custom field 3' for 'Contribution' reference type. The corresponding component looks like the following:

In:·Custom field 3·(eds.)
My problem is emulating Citavi's function of determining whether there are plural or single editor(s). If 'Custom field 3' contains several editors, it always contains a comma, which is never the case for a single editor. This creates a possibility for conditional formatting, but I can't figure out how to implement this.


I guess my only option is creating a separate (ed.)/(eds.) component and 'Filter output of this component part via program code'. Any help with such code would by helpful. I'm using Citavi 5.


Thanks!

Best Answer
photo

Hi Animus,

Thanks for your questions.

Custom fields are simple text fields - therefore, these are not suitable for the output of persons.

A) Do you need both versions of the editors' names (original and transliterated) within the Bibliography?

Then I would suggest to put the original or the transliterated name in parentheses in the field "Suffix", see https://www.screencast.com/t/0PfH9iDSfv

Necessary adaptations in citation style:

  1. If you are using an Author Year style, suppress the output of the suffix field there: Switch to the reference type "Unknown" in the citation style editor. Double-click the component "Author, editor or organization". Select the Suppress name suffixes" checkbox.
  2. If a comma appears in the bibliography between the transliterated name and the original name, you would have to remove this comma in the citation style, too: In the citation style editor, select the reference type "Contribution in edited book". Double-click the Author component. Remove the comma from the field "Name suffix separator".

B) If you need the transliterated version of the editors' names seperately

  1. Instead of using a custom field, put the transliterated names in an empty persons field, e.g. "Collaborators" or "Others involved".
  2. In the citation style editor, select the reference type "Contribution in edited book". Add the used component ("Collaborators" or "Others involved") within the Bibliography rule set at the desired position. Double-click the component. Select the "Group suffix output" checkbox and enter " (ed.)" resp. " (eds.)" (including the spaces!) in the field "Singular" resp. "Plural" , s. screenshot: https://www1.citavi.com/sub/manual5/en/cse_names_of_persons-7.png

Best regards

Susanne

Comments (3)

photo
1

Hi Animus,

Thanks for your questions.

Custom fields are simple text fields - therefore, these are not suitable for the output of persons.

A) Do you need both versions of the editors' names (original and transliterated) within the Bibliography?

Then I would suggest to put the original or the transliterated name in parentheses in the field "Suffix", see https://www.screencast.com/t/0PfH9iDSfv

Necessary adaptations in citation style:

  1. If you are using an Author Year style, suppress the output of the suffix field there: Switch to the reference type "Unknown" in the citation style editor. Double-click the component "Author, editor or organization". Select the Suppress name suffixes" checkbox.
  2. If a comma appears in the bibliography between the transliterated name and the original name, you would have to remove this comma in the citation style, too: In the citation style editor, select the reference type "Contribution in edited book". Double-click the Author component. Remove the comma from the field "Name suffix separator".

B) If you need the transliterated version of the editors' names seperately

  1. Instead of using a custom field, put the transliterated names in an empty persons field, e.g. "Collaborators" or "Others involved".
  2. In the citation style editor, select the reference type "Contribution in edited book". Add the used component ("Collaborators" or "Others involved") within the Bibliography rule set at the desired position. Double-click the component. Select the "Group suffix output" checkbox and enter " (ed.)" resp. " (eds.)" (including the spaces!) in the field "Singular" resp. "Plural" , s. screenshot: https://www1.citavi.com/sub/manual5/en/cse_names_of_persons-7.png

Best regards

Susanne

photo
1

Wow, somehow I didn't even think about option B! ;-) Thank you very much for this helpful advice.

photo
1

Hi Animus,

Thank you so much for writing back.

I'm glad to hear that I could help you.

Best regards

Susanne

photo