Blame Manuals/Repository/repository-html/repository_58.html

4c79b5
4c79b5
<html>
ccb7a3
4c79b5
4c79b5
Permission is granted to copy, distribute and/or modify this document
4c79b5
under the terms of the GNU Free Documentation License, Version 1.2 or
4c79b5
any later version published by the Free Software Foundation; with no
4c79b5
Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A
4c79b5
copy of the license is included in the section entitled GNU Free
4c79b5
Documentation License.  
4c79b5
-->
bf28e1
4c79b5
4c79b5
Written by: Lionel Cons <Lionel.Cons@cern.ch> (original author)
4c79b5
            Karl Berry  <karl@freefriends.org>
4c79b5
            Olaf Bachmann <obachman@mathematik.uni-kl.de>
4c79b5
            and many others.
4c79b5
Maintained by: Many creative people <dev@texi2html.cvshome.org>
4c79b5
Send bugs and suggestions to <users@texi2html.cvshome.org>
4c79b5
4c79b5
-->
4c79b5
<head>
d11e55
<title>CentOS Artwork Repository: 3.55 trunk/Scripts/Bash/Functions/Render</title>
4c79b5
d11e55
<meta name="description" content="CentOS Artwork Repository: 3.55 trunk/Scripts/Bash/Functions/Render">
d11e55
<meta name="keywords" content="CentOS Artwork Repository: 3.55 trunk/Scripts/Bash/Functions/Render">
4c79b5
<meta name="resource-type" content="document">
4c79b5
<meta name="distribution" content="global">
4c79b5
<meta name="Generator" content="texi2html 1.76">
4c79b5
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
4c79b5
<style type="text/css">
4c79b5
1e9202
@import "/home/centos/artwork/trunk/Identity/Models/Css/Texi2html/common.css";
4c79b5
4c79b5
a.summary-letter {text-decoration: none}
4c79b5
pre.display {font-family: serif}
4c79b5
pre.format {font-family: serif}
4c79b5
pre.menu-comment {font-family: serif}
4c79b5
pre.menu-preformatted {font-family: serif}
4c79b5
pre.smalldisplay {font-family: serif; font-size: smaller}
4c79b5
pre.smallexample {font-size: smaller}
4c79b5
pre.smallformat {font-family: serif; font-size: smaller}
4c79b5
pre.smalllisp {font-size: smaller}
4c79b5
span.sansserif {font-family:sans-serif; font-weight:normal;}
4c79b5
ul.toc {list-style: none}
4c79b5
-->
4c79b5
</style>
4c79b5
4c79b5
4c79b5
</head>
4c79b5
4c79b5
<body lang="en" bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080" alink="#FF0000">
4c79b5
300762
d11e55
[ < ]
d11e55
[ > ]
4c79b5
   
4c79b5
[ << ]
300762
[ Up ]
d11e55
[ >> ]
4c79b5
   
4c79b5
   
4c79b5
   
4c79b5
   
4c79b5
[Top]
4c79b5
[Contents]
d11e55
[Index]
4c79b5
[ ? ]
4c79b5
d11e55
d11e55
d11e55

3.55 trunk/Scripts/Bash/Functions/Render

166893
d11e55

The render functionality exists to produce both identity and

d11e55
translation files on different levels of information (i.e., different
d11e55
languages, release numbers, architectures, etc.).
d11e55

d11e55

The render functionality relies on "renderable directory

d11e55
structures" to produce files. Renderable directory structures can be
d11e55
either "identity directory structures" or "translation directory
d11e55
structures" with special directories inside.
7fa1fb

2b5e61
d11e55
d11e55

3.55.1 Renderable identity directory structures

c2a1bc
d11e55

Renderable identity directory structures are the starting point of

d11e55
identity rendition. Whenever we want to render a component of CentOS
d11e55
corporate visual identity, we need to point <tt>`centos-art.sh'</tt> to a
d11e55
renderable identity directory structure. If such renderable identity
d11e55
directory structure doesn't exist, then it is good time to create it. 
bf28e1

d11e55

Inside the working copy, one renderable identity directory structures

d11e55
represents one visual manifestation of CentOS corporate visual
d11e55
identity, or said differently, each visual manifestation of CentOS
d11e55
corporate visual identity should have one renderable identity
d11e55
directory structure.
d11e55

d11e55

Inside renderable identity directory structures, <tt>`centos-art.sh'</tt>

d11e55
can render both image-based and text-based files. Specification of
d11e55
whether a renderable identity directory structure produces image-based
d11e55
or text-based content is a configuration action that takes place in
d11e55
the pre-rendition configuration script of that renderable identity
d11e55
directory structure.
d11e55

d11e55

Inside renderable identity directory structures, content production is

d11e55
organized in different configurations. A content production
d11e55
configuration is a unique combination of the components that make an
d11e55
identity directory structure renderable. One content production
d11e55
configuration does one thing only (e.g., to produce untranslated
d11e55
images), but it can be extended (e.g., adding translation files) to
d11e55
achieve different needs (e.g., to produce translated images).
bf28e1

c2a1bc
d11e55
d11e55

3.55.1.1 Design template without translation

d11e55
d11e55

The design template without translation configuration is based on a

d11e55
renderable identity directory structure with an empty translation
d11e55
directory structure. In this configuration, one design template
d11e55
produces one untranslated file. Both design templates and final
d11e55
untranslated files share the same file name, but they differ one
d11e55
another in file-type and file-extension.
bf28e1

d11e55

For example, to produce images without translations (there is no much

d11e55
use in producing text-based files without translations), consider the
d11e55
following configuration:
d11e55

d11e55
d11e55
One renderable identity directory structure:
d11e55
d11e55

In this example we used <tt>`Identity/Path/To/Dir'</tt> as the identity

d11e55
component we want to produce untranslated images for.  Identity
d11e55
components can be either under <tt>`trunk/'</tt> or <tt>`branches/'</tt>
d11e55
directory structure.
d11e55

d11e55

The identity component (i.e., <tt>`Identity/Path/To/Dir'</tt>, in this

d11e55
case) is also the bond component we use to connect the identity
d11e55
directory structures with their respective auxiliar directories (i.e.,
d11e55
translation directory structres and pre-rendition configuration
d11e55
structures).  The bond component is the path convenction that
d11e55
<tt>`centos-art.sh'</tt> uses to know where to look for related
d11e55
translations, configuration scripts and whatever auxiliar thing a
d11e55
renderable directory structure may need to have.
d11e55

d11e55
      | The bond component
d11e55
      |----------------->|
d11e55
trunk/Identity/Path/To/Dir  <-- Renderable identity directory structure.
d11e55
|-- Tpl                     <-- Design template directory.
d11e55
|   `-- file.svg            <-- Design template file.
d11e55
`-- Img                     <-- Directory used to store final files.
d11e55
    `-- file.png            <-- Final image-based file produced from
d11e55
                                design template file.
d11e55
d11e55

Inside design template directory, design template files are based on

d11e55
SVG (Scalable Vector Graphics) and use the extension
d11e55
.svg.  Design template files can be organized using several
d11e55
directory levels to create a simple but extensible configuration,
d11e55
specially if translated images are not required.
bf28e1

d11e55

In order for SVG (Scalable Vector Graphics) files to be

d11e55
considered "design template" files, they should be placed under the
d11e55
design template directory and to have set a CENTOSARTWORK
d11e55
object id inside.
d11e55

d11e55

The CENTOSARTWORK word itself is a convenction name we use to

d11e55
define which object/design area, inside a design template, the
d11e55
<tt>`centos-art.sh'</tt> script will use to export as
d11e55
PNG (Portable Network Graphic) image at rendition time.
d11e55
Whithout such object id specification, the <tt>`centos-art.sh'</tt> script
d11e55
cannot know what object/design area you (as designer) want to export
d11e55
as PNG (Portable Network Graphic) image file.
d11e55

d11e55
info

Note

At rendition time, the content of <tt>`Img/'</tt> directory

d11e55
structure is produced by <tt>`centos-art.sh'</tt> automatically.
d11e55

7e35dc
d11e55

When a renderable identity directory structure is configured to

d11e55
produce image-based content, <tt>`centos-art.sh'</tt> produces
d11e55
PNG (Portable Network Graphics) files with the .png
d11e55
extension. Once the base image format has been produced, it is
d11e55
possible for <tt>`centos-art.sh'</tt> to use it in order to automatically
d11e55
create other image formats that may be needed (see section trunk/Scripts/Bash/Functions/Render/Config).
d11e55

d11e55

Inside the working copy, you can find an example of "design template

d11e55
without translation" configuration at <tt>`trunk/Identity/Models/'</tt>.
d11e55

d11e55

See section trunk/Identity, for more information.

d11e55

d11e55
d11e55
One translation directory structure:
d11e55
d11e55

In order for an identity entry to be considered an identity renderable

d11e55
directory structure, it should have a translation entry. The content
d11e55
of the translation entry is relevant to determine how to process the
d11e55
identity renderable directory entry.
d11e55

d11e55

If the translation entry is empty (i.e., there is no file inside it),

d11e55
<tt>`centos-art.sh'</tt> interprets the identity renderable directory
d11e55
structure as a "design templates without translation" configuration.
d11e55

d11e55
                   | The bond component
d11e55
                   |----------------->|
d11e55
trunk/Translations/Identity/Path/To/Dir
d11e55
`-- (empty)
d11e55
d11e55

If the translation entry is not empty, <tt>`centos-art.sh'</tt> can

d11e55
interpret the identity renderable directory structure as one of the
d11e55
following configurations: "design template with translation
d11e55
(one-to-one)" or "design template with translation (optimized)".
d11e55
Which one of these configurations is used depends on the value
d11e55
assigned to the matching list (MATCHINGLIST) variable in the
d11e55
pre-rendition configuration script of the renderable identity
d11e55
directory structure we are producing images for.
d11e55

d11e55

If the matching list variable is empty (as it is by default), then

d11e55
"design template with translation (one-to-one)" configuration is
d11e55
used. In this configuration it is required that both design templates
d11e55
and translation files have the same file names. This way, one
d11e55
translation files is applied to one design template, to produce
d11e55
one translated image.
d11e55

d11e55

If the matching list variable is not empty (because you redefine it in

d11e55
the pre-rendition configuration script), then "design template with
d11e55
translation (optimized)" configuration is used instead. In this
d11e55
configuration, design templates and translation files don't need to
d11e55
have the same names since such name relationship between them is
d11e55
specified in the matching list properly.
d11e55

d11e55

-- Removed(xref:trunk Translations) --, for more information.

d11e55

d11e55
d11e55
One pre-rendition configuration script:
d11e55
d11e55

In order to make an identity directory structure renderable, a

d11e55
pre-rendition configuration script should exist for it.  The
d11e55
pre-rendition configuration script specifies what type of rendition
d11e55
does <tt>`centos-art.sh'</tt> will perform over the identity directory
d11e55
structure and how does it do that.
d11e55

d11e55
                                           | The bond component
d11e55
                                           |----------------->|
d11e55
trunk/Scripts/Bash/Functions/Render/Config/Identity/Path/To/Dir
d11e55
`-- render.conf.sh
d11e55
d11e55

In this configuration the pre-rendition configuration script

d11e55
(<tt>`render.conf.sh'</tt>) would look like the following:
d11e55

d11e55
function render_loadConfig {
2dc146
d11e55
    # Define rendition actions.
2dc146
    ACTIONS[0]='BASE:renderImage'
2dc146
2dc146
}
4a9d2a
d11e55

Since translation directory structure is empty, <tt>`centos-art.sh'</tt>

d11e55
assumes a "design template without translation" configuration to
d11e55
produce untranslated images.
7fa1fb

d11e55

To produce untranslated images, <tt>`centos-art.sh'</tt> takes one design

d11e55
template and creates one temporal instance from it.  Later,
d11e55
<tt>`centos-art.sh'</tt> uses the temporal design template instance as
d11e55
source file to export the final untranslated image. The action of
d11e55
exporting images from SVG (Scalable Vector Graphics) to
d11e55
PNG (Portable Network Graphics) is possible thanks to
d11e55
Inkscape's command-line interface and the CENTOSARTWORK object
d11e55
id we previously set inside design templates.
d11e55

d11e55
centos-art.sh render --identity=trunk/Identity/Path/To/Dir
d11e55
-------------------------------------------------
d11e55
0 | Execute centos-art.sh on renderable identity directory structure.
d11e55
--v----------------------------------------------
d11e55
trunk/Identity/Path/To/Dir/Tpl/file.svg
d11e55
-------------------------------------------------
d11e55
1 | Create instance from design template.
d11e55
--v----------------------------------------------
d11e55
/tmp/centos-art.sh-a07e824a-5953-4c21-90ae-f5e8e9781f5f-file.svg
d11e55
-------------------------------------------------
d11e55
2 | Render untranslated image from design template instance.
d11e55
--v----------------------------------------------
d11e55
trunk/Identity/NewDir/Img/file.png
d11e55
-------------------------------------------------
d11e55
3 | Remove design template instance.
7e35dc
d11e55

Finally, when the untranslated image has been created, the temporal

d11e55
design template instance is removed. At this point,
d11e55
<tt>`centos-art.sh'</tt> takes the next design template and repeats the
d11e55
whole production flow once again (design template by design template),
d11e55
until all design templates be processed.
bf28e1

d11e55

See section trunk/Scripts/Bash/Functions/Render/Config, for more

d11e55
information.
d11e55

d11e55
c2a1bc
c2a1bc
d11e55
d11e55

3.55.1.2 Design template with translation (one-to-one)

d11e55
d11e55

Producing untranslated images is fine in many cases, but not always.

d11e55
Sometimes it is required to produce images in different languages and
d11e55
that is something that untrasnlated image production cannot achieve.
d11e55
However, if we fill its empty translation entry with translation files
d11e55
(one for each design template) we extend the production flow from
d11e55
untranslated image production to translated image production.
d11e55

d11e55

In order for <tt>`centos-art.sh'</tt> to produce images correctly, each

d11e55
design template should have one translation file and each translation
d11e55
file should have one design template.  Otherwise, if there is a
d11e55
missing design template or a missing translation file,
d11e55
<tt>`centos-art.sh'</tt> will not produce the final image related to the
d11e55
missing component.
d11e55

d11e55

In order for <tt>`centos-art.sh'</tt> to know which is the relation

d11e55
between translation files and design templates the translation
d11e55
directory structure is taken as reference.  For example, the
d11e55
<tt>`trunk/Translations/Identity/Path/To/Dir/file.sed'</tt> translation
d11e55
file does match <tt>`trunk/Identity/Path/To/Dir/Tpl/file.svg'</tt> design
d11e55
template, but it doesn't match
d11e55
<tt>`trunk/Identity/Path/To/Dir/File.svg'</tt> or
d11e55
<tt>`trunk/Identity/Path/To/Dir/Tpl/File.svg'</tt> or
d11e55
<tt>`trunk/Identity/Path/To/Dir/Tpl/SubDir/file.svg'</tt> design
d11e55
templates.
7fa1fb

d11e55

The pre-rendition configuration script used to produce untranslated

d11e55
images is the same we use to produce translated images. There is no
d11e55
need to modify it. So, as we are using the same pre-rendition
d11e55
configuration script, we can say that translated image production is
d11e55
somehow an extended/improved version of untranslated image production.
d11e55

d11e55
info

Note

If we use no translation file in the translation entry

d11e55
(i.e., an empty directory), <tt>`centos-art.sh'</tt> assumes the
d11e55
untranslated image production. If we fill the translation entry with
d11e55
translation files, <tt>`centos-art.sh'</tt> assumes the translated image
d11e55
production.  
d11e55

7e35dc
d11e55

To produce final images, <tt>`centos-art.sh'</tt> applies one translation

d11e55
file to one design template and produce a translated design template
d11e55
instance. Later, <tt>`centos-art.sh'</tt> uses the translated template
d11e55
instance to produce the translated image. Finally, when the translated
d11e55
image has been produced, <tt>`centos-art.sh'</tt> removes the translated
d11e55
design template instance. This production flow is repeated for each
d11e55
translation file available in the translatio entry. 
d11e55

d11e55
centos-art.sh render --identity=trunk/Identity/Path/To/Dir
d11e55
-------------------------------------------------
d11e55
0 | Execute centos-art.sh on directory structure.
d11e55
--v----------------------------------------------
d11e55
trunk/Translations/Identity/Path/To/Dir/file.sed
d11e55
-------------------------------------------------
d11e55
1 | Apply translation to design template.
d11e55
--v----------------------------------------------
d11e55
trunk/Identity/Path/To/Dir/Tpl/file.svg
d11e55
-------------------------------------------------
d11e55
2 | Create design template instance.
d11e55
--v----------------------------------------------
d11e55
/tmp/centos-art.sh-a07e824a-5953-4c21-90ae-f5e8e9781f5f-file.svg
d11e55
-------------------------------------------------
d11e55
3 | Render PNG image from template instance.
d11e55
--v----------------------------------------------
d11e55
trunk/Identity/NewDir/Img/file.png
d11e55
-------------------------------------------------
d11e55
4 | Remove design template instance.
4a9d2a
d11e55
d11e55
d11e55

3.55.1.3 Design template with translation (optimized)

d11e55
d11e55

Producing translated images satisfies almost all our production images

d11e55
needs, but there is still a pitfall in them. In order to produce
d11e55
translated images as in the "one-to-one" configuration describes
d11e55
previously, it is required that one translation file has one design
d11e55
template. That's useful in many cases, but what would happen if we
d11e55
need to apply many different translation files to the same design
d11e55
template?  Should we have to duplicate the same design template file
d11e55
for each translation file, in order to satisfy the "one-to-one"
d11e55
relation? What if we need to assign translation files to design
d11e55
templates arbitrarily?
d11e55

d11e55

Certenly, that's something the "one-to-one" configuration cannot

d11e55
handle.  So, that's why we had to "optimize" it. The optimized
d11e55
configuration consists on using a matching list (MATCHINGLIST)
d11e55
variable that specifies the relationship between translation files and
d11e55
design templates in an arbitrary way. Using such matching list between
d11e55
translation files and design templates let us use as many assignment
d11e55
combinations as translation files and design templates we are working
d11e55
with.
d11e55

d11e55

The MATCHINGLIST variable is set in the pre-rendition

d11e55
configuration script of the component we want to produce images for.
d11e55
By default, the MATCHINGLIST variable is empty which means no
d11e55
matching list is used. Otherwise, if MATCHINGLIST variable has a
d11e55
value different to empty value then, <tt>`centos-art.sh'</tt> interprets
d11e55
the matching list in order to know how translation files are applied
d11e55
to design templates.
d11e55

d11e55

For example, consider the following configuration:

d11e55

d11e55
d11e55
One entry under <tt>`trunk/Identity/'</tt>:
d11e55
d11e55

In this configuration we want to produce three images using a

d11e55
paragraph-based style, controlled by <tt>`paragraph.svg'</tt> design
d11e55
template; and one image using a list-based style, controlled by
d11e55
<tt>`list.svg'</tt> design template.
d11e55

d11e55
trunk/Identity/Path/To/Dir
d11e55
|-- Tpl
d11e55
|   |-- paragraph.svg
d11e55
|   `-- list.svg
d11e55
`-- Img
d11e55
    |-- 01-welcome.png
d11e55
    |-- 02-donate.png
d11e55
    |-- 03-docs.png
d11e55
    `-- 04-support.png
2dc146
d11e55
d11e55
One entry under <tt>`trunk/Translations/'</tt>:
d11e55
d11e55

In order to produce translated images we need to have one translation

d11e55
file for each translated image we want to produce. Notice how
d11e55
translation names do match final image file names, but how translation
d11e55
names do not match design template names. When we use matching list
d11e55
there is no need for translation files to match the names of design
d11e55
templates, such name relation is set inside the matching list itself.
d11e55

d11e55
trunk/Translations/Identity/Path/To/Dir
d11e55
|-- 01-welcome.sed
d11e55
|-- 02-donate.sed
d11e55
|-- 03-docs.sed
d11e55
`-- 04-support.sed
4a9d2a
d11e55
d11e55
One entry under <tt>`trunk/trunk/Scripts/Bash/Functions/Render/Config/'</tt>:
d11e55
d11e55

In order to produce different translated images using specific design

d11e55
templates, we need to specify the relation between translation files
d11e55
and design templates in a way that <tt>`centos-art.sh'</tt> could know
d11e55
exactly what translation file to apply to what design template. This
d11e55
relation between translation files and design templates is set using
d11e55
the matching list MATCHINGLIST variable inside the pre-rendition
d11e55
configuration script of the component we want to produce images for.  
d11e55

d11e55
trunk/Scripts/Bash/Functions/Render/Config/Identity/Path/To/Dir
d11e55
`-- render.conf.sh
d11e55
d11e55

In this configuration the pre-rendition configuration script

d11e55
(<tt>`render.conf.sh'</tt>) would look like the following:
7e35dc

d11e55
function render_loadConfig {
d11e55
d11e55
    # Define rendition actions.
d11e55
    ACTIONS[0]='BASE:renderImage'
d11e55
d11e55
    # Define matching list.
d11e55
    MATCHINGLIST="\
d11e55
    paragraph.svg:\
d11e55
        01-welcome.sed\
d11e55
        02-donate.sed\
d11e55
        04-support.sed
d11e55
    list.svg:\
d11e55
        03-docs.sed
d11e55
    "
d11e55
d11e55
}
2dc146
d11e55

As result, <tt>`centos-art.sh'</tt> will produce <tt>`01-welcome.png'</tt>,

d11e55
<tt>`02-donate.png'</tt> and <tt>`04-support.png'</tt> using the
d11e55
paragraph-based design template, but <tt>`03-docs.png'</tt> using the
d11e55
list-based design template.
d11e55

d11e55
6ba043
b8013f
d11e55
d11e55

3.55.1.4 Design template with translation (optimized+flexibility)

d11e55
d11e55

In the production models we've seen so far, there are design templates

d11e55
to produce untranslated images and translation files which combiend
d11e55
with design templates produce translated images. That may seems like
d11e55
all our needs are covered, doesn't it? Well, it almost does.
d11e55

d11e55

Generally, we use design templates to define how final images will

d11e55
look like. Generally, each renderable directory structure has one
d11e55
<tt>`Tpl/'</tt> directory where we organize design templates for that
d11e55
identity component. So, we can say that there is only one unique
d11e55
design template definition for each identity component; or what is the
d11e55
same, said differently, identity components can be produced in one way
d11e55
only, the way its own design template directory specifies.  This is
d11e55
not enough for theme production. It is a limitation, indeed.
d11e55

d11e55

Initially, to create one theme, we created one renderable directory

d11e55
structure for each theme component. When we found ourselves with many
d11e55
themes, and components inside them, it was obvious that the same
d11e55
design model was duplicated inside each theme. As design models were
d11e55
independently one another, if we changed one theme's design model,
d11e55
that change was useless to other themes. So, in order to reuse design
d11e55
model changes, we unified design models into one common directory
d11e55
structure.
d11e55

d11e55

With design models unified in a common structure, another problem rose

d11e55
up. As design models also had the visual style of theme components,
d11e55
there was no difference between themes, so there was no apparent need
d11e55
to have an independent theme directory structure for each different
d11e55
theme.  So, it was also needed to separate visual styles from design
d11e55
models.
d11e55

d11e55

At this point there are two independent worklines: one directory

d11e55
structure to store design models (the final image characteristics
d11e55
[i.e., dimensions, translation markers, etc.]) and one directory
d11e55
structure to store visual styles (the final image visual style [i.e.,
d11e55
the image look and feel]).  So, it is possible to handle both
d11e55
different design models and different visual styles independtly one
d11e55
another and later create combinations among them using
d11e55
<tt>`centos-art.sh'</tt>. 
d11e55

d11e55

For example, consider the following configuration:

2dc146

4a9d2a
d11e55
One entry under <tt>`trunk/Identity/Themes/Models/'</tt>:
2dc146
d11e55

The design model entry exists to organize design model files (similar

d11e55
to design templates). Both design models and design templates are very
d11e55
similar; they both should have the CENTOSARTWORK export id
d11e55
present to identify the exportation area, translation marks, etc.
d11e55
However, design models do use dynamic backgrounds inclusion while
d11e55
design templates don't.
d11e55

d11e55
                        THEMEMODEL | | The bond component
d11e55
                             |<----| |--------------------->|
d11e55
trunk/Identity/Themes/Models/Default/Distro/Anaconda/Progress/
d11e55
|-- paragraph.svg
d11e55
`-- list.svg
d11e55
d11e55

Inisde design models, dynamic backgrounds are required in order for

d11e55
different artistic motifs to reuse common design models. Firstly, in
d11e55
order to create dynamic backgrounds inside design models, we import a
d11e55
bitmap to cover design model's background and later, update design
d11e55
model's path information to replace fixed values to dynamic values.
4a9d2a

2dc146
d11e55
One entry under <tt>`trunk/Identity/Themes/Motifs/'</tt>:
2dc146
d11e55

The artistic motif entry defines the visual style we want to produce

d11e55
images for, only. Final images (i.e., those built from combining both
d11e55
design models and artistic motif backrounds) are not stored here, but
d11e55
under branches directory structure. In the artistic motif entry, we
d11e55
only define those images that cannot be produced automatically by
d11e55
<tt>`centos-art.sh'</tt> (e.g., Backgrounds, Color information,
d11e55
Screenshots, etc.).
2dc146

d11e55
                  Artistic motif name | | Artistic motif backgrounds
d11e55
                             |<-------| |-------->|
d11e55
trunk/Identity/Themes/Motifs/TreeFlower/Backgrounds/
d11e55
|-- Img
d11e55
|   |-- Png
d11e55
|   |   |-- 510x300.png
d11e55
|   |   `-- 510x300-final.png
d11e55
|   `-- Jpg
d11e55
|       |-- 510x300.jpg
d11e55
|       `-- 510x300-final.jpg
d11e55
|-- Tpl
d11e55
|   `-- 510x300.svg
d11e55
`-- Xcf
d11e55
    `-- 510x300.xcf
d11e55
2dc146
d11e55
One entry under <tt>`trunk/Translations/'</tt>:
2dc146
d11e55

The translation entry specifies, by means of translation files, the

d11e55
language-specific information we want to produce image for. When we
d11e55
create the translation entry we don't use the name of neither design
d11e55
model nor artistic motif, just the design model component we want to
d11e55
produce images for.
4a9d2a

d11e55
                                   | The bond component
d11e55
                                   |--------------------->|
d11e55
trunk/Translations/Identity/Themes/Distro/Anaconda/Progress/
d11e55
`-- 5
d11e55
    |-- en
d11e55
    |   |-- 01-welcome.sed
d11e55
    |   |-- 02-donate.sed
d11e55
    |   `-- 03-docs.sed
d11e55
    `-- es
d11e55
        |-- 01-welcome.sed
d11e55
        |-- 02-donate.sed
d11e55
        `-- 03-docs.sed
d11e55
2dc146
d11e55
One entry under <tt>`trunk/Scripts/Bash/Functions/Render/Config/'</tt>:
2dc146
d11e55

There is one pre-rendition configuration script for each theme

d11e55
component. So, each time a theme component is rendered, its
d11e55
pre-rendition configuration script is evaluated to teach
d11e55
<tt>`centos-art.sh'</tt> how to render the component.
bf28e1

d11e55
trunk/Scripts/Bash/Functions/Render/Config/Identity/Themes/Distro/Anaconda/Progress/
d11e55
`-- render.conf.sh
d11e55
d11e55

In this configuration the pre-rendition configuration script

d11e55
(<tt>`render.conf.sh'</tt>) would look like the following:
d11e55

d11e55
function render_loadConfig {
d11e55
d11e55
    # Define rendition actions.
d11e55
    ACTIONS[0]='BASE:renderImage'
d11e55
d11e55
    # Define matching list.
d11e55
    MATCHINGLIST="\
d11e55
    paragraph.svg:\
d11e55
        01-welcome.sed\
d11e55
        02-donate.sed
d11e55
    list.svg:\
d11e55
        03-docs.sed
d11e55
        "
d11e55
d11e55
    # Deifne theme model.
d11e55
    THEMEMODEL='Default'
d11e55
d11e55
}
d11e55
2dc146
2dc146
d11e55

The production flow of "optimize+flexibility" configuration…

d11e55

d11e55
d11e55

3.55.2 Renderable translation directory structures

d11e55
d11e55

Translation directory structures are auxiliar structures of renderable

d11e55
identity directory structures. There is one translation directory
d11e55
structure for each renderable identity directory structure.  Inside
d11e55
translation directory structures we organize translation files used by
d11e55
renderable identity directory structures that produce translated
d11e55
images. Renderable identity directory structures that produce
d11e55
untranslated images don't use translation files, but they do use a
d11e55
translation directory structure, an empty translation directory
d11e55
structure, to be precise.
d11e55

d11e55

In order to aliviate production of translation file, we made

d11e55
translation directory structures renderable adding a template
d11e55
(<tt>`Tpl/'</tt>) directory structure to handle common content inside
d11e55
translation files.  This way, we work on translation templates and
d11e55
later use <tt>`centos-art.sh'</tt> to produce specific translation files
d11e55
(based on translation templates) for different information (e.g.,
d11e55
languages, release numbers, architectures, etc.).  
d11e55

d11e55

If for some reason, translation files get far from translation

d11e55
templates and translation templates become incovenient to produce such
d11e55
translation files then, care should be taken to avoid replacing the
d11e55
content of translation files with the content of translation templates
d11e55
when <tt>`centos-art.sh'</tt> is executed to produce translation files
d11e55
from translation templates.
d11e55

d11e55

Inside renderable translation directory structures,

d11e55
<tt>`centos-art.sh'</tt> can produce text-based files only.
d11e55

d11e55
d11e55
d11e55

3.55.3 Copying renderable directory structures

d11e55
d11e55

A renderable layout is formed by design models, design images,

d11e55
pre-rendition configuration scripts and translations files. This way,
d11e55
when we say to duplicate rendition stuff we are saying to duplicate
d11e55
these four directory structures (i.e., design models, design images,
d11e55
pre-rendition configuration scripts, and related translations files).
d11e55

d11e55

When we duplicate directories, inside `trunk/Identity' directory

d11e55
structure, we need to be aware of renderable layout described above
d11e55
and the source location used to perform the duplication action.  The
d11e55
source location is relevant to centos-art.sh script in order to
d11e55
determine the required auxiliar information inside directory
d11e55
structures that need to be copied too (otherwise we may end up with
d11e55
orphan directory structures unable to be rendered, due the absence of
d11e55
required information).
d11e55

d11e55

In order for a renderable directory structure to be valid, the new

d11e55
directory structure copied should match the following conditions:
d11e55

d11e55
    d11e55
  1. To have a unique directory structure under
  2. d11e55
    <tt>`trunk/Identity'</tt>, organized by any one of the above
    d11e55
    organizational designs above.
    d11e55
    d11e55
  3. To have a unique directory structure under
  4. d11e55
    <tt>`trunk/Translations'</tt> to store translation files.
    d11e55
    d11e55
  5. To have a unique directory structure under
  6. d11e55
    <tt>`trunk/Scripts/Bash/Functions/Render/Config'</tt> to set pre-rendition
    d11e55
    configuration script.
    d11e55
    d11e55
    d11e55

    As convenction, the render_doCopy function uses

    d11e55
    <tt>`trunk/Identity'</tt> directory structure as source location.  Once
    d11e55
    the <tt>`trunk/Identity'</tt> directory structure has been specified and
    d11e55
    verified, the related path information is built from it and copied
    d11e55
    automatically to the new location specified by FLAG_TO variable.
    d11e55

    d11e55

    Design templates + No translation:

    d11e55

    d11e55

    Command:

    d11e55
    - centos-art render -copy=trunk/Identity/Path/To/Dir -to=trunk/Identity/NewPath/To/Dir
    d11e55

    d11e55

    Sources:

    d11e55
    - trunk/Identity/Path/To/Dir
    d11e55
    - trunk/Translations/Identity/Path/To/Dir
    d11e55
    - trunk/Scripts/Bash/Functions/Render/Config/Identity/Path/To/Dir
    d11e55

    d11e55

    Targets:

    d11e55
    - trunk/Identity/NewPath/To/Dir
    d11e55
    - trunk/Translations/Identity/NewPath/To/Dir
    d11e55
    - trunk/Scripts/Bash/Functions/Render/Config/Identity/NewPath/To/Dir
    d11e55

    d11e55

    Renderable layout 2:

    d11e55

    d11e55

    Command:

    d11e55
    - centos-art render -copy=trunk/Identity/Themes/Motifs/TreeFlower \
    d11e55
                        -to=trunk/Identity/Themes/Motifs/NewPath/To/Dir
    d11e55

    d11e55

    Sources:

    d11e55
    - trunk/Identity/Themes/Motifs/TreeFlower
    d11e55
    - trunk/Translations/Identity/Themes
    d11e55
    - trunk/Translations/Identity/Themes/Motifs/TreeFlower
    d11e55
    - trunk/Scripts/Bash/Functions/Render/Config/Identity/Themes
    d11e55
    - trunk/Scripts/Bash/Functions/Render/Config/Identity/Themes/Motifs/TreeFlower
    d11e55

    d11e55

    Targets:

    d11e55
    - trunk/Identity/Themes/Motifs/NewPath/To/Dir
    d11e55
    - trunk/Translations/Identity/Themes
    d11e55
    - trunk/Translations/Identity/Themes/Motifs/NewPath/To/Dir
    d11e55
    - trunk/Scripts/Bash/Functions/Render/Config/Identity/Themes
    d11e55
    - trunk/Scripts/Bash/Functions/Render/Config/Identity/Themes/Motifs/NewPath/To/Dir
    d11e55

    d11e55

    Notice that design models are not included in source or target

    d11e55
    locations. This is intentional. In "Renderable layout 2", design
    d11e55
    models live by their own, they just exist, they are there, available
    d11e55
    for any artistic motif to use. By default `Themes/Models/Default'
    d11e55
    design model directory structure is used, but other design models
    d11e55
    directory structures (under Themes/Models/) can be created and used
    d11e55
    changing the value of THEMEMODEL variable inside the pre-rendition
    d11e55
    configuration script of the artistic motif source location you want to
    d11e55
    produce.
    d11e55

    d11e55

    Notice how translations and pre-rendition configuration scripts may

    d11e55
    both be equal in source and target. This is because such structures
    d11e55
    are common to all artistic motifs (the default values to use when no
    d11e55
    specific values are provided).
    d11e55

    d11e55

    - The common directory structures are not copied or deleted. We cannot

    d11e55
      copy a directory structure to itself.
    d11e55

    d11e55

    - The common directory structures represent the default value to use

    d11e55
      when no specific translations and/or pre-rendition configuration
    d11e55
      script are provided inside source location.
    d11e55

    d11e55

    - The specific directory structures, if present, are both copiable and

    d11e55
      removable. This is, when you perform a copy or delete action from
    d11e55
      source, that source specific auxiliar directories are transfered in
    d11e55
      the copy action to a new location (that specified by FLAG_TO
    d11e55
      variable).
    d11e55

    d11e55

    - When translations and/or pre-rendition configuration scripts are

    d11e55
      found inside the source directory structure, the centos-art.sh
    d11e55
      script loads common auxiliar directories first and later specific
    d11e55
      auxiliar directories.  This way, identity rendition of source
    d11e55
      locations can be customized idividually over the base of common
    d11e55
      default values.
    d11e55

    d11e55

    - The specific auxiliar directories are optional.

    d11e55

    d11e55

    - The common auxiliar directories should be present always. This is,

    d11e55
      in order to provide the information required by render functionality
    d11e55
      (i.e., to make it functional in the more basic level of its
    d11e55
      existence).
    d11e55

    d11e55

    Notice how the duplication process is done from `trunk/Identity' on,

    d11e55
    not the oposite. If you try to duplicate a translation structure (or
    d11e55
    similar auxiliar directory structures like pre-rendition configuration
    d11e55
    scripts), the `trunk/Identity' for that translation is not created.
    d11e55
    This limitation is impossed by the fact that many `trunk/Identity'
    d11e55
    directory structures may reuse/share the same translation directory
    d11e55
    structure. We cannot delete one translation (or similar) directory
    d11e55
    structures while a related `trunk/Identity/' directory structure is
    d11e55
    still in need of it.
    d11e55

    d11e55

    The `render_doCopy' functionality does duplicate directory structures

    d11e55
    directly involved in rendition process only. Once such directories
    d11e55
    have been duplicated, the functionality stops thereat. 
    4a9d2a

    b8013f
    af3979
    d11e55

    3.55.4 Usage

    d11e55
    d11e55
      d11e55
    • ...
    • d11e55
      d11e55
      d11e55
      d11e55
      d11e55

      3.55.5 See also

      300762
      4a9d2a
      d11e55
      3.56 trunk/Scripts/Bash/Functions/Render/Config  
      4a9d2a
      4a9d2a
      bc3531
      38bcd9
      300762
      d11e55
      [ < ]
      d11e55
      [ > ]
      300762
         
      300762
      [ << ]
      d11e55
      [ Up ]
      d11e55
      [ >> ]
      300762
      4c79b5

      4c79b5
       <font size="-1">
      bf28e1
        This document was generated on February, 27 2011 using texi2html 1.76.
      4c79b5
       </font>
      4c79b5
       
      4c79b5
      4c79b5

      4c79b5
      </body>
      4c79b5
      </html>