Use templates to give your elements a chosen look
A template in SuperMemo is a definition of an element's appearance. Templates are used to create a number of similarly looking elements, e.g. with a given color, font, image, etc. The first thing to do with templates is to create the "common look". You can do it by creating an element containing all components that are common to all elements that will be created with the use of the template. All components should have their properties set in the way that is desired for the "common look" (e.g. color, font, position on the screen, etc.). You set the properties of components by using the component pop-up menu.
After creating the desired look, you can use Template : Save as template on the element pop-up menu (e.g. opened with Alt+F10). Save as template makes it possible to keep a "gallery of looks" for future use. Indeed, you can save any element as a template. If you want particular texts, sounds or images being associated with the template, use Temple : Save with objects instead.
Saved templates are stored in the template registry that can be viewed with Search : Template on the main window's menu. If you want a saved template to become the default template for items in the currently selected category, use Template : Save as default (Ctrl+Alt+S). Save as default will save the template in the same way as Save as template. If you follow Save as default with Add new (Ctrl+A), the newly added item will use the "saved look".
You can give an element a given look by applying a template. A template is taken from the template registry and applied to any element with Template : Apply template (after you choose a template in the registry, click the Accept button at the bottom of the template registry window). Applying a template does not overwrite the "old look". You can always remove the applied template by choosing Template : Detach template.
Use category templates to switch between different looks
If you always want a given template to be used within a given category follow these steps:
- choose Search : Categories on the main menu (if you are not in the professional level, you will need to enter the professional level, e.g. with Ctrl+Alt+F12)
- select the category (e.g. by typing its name at the top of the category registry window)
- click the Template button (in the display panel top-right)
- choose the template from the template registry (e.g. by typing its name at the top of the template registry window)
- click Accept (at the bottom of the template registry window)
- close the category registry window
The above will make sure that your template is used each time you choose Add new or press Ctrl+A (only if the relevant category is selected as the current category in the category combo-box).
You can apply a template to many elements at the same time
You can change the look of many elements at the same time. If your selected element use a given template, go to one of these elements and simply redefine the template. If your elements use different templates or use no template at all, you can apply a template to all of them by choosing Process branch : Template : Apply template in the contents window, or Process browser : Template : Apply template in the browser.
Template operations
Here is the summary of template operations on the Template submenu of the element pop-up menu. Use Alt+F10 to open this menu or right-click over the empty element area or over the navigation toolbar:
- Save as template - save the currently displayed element as a template in the template registry. This makes it possible to use the looks of the element in other elements. Template objects such as pictures or texts are not saved with the template
- Save as default - save the current element as a template and make it the default template in the currently selected category. Choosing Alt+Ctrl+s is the fastest way to make sure that all new items added to the current category assume a given look. Save as default does not save template objects
- Save with objects - save the currently displayed element as a template in the template registry. The saved template will include references to texts, pictures, sounds and other objects associated with the element
- Apply template - use a selected template from the template registry to modify the look of the element. The original look will remain untouched as the template source and can be inspected with Template : View source or restored with Template : Detach template. After using Template : Apply template, the template source can be overwritten with Template : Impose template. In applying a template, SuperMemo transfers all matching registry objects (e.g. texts, images, etc.) from the source template to the applied template. Source components that do not find their match in the applied template will become invisible
- Replace with template - replace the current template source with a new template. The original look of the element will be lost. Replace with template is equivalent to Apply template and Impose template run in succession. The template is not detached and all its changes will be reflected in the looks of the element
- Detach template - detach the template attached with Apply template. The original source template of the element will be exposed. The element will become template-less until a new template is applied
- Impose template - overwrite the source template with the currently applied template. After Impose template, View source will have no effect as the source template will be the same as the applied template
- Add template - add components from a selected template to the currently displayed element
- View source (Ctrl+Shift+U) - view the source template of the current element. The source template is the original look of the element before any template was applied with Template : Apply template
- Save to file - save the current element as a template file. This file can later be loaded into another collection with Template : Load from file. You can view template files with any text editor. Note that these files do not store registry objects but only references to appropriate files. This way a template file is useful only as long as the source collection remains in its original location on the disk. Once it is moved, references in the template file will be useless
- Load from file - load a template file saved with Template : Save to file. Loading template file deletes all components and creates new components specified in the template
- Copy template - copy the currently used template to the clipboard
- Paste template - paste the template from the clipboard (currently displayed template will be overwritten)
Adding components to a group of existing elements
If you want to add new components to a group of elements, use Add template in the contents window or in the browser. This will retain the old components and add new components from the added template. Add to template is similar to Apply template but the contents of the new template is simply superimposed over the old template. This way, you can create a template with an image and add this image to a selected group of elements by adding the image template
Transferring templates between collections
If you want to transfer templates (or single elements) between different collections, use Template : Save to file and Template : Load from file. You can also use Edit : Copy element with Edit : Paste template and Edit : Paste element to transfer templates and elements within a collection or between different collections using the clipboard
Frequently Asked Questions
You can easily
change the position of question and answer fields with double Alt+click and
dragging
You can detach a template to provide an
element with a unique look
Templates are not used when building knowledge tree
in the contents window
You can keep different fonts for questions and for answers
You can change the look of items globally
Categories make it possible to select the default template
If you delete a component from a global template, all elements will be affected
You can learn English in
your own language (e.g. Japanese)
If you choose Save with objects,
texts and pictures will be included in your template
If Add New does not create needed components, you can redefine the template
Component order may determine how the
titles are generated
You can drag components inside a template
You can save a template with objects to associate RTF components with fonts
Question:
How can I change the position of the question field on the screen?
Answer:
Alt-click the question twice. It will become draggable.
Alternatively, you can choose Dragging mode on the question's
pop-up menu or on the element pop-up menu (in the
latter case, all components will become draggable). If you want to change this
position globally (i.e. in all elements in your collection), you should use
templates.
(Mariusz
Zmuda, Poland, Jan 29, 2001)
Question:
I changed the size of the question field in one element and SuperMemo
changed this in other elements too! This was quite a surprise!
Answer:
If you change the template of one element, all elements that use this
template will be affected. If you want to provide a unique look to a single
element, you need to detach its template. For best effect, choose Template :
Impose template or simply press Ctrl+Shift+F2 and respond with Yes
to Detach template? As of this moment, changes to the element will not
propagate to other places in the collection. Global templates are new to
SuperMemo 2000 and users of older versions are often surprised when they see the
global effect of editing a template
(Vidar
Garlie, Norway,
Mar 18, 1999)
Question:
When I go to the contents window, select a
category branch and click Ctrl+A, the template
of this category is not used! Can you help?
Answer:
To use a category template, you have to first
choose the category in the category
combo box on the Tools toolbar.
Selecting branches in the contents
window does not affect the current category selection
(Eryk
Horloza, Poland, June 3, 1997)
Question:
How can I keep different fonts for the question and the answer component in
SuperMemo?
Answer:
The
fastest way is:
- Add a new item with Ctrl+A
- Apply Classic template (Ctrl+Shift+M), type Classic and press Enter) (you need at least Middle level for this to work)
- On the pop-up menu of the question component choose Text : New font (or Links : Font if you have already defined the font)
- Select the appropriate question font
- Select the answer font in the same way
- On the element pop-up menu choose Template : Save as default (or simple press Ctrl+Alt+s)
- Choose Ctrl+A again to see if your new template has been applied correctly
Now your new template with new fonts will be used each time you add a new item
(Doug
Edmunds, USA, Nov 4, 1997)
Question:
How can I globally change the layout of question, answer, font, background
color, etc.
Answer:
Do as follows:
- Create a new template with your new layout
- Save the template with Template : Save as template (on the element pop-up menu)
- In the contents window, choose the branch that should be changed
- On the contents pop-up menu choose Process branch : Template : Apply template and select the new template
(George W., USA, Dec 14, 2000)
Question:
I use the occlusion pre-defined template. Is there any way to make the red
occlusion box appear in front of the image?
Answer:
You need to learn two skills that will help you handle such situations:
- Ctr+T will help you switch between components and turn the editing mode for each component. You can bring your selected component to front by cycling through components with Ctrl+T
- Alt+click can switch a single component to the editing mode. Second Alt+click will switch to the dragging mode. In the dragging mode, you can grab the red rectangle with the mouse and move it to the location of your choice
(George W., USA, Dec 14, 2000)
Question:
When I use the occlusion pre-defined template, I cannot edit one item
without affecting the appearance of others. What should I do to have images of
different sizes and a different location of the red occluding rectangle?
Answer:
To make sure your global Occlusion template does not get modified each time
you resize components, you need to detach this template from the element whose
components are to be resized. The fastest way to do it is:
- Ctrl+Shift+F2 (here Template : Impose template writes template data over the element source)
- Answer Yes to Detach template?. This will make the element use the template's look without using the global template
Once you detach the template, all changes to the looks of a given element will be local
(Tomoki
Takahashi, Japan, Feb
6, 1999)
Question:
I would like to learn English with questions asked in Japanese. How can I
do it?
Answer:
You have to (1) create your own template
with the Japanese font in the plain-text question field (you can use Text
: New Font to change the question font in the classic
template), (2) save the template with Template
: Save as default. Do not use rich text components in your template
as these do store a font setting!
After this, each time you choose Add new (or
press Ctrl+A), your questions will be
generated in Japanese and answers will retain standard look (you can also swap
English with Japanese by using Edit
: Swap components).
Although you cannot change the writing direction in SuperMemo text
components (from yokogaki to tategaki), you can include texts via OLE from
Japanese Word or Ichi Taro word processors. These programs use either Microsoft
IME or ATOK utilities to input Japanese text. Microsoft IME is part of Japanese
Windows. ATOK is part of the Ichi Taro word processor (Justy System) but can be
installed as a separate unit. With ATOK you can change from the English to the
Japanese input mode. It is fully compatible with SuperMemo: 1) You type the
pronunciation of a word from the keyboard, 2) press Space, and 3)
select the appropriate kanji(s) from the list showing those matching the input
sounds combination. Ganbatte ne
(Brian
DeMio, USA, Jan 10, 1999)
Question:
I changed the template for the questions so that I have a purple
background and yellow fonts. Everything is fine with that part.
After I entered in an element (question and answer) I hit Ctrl+A to put
in a new one. The question from the previous element keeps popping up in the new
elements where you are supposed to input answers. How can I fix this?
Answer:
Please make sure that when you save your template
there are no texts in text components.
You can accomplish that by choosing Save as template rather than Save
with objects on the element pop-up menu
(Krzysztof
Morawski, Poland, Dec 28, 1998)
Question:
I am learning Norwegian. Until recently, SuperMemo
has automatically chosen appropriate titles for my elements;
however, for some time now, it has been choosing Norsk as the title for
all elements (Norsk is a text included in a text component displayed as
a label on each page). How can I make SuperMemo choose the right title (in my
case, Polish word used as the question)?
Answer:
SuperMemo will automatically generate the title from the first text
component in the component order. Your Norsk component is clearly first
in the component order in your template. Choose Component
order on the element menu and drag the
component with your question text to the first position. Then choose OK
and save your element in a new template (choose the same template name as
before, i.e. default item template name)
If you delete a component from a global template, all elements will be affected
(facep2b, Sunday, July 22, 2001 10:29 PM)
Question:
My collection is composed of questions and answers. For some reason, only the answers are showing. What gives?
Answer:
Most likely you have deleted the question component (or changed its display status) in the default global template used in your elements. Try applying another template (e.g.
Classic, Standard, etc.) to see if this is the correct diagnosis. Then you will need to define the appropriate template and save it in place of your default template. Remember to make a backup beforehand!
(Christian
Roessel, Germany, Dec 17,
2000)
Question:
If I save a template, is it safe to delete the source element? Is the
element used to save the template copied or only referenced to in the template
registry?
Answer:
Yes. You can delete the source element. Every template is a separate copy of
data defining the look of elements. Deleting the source element will only
decrease the reference count for a given template. Templates are not deleted
even if the reference count drops to zero
You can drag components inside a template
(Adam, Australia, Mon, May 07, 2001 2:48)
Question:
How can one tell if a transparent image component without an image is present in a template displayed in the template
registry?
Answer:
You can put the template in the editing mode by
Alt+click or by choosing Mode : Editing on the template's pop-up menu
Categories make it possible to select the default template
(Adam, Australia, Mon, May 07, 2001 2:48)
Question:
How do we select a template from the template
registry as the default template?
Answer:
You need to select this template for the current category in the
category registry. For example, choose Search :
Categories, click Template (if you want to use the template with items), select the template from the registry and choose
Accept (at the bottom of the registry window)
You can save a template with objects to associate RTF components with fonts
(Reinhard K. Koehler (private), Fri, Jun 22, 2001 1:35)
Question:
Is there a way to circumvent a limitation of
rich text components that they do not associate a font? I would like to use mixed fonts but still begin with a desired default font
Answer:
You could trick SuperMemo by associating one-letter texts associated with your preferred font. For example, apply
Standard template (based on rich text components). Add different letters to question and answer fields (e.g.
'x' and 'z'). Apply your preferred font. Choose Template : Save with
objects. Select this newly defined template as the default template in your current category
(with Search : Categories)
An item cannot use two templates at the same time (#5888)
(facep2b, Monday, July 23, 2001 8:37 PM)
Question:
There seems to be two
templates being applied at the same time! Superimposed over my questions and answers
Answer:
Each element is made of the source data (e.g. question and answer) and may additionally include a template. There cannot be two templates used with the same element. If you apply a template to an element, the template is filled out with matching source data and displayed in the element window. For example, blue template with empty text fields applied to a green source with non-empty text will show as a blue element with non-empty texts taken from the source
If Add New does not create needed components, you can redefine the
template (#5866)
(noam-at, Israel, Aug 04, 2001)
Question:
When I click Add New, I get a new item, but SuperMemo doesn't create two
editing fields for the question and answer. Instead, I see the gray screen of
SuperMemo without any fields
Answer:
Add New uses the default template to create
new items. If you delete all components (e.g. question and answer fields) from
the default template, Add New will add new elements that look empty. If
you want to restore your question and answer components, you need to redefine
the template. If you are not very fluent with templates, locate an element in
your collection that looks ok and choose Template : Save as template
on the element pop-up menu. This will save the look
of the selected element in the default template. Add New will then
replicate this look