Blame Manual/repository-html/repository_78.html

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

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

52772c
52772c

The render functionality exists to produce both identity and

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

52772c

The render functionality relies on "renderable directory

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

52772c
52772c
52772c

2.71.1 Renderable identity directory structures

52772c
52772c

Renderable identity directory structures are the starting point of

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

52772c

Inside the working copy, one renderable identity directory structures

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

52772c

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

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

52772c

Inside renderable identity directory structures, content production is

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

52772c
52772c
52772c

2.71.1.1 Design template without translation

52772c
52772c

The design template without translation configuration is based on a

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

52772c

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

52772c
use in producing text-based files without translations), consider the
52772c
following configuration:
06d106

06d106
52772c
One renderable identity directory structure:
52772c
52772c

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

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

52772c

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

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

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

Inside design template directory, design template files are based on

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

52772c

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

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

52772c

The CENTOSARTWORK word itself is a convenction name we use to

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

52772c
info

Note

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

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

52772c
52772c

When a renderable identity directory structure is configured to

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

52772c

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

52772c
without translation" configuration at <tt>`trunk/Identity/Models/'</tt>.
06d106

1856b7

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

06d106

06d106
52772c
One translation directory structure:
52772c
52772c

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

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

52772c

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

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

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

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

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

52772c

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

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

52772c

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

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

52772c

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

06d106

06d106
52772c
One pre-rendition configuration script:
52772c
52772c

In order to make an identity directory structure renderable, a

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

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

In this configuration the pre-rendition configuration script

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

52772c
function render_loadConfig {
52772c
52772c
    # Define rendition actions.
52772c
    ACTIONS[0]='BASE:renderImage'
52772c
52772c
}
52772c
52772c

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

52772c
assumes a "design template without translation" configuration to
52772c
produce untranslated images.
52772c

52772c

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

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

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

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

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

52772c

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

52772c
information.
06d106

06d106
9bfd15
9bfd15
52772c
52772c

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

9bfd15
52772c

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

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

52772c

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

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

52772c

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

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

52772c

The pre-rendition configuration script used to produce untranslated

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

52772c
info

Note

If we use no translation file in the translation entry

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

52772c
52772c

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

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

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

2.71.1.3 Design template with translation (optimized)

9bfd15
52772c

Producing translated images satisfies almost all our production images

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

52772c

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

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

52772c

The MATCHINGLIST variable is set in the pre-rendition

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

52772c

For example, consider the following configuration:

52772c

06d106
52772c
One entry under <tt>`trunk/Identity/'</tt>:
52772c
52772c

In this configuration we want to produce three images using a

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

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

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

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

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

In order to produce different translated images using specific design

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

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

In this configuration the pre-rendition configuration script

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

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

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

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

06d106
9bfd15
52772c
52772c
52772c

2.71.1.4 Design template with translation (optimized+flexibility)

52772c
52772c

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

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

52772c

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

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

52772c

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

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

52772c

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

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

52772c

At this point there are two independent worklines: one directory

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

52772c

For example, consider the following configuration:

52772c

52772c
52772c
One entry under <tt>`trunk/Identity/Themes/Models/'</tt>:
52772c
52772c

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

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

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

Inisde design models, dynamic backgrounds are required in order for

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

52772c
52772c
One entry under <tt>`trunk/Identity/Themes/Motifs/'</tt>:
52772c
52772c

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

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

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

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

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

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

There is one pre-rendition configuration script for each theme

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

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

In this configuration the pre-rendition configuration script

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

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

The production flow of "optimize+flexibility" configuration…

52772c

52772c
52772c

2.71.2 Renderable translation directory structures

52772c
52772c

Translation directory structures are auxiliar structures of renderable

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

52772c

In order to aliviate production of translation file, we made

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

52772c

If for some reason, translation files get far from translation

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

52772c

Inside renderable translation directory structures,

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

52772c
52772c
52772c

2.71.3 Copying renderable directory structures

06d106
52772c

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

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

52772c

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

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

52772c

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

52772c
directory structure copied should match the following conditions:
52772c

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

    As convenction, the render_doCopy function uses

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

    52772c

    Design templates + No translation:

    52772c

    52772c

    Command:

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

    52772c

    Sources:

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

    52772c

    Targets:

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

    52772c

    Renderable layout 2:

    52772c

    52772c

    Command:

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

    52772c

    Sources:

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

    52772c

    Targets:

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

    52772c

    Notice that design models are not included in source or target

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

    52772c

    Notice how translations and pre-rendition configuration scripts may

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

    52772c

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

    52772c
      copy a directory structure to itself.
    52772c

    52772c

    - The common directory structures represent the default value to use

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

    52772c

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

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

    52772c

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

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

    52772c

    - The specific auxiliar directories are optional.

    52772c

    52772c

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

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

    52772c

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

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

    52772c

    The `render_doCopy' functionality does duplicate directory structures

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

    52772c
    52772c
    52772c

    2.71.4 Usage

    52772c
    52772c
      52772c
    • ...
    • 52772c
      52772c
      06d106
      52772c
      52772c

      2.71.5 See also

      9bfd15
      632e8b
      632e8b
      632e8b
      52772c
      [ < ]
      1856b7
      [ > ]
      632e8b
         
      1856b7
      [ << ]
      52772c
      [ Up ]
      1856b7
      [ >> ]
      632e8b
      632e8b

      632e8b
       <font size="-1">
      52772c
        This document was generated on March, 22 2011 using texi2html 1.76.
      632e8b
       </font>
      632e8b
       
      632e8b
      632e8b

      632e8b
      </body>
      632e8b
      </html>