Blame Manual/repository-html/repository_59.html

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

1.58 The <tt>`trunk/Scripts/Bash/Cli/Functions/Render'</tt> Directory

ee1f37
b130a0

The render functionality exists to produce both identity and

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

b130a0

The render functionality relies on "renderable directory

b130a0
structures" to produce files. Renderable directory structures can be
b130a0
either "identity directory structures" or "translation directory
b130a0
structures" with special directories inside.
ee1f37

ee1f37
b130a0
b130a0

1.58.1 Renderable identity directory structures

ee1f37
b130a0

Renderable identity directory structures are the starting point of

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

b130a0

Inside the working copy, one renderable identity directory structures

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

b130a0

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

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

b130a0

Inside renderable identity directory structures, content production is

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

010b2d
b130a0
b130a0

1.58.1.1 Design template without translation

aaf678
b130a0

The design template without translation configuration is based on a

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

b130a0

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

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

b130a0
b130a0
One renderable identity directory structure:
b130a0
b130a0

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

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

b130a0

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

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

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

Inside design template directory, design template files are based on

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

b130a0

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

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

b130a0

The CENTOSARTWORK word itself is a convenction name we use to

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

b130a0
info

Note

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

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

aaf678
b130a0

When a renderable identity directory structure is configured to

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

b130a0

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

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

b130a0

See section The <tt>`trunk/Identity'</tt> Directory, for more information.

b130a0

b130a0
b130a0
One translation directory structure:
b130a0
b130a0

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

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

b130a0

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

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

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

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

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

b130a0

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

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

b130a0

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

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

b130a0

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

b130a0

b130a0
b130a0
One pre-rendition configuration script:
b130a0
b130a0

In order to make an identity directory structure renderable, a

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

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

In this configuration the pre-rendition configuration script

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

b130a0
function render_loadConfig {
010b2d
b130a0
    # Define rendition actions.
010b2d
    ACTIONS[0]='BASE:renderImage'
010b2d
010b2d
}
010b2d
b130a0

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

b130a0
assumes a "design template without translation" configuration to
b130a0
produce untranslated images.
ee1f37

b130a0

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

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

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

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

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

b130a0

-- Removed(xref:trunk Scripts Bash Functions Render Config) --, for more

b130a0
information.
b130a0

b130a0
010b2d
010b2d
b130a0
b130a0

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

b130a0
b130a0

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

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

b130a0

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

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

b130a0

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

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

b130a0

The pre-rendition configuration script used to produce untranslated

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

b130a0
info

Note

If we use no translation file in the translation entry

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

aaf678
b130a0

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

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

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

1.58.1.3 Design template with translation (optimized)

b130a0
b130a0

Producing translated images satisfies almost all our production images

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

b130a0

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

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

b130a0

The MATCHINGLIST variable is set in the pre-rendition

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

b130a0

For example, consider the following configuration:

b130a0

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

In this configuration we want to produce three images using a

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

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

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

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

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

In order to produce different translated images using specific design

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

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

In this configuration the pre-rendition configuration script

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

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

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

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

b130a0
b130a0
010b2d
b130a0
b130a0

1.58.1.4 Design template with translation (optimized+flexibility)

010b2d
b130a0

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

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

b130a0

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

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

b130a0

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

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

b130a0

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

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

b130a0

At this point there are two independent worklines: one directory

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

b130a0

For example, consider the following configuration:

ee1f37

010b2d
b130a0
One entry under <tt>`trunk/Identity/Themes/Models/'</tt>:
010b2d
b130a0

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

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

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

Inisde design models, dynamic backgrounds are required in order for

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

ee1f37
b130a0
One entry under <tt>`trunk/Identity/Themes/Motifs/'</tt>:
010b2d
b130a0

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

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

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

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

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

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

There is one pre-rendition configuration script for each theme

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

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

In this configuration the pre-rendition configuration script

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

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

The production flow of "optimize+flexibility" configuration…

b130a0

b130a0
b130a0

1.58.2 Renderable translation directory structures

b130a0
b130a0

Translation directory structures are auxiliar structures of renderable

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

b130a0

In order to aliviate production of translation file, we made

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

b130a0

If for some reason, translation files get far from translation

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

b130a0

Inside renderable translation directory structures,

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

b130a0
b130a0
b130a0

1.58.3 Copying renderable directory structures

b130a0
b130a0

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

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

b130a0

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

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

b130a0

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

b130a0
directory structure copied should match the following conditions:
b130a0

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

    As convenction, the render_doCopy function uses

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

    b130a0

    Design templates + No translation:

    b130a0

    b130a0

    Command:

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

    b130a0

    Sources:

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

    b130a0

    Targets:

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

    b130a0

    Renderable layout 2:

    b130a0

    b130a0

    Command:

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

    b130a0

    Sources:

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

    b130a0

    Targets:

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

    b130a0

    Notice that design models are not included in source or target

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

    b130a0

    Notice how translations and pre-rendition configuration scripts may

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

    b130a0

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

    b130a0
      copy a directory structure to itself.
    b130a0

    b130a0

    - The common directory structures represent the default value to use

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

    b130a0

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

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

    b130a0

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

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

    b130a0

    - The specific auxiliar directories are optional.

    b130a0

    b130a0

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

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

    b130a0

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

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

    b130a0

    The `render_doCopy' functionality does duplicate directory structures

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

    b130a0
    b130a0
    b130a0

    1.58.4 Usage

    b130a0
    b130a0
      b130a0
    • ...
    • b130a0
      982d5c
      982d5c
      b130a0
      b130a0

      1.58.5 See also

      b130a0
      ee1f37
      ee1f37
      ee1f37
      b130a0
      [ < ]
      b130a0
      [ > ]
      ee1f37
         
      aaf678
      [ << ]
      b130a0
      [ Up ]
      b130a0
      [ >> ]
      ee1f37
      ee1f37

      ee1f37
       <font size="-1">
      406f69
        This document was generated on March, 1 2011 using texi2html 1.76.
      ee1f37
       </font>
      ee1f37
       
      ee1f37
      ee1f37

      ee1f37
      </body>
      ee1f37
      </html>