Editing Bib Items

In this section, you can find how to create and edit bib items. This section contains the following topics.

back to the Help TOC

Create a New Bib Item

To create a new database item, press <New Bib Item> button just above the items list or choose [BibItem - Append Bib Item] menu. A new bib item with bib key of “_untitled_nnnn” (nnnn is a number) is created in the selected database and the item is ready to edit. When you select a library or a library group in the database list, and if only one database is opened, the new item is appended to the opened database, while if plural database is opened, target database choice appears.

back to the Help TOC / back to the Top of This Page

Edit Bib Fields

Outline of the Editing

Before editing bib fields, you should choose ‘bibtype’. By default, ‘ARTICLE’ is selected that is used for a paper in a journal. ‘bibtype’ menu shows only standard types of BibTeX, however, you can enter any kind of type manually. If you frequently uses non-standard types, it is better to define them in the bib types tab of BibCompanion preferences.

When a new bib item is created, detail information panel becomes editing mode. In the editing mode, a button with key icon (editing button) at the bottom of the main window shows unlocked key and input support panel appears at the bottom of the main window. When BibCompanion is launched, bib items are in locked mode to prevent unwanted change to the items. If you want to edit an item, click on the editing button or choose [BibItem - Unlock Item Edit] menu. Double clicking on an item in the item list also makes the item into edit mode. When you finished editing, click the editing button again or choose [BibItem - Lock Item Edit] menu.

Expressions in detail information panel is different between the edit mode and the locked mode. If it is in the edit mode, field contents are displayed as you typed, that is, TeX commands etc. is shown as is. While in the locked mode, TeX commands are converted to unicode letters as possible. Despite the locked mode, field data can be selected and copied in the detailed information panel.

The following is brief explanations of frequently used types and fields. Please refer to BibTeX books or web sites for complete type definition and field usage of standard types. Text in all fields should be followed TeX input rules.

Frequently Used Bib Types

ARTICLE:
An article or a paper in a journal.
BOOK:
A book that is issued by a publisher.
INBOOK:
A part of a book, i.g. a chapter or page range.
INCOLLECTION:
A part of a book which has its own title (and usually own author).
INPROCEEDINGS:
A paper in a proceedings of a conference. It is same as CONFERENCE that is only for compatibility.

Frequently Used Bib Fields

bibkey:
Unique string for the item to use for citation. Spaces and commas can not be included in the key string. BibCompanion can generate a key for you. See the topic below. (Exactly speaking, ‘bibkey’ is not a field. BibCompanion treats it as a field for convenience.)
author:
Authors of the item. You should separate plural names by “and” but NOT comma. For example, “H. Nakahara and M. Ichikawa and A. Ichimiya and Y. Saito”. If there are too many authors and want to abbreviate at certain point, use “and others” at the end.
BibCompanion has a feature called “Smart Author Paste” to help users to input ‘author’ field easily. When you copy a string as “J. Slezák, P. Mutombo, V. Cháb” and paste it on the ‘author’ field, it is automatically converted to “J. Slez\'{a}k and P. Mutombo and V. Ch\'{a}b”. As you can see, commas between authors are converted to “and” and letters with accents are converted to corresponding TeX commands. It also removes numbers, daggers and several symbols that is often used to connect an author and his affiliation. When you paste names after existing names, connecting “and” is inserted. This feature is very useful when you copy authors from web sites or PDF files. Smart paste function is only invoked when more than 4 letters are pasted. It may not work when overwriting paste (make a selection before pasting) is done. It is also disabled when a pasted string already contains a TeX command. You can disable it in the general settings of BibCompainon preferences.
editor:
Editors of the item. Its format is the same as ‘author’ field. Smart author paste also works on this field.
title:
A title of the item (article title or book title).
BibCompanion has a feature called “Smart Title Paste” to help users to input ‘title’ field easily. When you copy a string as “Spin Chain System in KCu5V3O13 on Si(111)-(7×7)” and paste it on the ‘title’ field, it is automatically converted to “Spin Chain System in {KCu}$_5${V}$_3${O}$_{13}$ on {Si(111)-(7$\times$7)}”. As you can see, a chemical formula is analyzed and converted to super- or subscript. Mathematical symbols, greek letters and letters with accents are also converted to TeX commands. This feature is very useful when you copy titles from web sites or PDF files. Smart paste function is only invoked when more than 4 letters are pasted. It may not work when overwriting paste (make a selection before pasting) is done. It is also disabled when a pasted string already contains a TeX command. You can disable it in the general settings of BibCompainon preferences.
booktitle:
A title of a book or a collection that includes the item. It is used when the item has its own title. Smart title paste also works on this field.
journal:
A journal name. You'd better use macros for journals. See the topic below.
publisher:
A publisher name, i.g. ‘Addison-Wesley’.
address:
An address of the publisher, i.g. ‘New York’.
year:
A published year. It should have a 4 digit number, i.g. ‘2005’.
pages:
A page or a page range of the item. For a page range, enter as ‘123--456’.
annote:
An annotation or keywords of the item. It can contain an abstract of the item. BibCompanion has a functionality to search this field as a keyword field but BibTeX does not use this field. The usage is up to you.
email:
An e-mail address of the 1st author. Refer to E-Mail Attachment for detail.
url:
URL related to the bib item. Refer to URL Attachment for detail.
file:
A path to an attached file (or folder). Refer to File Attachment for detail.

Editing bib fields in the detail information panel

Bib fields can be edited in the detail information panel. The panel has 4 tabs, [Basic Info], [Optional Info], [Annotation], [Links] and [RAW field].

Basic Info:
Fields of basic information of the item. Most of those fields are required fields. Field titles colored blue are optional fields. Fields displayed here depends on bib type you choose. You can customize fields in the bib types tab of BibCompanion preferences.
Optional Info:
Optional fields of the item. It is also customizable.
Annotation:
‘annote’ field. As explained above, you can use this field as you like. You can enter a new line in this field, however, they are converted to a space.
Links:
E-mail, URL and file attachments. Detail of the usage of those fields are explain in the next section.
RAW Fields:
You can edit raw fields of the item here, so that it is possible to edit non-standard fields.
back to the Help TOC / back to the Top of This Page

Using Input Support Panel

When bib item is in edit mode, the input support panel is appeared below (or above) the main window. The panel has a macro popup menu, a generate bibkey button and grouped input buttons.

Macro Popup Menu

When you are editing a field, you can put a macro from this menu. There are three parts in the menu, [Edit Macros] command, database macros and general macros. Those are separated by separator lines.

Using the [Edit Macros] command is explained below.

The database macros are macros defined in a database. Those are save in the database file with @STRING{}.

The general macros are macros defined in a BibTeX style file (.bst). Those can be edited in the macros tab of BibCompanion preferences. As explained below, a field with a macro should begin with ‘@’. This menu automatically append a letter ‘@’.

Generate Bibkey Button

BibCompanion can generate a bib key from field data. See the topic below for more detail.

Input Buttons

When you are editing a field, you can put a special letters or mathematical symbols using those buttons. There are three groups of buttons, letters with accents, greek letters and others. Usage of those buttons are basically the same. When you press a button, corresponding TeX command is inserted at the cursor position.

For accent buttons with accent names (14 long buttons), you can choose a letter prior to press the button. In this case, the selected letter is used for a base letter of the accent. For example, if you select a letter ‘a’ of “Chab” and press [Acute] button, ‘a’ is replaced by ‘{\'a}’. If no selection is made, ‘{\'e}’ which is denoted in the button name is inserted.

For greek letters and most of math symbols, TeX commands for those characters should be surrounded by math mode character ‘$’. BibCompanion automatically detects a mode at the cursor position and insert ‘$’ if it is not in math mode.

Several math symbol buttons have parameters (‘A’ is used in the button name). It works as the accent buttons, select a parameter string first, then press a button with parameter. For example, if you select ‘31’ and press [√A] button, the selection is replaced by ‘$\sqrt{31}$’.

30 button definitions of the group [Others] can be customized by pressing [Edit Buttons] button in the panel. See Customizing Input Support Buttons for more detail.

back to the Help TOC / back to the Top of This Page

Generate a Bib Key

BibCompanion can generate bibkeys for bib items by pressing [Generate BibKey] button or choose [BibItem - Generate a BibKey/Generate BibKeys]. When you press the button or choose <Generate a BibKey> menu, bib key of currently editing bib item is generated. If you choose <Generate BibKeys>, all selected bib items in the bib items list are target.

By default, a generated key consists of the following three parts connected by colons.

For example, if the following fields are set as

the generated key is “NakaharaH:JJAP34:2003”.

The generation rule can be customized in the general settings of BibCompainon preferences.

back to the Help TOC / back to the Top of This Page

Using Macros

Using Macros in a Bib Field

Macros are very useful especially for journal names, publisher names and moths because those names in a reference list may slightly different in different journal. For example, the journal “Surface Science” is commonly abbreviated as “Surf. Sci.” but in some papers, it should be “Surface Sci.”. Therefore if you put a journal field as

   journal: [Surf. Sci.],

you should replace all occurrences of “Surf. Sci.” to “Surface Sci.” in the latter case. To reduce such an effort, use a macro as

   Journal: [@SS],

and set “SS” to “Surf. Sci.” in macro definition (how to define a macro is explained later). Once you put a journal name by a macro, only you should do is to change the macro definition.

There are several rules to use macros in bib fields.

You can put macros by hands but it is easier to use macro input menu in the input support panel. If you put a macro from the menu, ‘@’ is automatically inserted at the beginning. If some string is already entered, existing string is surrounded by double quotes and connected by ‘#’. If a macro is already entered, it is also connected by ‘#’. Macro menu is disabled when you are editing a field where you can not use macros.

Editing Database Macros

You can edit macro definitions by choosing [Edit Macors] menu in the [Input Macro] menu of the input support panel, or choose [File - Edit Macros] menu. Then the following window will appear.

DbMacros

In the list, [Macro Name] is a name of a macro and [Macro Data] is an expanded string of the macro name.

You can edit it by double clicking on a cell. If you double click on a empty cell at the end of the list, you can add a new macro. You can also insert a new macro by pressing [Insert New Macro] button. When you select a macro and press <delete> key or enter empty string for a macro name, the macro is deleted.

Macro name should start with an alphabet and spaces and symbols (such as ‘#’, ‘$’) are not allowed to use (hyphen and underscore can be used). If you make a macro name that already used in the list or macro name with illegal characters (such as a space), the name is shown in red and can not be fixed. Upper and lowercase of the macro name has no meaning with BibTeX. BibCompanion converts all letters in macro names to uppercase.

In the macro data, there is no limitation for characters, however, symbols should be in TeX format. The macro data can be a simple string as [J. Chem. Phys.] or more complex one with other macros such as [@_J # " of the " # _PHYS # " Society of " # _JPN]. As same as macro usage in a field, macro data that contains another macro should begins with ‘@’ and macros and strings should be connected by ‘#’. ‘#’ operator does not include any space, so that you should include a space explicitly in a string if you need. The order of macros is important when macro data contains another macro (i.g. [APA] in the above figure). A referred macro ([_APPHY] in this case) should be placed above a macro that uses one. You can change order of macros by dragging one (or some) to desired position in the list. It is recommended to make a name of referred macro begins with ‘_’. Because, when [Sort] button pressed, macros begin with ‘_’ always gathered on top of the list.

[Search in Data] Field
When you enter a string in this field, macros including the string is selected. It only searches into macro data but not macro names.
[Sort] Button
To sort macros by their names, press this button. Name of moths (JAN, FEB...) always placed at the top of the list.
[Import Macros] Button
Press this button to import macros from opened database.
ImportDbMacros
The upper menu specifies a source database. The source database should be opened by BibCompanion. The lower menu specifies an action when duplicated name is found. The meanings of the choices are as follows.
Create an Unique Name
Loads duplicated macros with an unique name (usually, name with a number).
Don't Overwrite It
Ignores duplicated ones.
Overwrite Existing Macros
Overwrites existing ones with imported ones.
back to the Help TOC / back to the Top of This Page