Difference between revisions of "File:Project-structure.png"

From Wiki
Jump to navigation Jump to search
(added flow chart code)
(Mkii --> Mark II)
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
ConTeXt project structure as flow chart
+
ConTeXt project structure as a flow chart
  
Code for the flow chart: (setup see [[ConTeXt info style]])
+
Here is the complete code. Note that this is [[Mark II]] code, and so must be compiled with {{code|texexec}}. If somebody more experienced with the chart module can give separate colors to the project, product, component, and environment boxes, that would be excellent.
  
<pre>
+
<texcode>
 +
\usemodule      [chart]
 +
\setupcolors    [state=start, system=rgb]
 +
 
 +
\definecolor    [green]  [r=.720, g=1, b=.72] % pale green
 +
\definecolor    [pink]  [g=.720, r=1, b=.72] % pale red
 +
\definecolor    [blue]  [g=.720, b=1, g=.72] % pale blue
 +
 
 +
\setupFLOWcharts
 +
    [height=4\bodyfontsize,
 +
    maxwidth=\textwidth,
 +
    offset=none]
 +
 
 +
\setupFLOWlines
 +
    [corner=rectangular,
 +
    color=black]
 +
 
 +
\setupFLOWshapes
 +
    [framecolor=black,
 +
    background=color,
 +
    backgroundcolor=green]
 +
 
 +
\startTEXpage
 
\startFLOWchart[projekte]
 
\startFLOWchart[projekte]
\startFLOWcell
+
    \startFLOWcell
\name {project}
+
        \name   {project}
\location {3,3}
+
        \location   {3,3}
\connection[ntb] {product1}
+
        \connection[rl] {environment1}
\connection[ptb] {product2}
+
        \text  {\ssb Project}
\text {Project}
+
    \stopFLOWcell
\stopFLOWcell
+
    \startFLOWcell
\startFLOWcell
+
        \name  {environment2}
\name {environment}
+
        \location  {5,2}
\location {5,3}
+
        \text   {\ssb Product-specific \\ environment}
\connection[lr] {project}
+
    \stopFLOWcell
\text {Environment}
+
    \startFLOWcell
\stopFLOWcell
+
        \name   {environment1}
 +
        \location   {5,3}
 +
        \text  {\ssb Project-wide \\ environment}
 +
    \stopFLOWcell
  
\startFLOWcell
+
    \startFLOWcell
\name {product1}
+
        \name   {product1}
\location {2,2}
+
        \location   {1,1}
\connection[ntb] {comp11}
+
        %\connection[tb]    {comp11}
\connection[tb] {comp12}
+
        %\connection[ptb] {comp12}
\text {Product 1}
+
        \location  {2,2}
\stopFLOWcell
+
        \connection[ntb]   {comp11}
\startFLOWcell
+
        \connection[tb] {comp12}
\name {product2}
+
        \connection[btn]    {project}
\location {4,2}
+
        \text   {\ssb Product 1}
\connection[ntb] {comp21}
+
    \stopFLOWcell
\connection[tb] {comp22}
+
    \startFLOWcell
\connection[ptb] {comp23}
+
        \name   {product2}
\text {Product 2}
+
        \location   {4,2}
\stopFLOWcell
+
        \connection[ntb]   {comp21}
 +
        \connection[tb]     {comp22}
 +
        \connection[ptb]   {comp23}
 +
        \connection[btp]    {project}
 +
        \connection[rl]    {environment2}
 +
        \text   {\ssb Product 2}
 +
    \stopFLOWcell
  
\startFLOWcell
+
    \startFLOWcell
\name {comp11}
+
        \name   {comp11}
\location {1,1}
+
        \location   {1,1}
\text {Component A}
+
        \text   {\ssb Component A}
\stopFLOWcell
+
    \stopFLOWcell
\startFLOWcell
+
    \startFLOWcell
\name {comp12}
+
        \name   {comp12}
\location {2,1}
+
        \location   {2,1}
\text {Component B}
+
        \text   {\ssb Component B}
\stopFLOWcell
+
    \stopFLOWcell
\startFLOWcell
+
    \startFLOWcell
\name {comp21}
+
        \name   {comp21}
\location {3,1}
+
        \location   {3,1}
\text {Component X}
+
        \text   {\ssb Component X}
\stopFLOWcell
+
    \stopFLOWcell
\startFLOWcell
+
    \startFLOWcell
\name {comp22}
+
        \name   {comp22}
\location {4,1}
+
        \location   {4,1}
\text {Component Y}
+
        \text   {\ssb Component Y}
\stopFLOWcell
+
    \stopFLOWcell
\startFLOWcell
+
    \startFLOWcell
\name {comp23}
+
        \name   {comp23}
\location {5,1}
+
        \location   {5,1}
\text {Component Z}
+
        \text   {\ssb Component Z}
\stopFLOWcell
+
    \stopFLOWcell
 
\stopFLOWchart
 
\stopFLOWchart
  
 
\FLOWchart[projekte]
 
\FLOWchart[projekte]
</pre>
+
 
 +
\stopTEXpage
 +
</texcode>

Latest revision as of 12:08, 7 August 2012

ConTeXt project structure as a flow chart

Here is the complete code. Note that this is Mark II code, and so must be compiled with texexec. If somebody more experienced with the chart module can give separate colors to the project, product, component, and environment boxes, that would be excellent.

\usemodule      [chart]
\setupcolors    [state=start, system=rgb]

\definecolor    [green]  [r=.720, g=1, b=.72] % pale green
\definecolor    [pink]  [g=.720, r=1, b=.72] % pale red
\definecolor    [blue]  [g=.720, b=1, g=.72] % pale blue

\setupFLOWcharts
    [height=4\bodyfontsize,
     maxwidth=\textwidth,
     offset=none]

\setupFLOWlines
    [corner=rectangular,
     color=black]

\setupFLOWshapes
    [framecolor=black,
     background=color,
     backgroundcolor=green]

\startTEXpage
\startFLOWchart[projekte]
    \startFLOWcell
        \name   {project}
        \location   {3,3}
        \connection[rl] {environment1}
        \text   {\ssb Project}
    \stopFLOWcell
    \startFLOWcell
        \name   {environment2}
        \location   {5,2}
        \text   {\ssb Product-specific \\ environment}
    \stopFLOWcell
    \startFLOWcell
        \name   {environment1}
        \location   {5,3}
        \text   {\ssb Project-wide \\ environment}
    \stopFLOWcell

    \startFLOWcell
        \name   {product1}
        \location   {1,1}
        %\connection[tb]    {comp11}
        %\connection[ptb] {comp12}
        \location   {2,2}
        \connection[ntb]    {comp11}
        \connection[tb] {comp12}
        \connection[btn]    {project}
        \text   {\ssb Product 1}
    \stopFLOWcell
    \startFLOWcell
        \name   {product2}
        \location   {4,2}
        \connection[ntb]    {comp21}
        \connection[tb]     {comp22}
        \connection[ptb]    {comp23}
        \connection[btp]    {project}
        \connection[rl]    {environment2}
        \text   {\ssb Product 2}
    \stopFLOWcell

    \startFLOWcell
        \name   {comp11}
        \location   {1,1}
        \text   {\ssb Component A}
    \stopFLOWcell
    \startFLOWcell
        \name   {comp12}
        \location   {2,1}
        \text   {\ssb Component B}
    \stopFLOWcell
    \startFLOWcell
        \name   {comp21}
        \location   {3,1}
        \text   {\ssb Component X}
    \stopFLOWcell
    \startFLOWcell
        \name   {comp22}
        \location   {4,1}
        \text   {\ssb Component Y}
    \stopFLOWcell
    \startFLOWcell
        \name   {comp23}
        \location   {5,1}
        \text   {\ssb Component Z}
    \stopFLOWcell
\stopFLOWchart

\FLOWchart[projekte]

\stopTEXpage

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current12:03, 7 August 2012Thumbnail for version as of 12:03, 7 August 2012720 × 204 (85 KB)Esteis (talk | contribs)Arrow direction: make A --> B mean 'A invokes B' Resolution: 720 px to fit the main content column Colors: nicer
13:01, 28 July 2004Thumbnail for version as of 13:01, 28 July 2004888 × 235 (3 KB)Hraban (talk | contribs)ConTeXt project structure as flow chart

The following page uses this file: