Author Topic: How can I get the Swimlanes to have a fill color?  (Read 6033 times)

Roger A. Shepherd

  • EA User
  • **
  • Posts: 35
  • Karma: +0/-0
    • View Profile
How can I get the Swimlanes to have a fill color?
« on: April 18, 2006, 10:31:15 am »
Is it possible to set the background color of swimlanes in a BPMN diagram to give it an alternatively shaded 'greenbar paper' effect?  I know the BPMN specification discourages the use of color, but is shading of model elements supported in EA?
If so, how might I accomplish it in the tool?
Thanks  

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: How can I get the Swimlanes to have a fill col
« Reply #1 on: April 18, 2006, 12:48:27 pm »
I don't think EA treats swimlanes as elements per se. Thus I do not think you can individually set the color properties.

There was something though in the latest build about extending the cases in which you could set a background color. Take a look at the release notes for build 789 and see if that might help. Of course, you would also have to ensure you were using the latest build in that case.
No, you can't have it!

nara_c

  • EA User
  • **
  • Posts: 45
  • Karma: +0/-0
    • View Profile
Re: How can I get the Swimlanes to have a fill col
« Reply #2 on: April 18, 2006, 03:20:17 pm »
It does not appear to be possible to set the background colour of the BPMN swimlane.  

However as an alternative, have you cosidered selecting the "Swimlanes..." option from the right click menu on a diagram or the "Configure Swimlanes..." option from the Diagram menu options.  Both options lead to the same "Diagram Swimlanes" screen.

While creating diagram swimlaes it is possible to set the background colour and orientation of the swimlane.

Note however that unlike Swimlane elements from the toolbar, diagrams swimlanes are specific to the diagram where they were created and hence cannot be moved to other diagrams (i.e.) no reusability.  That is the reason they do not appear in the project browser.

Another option is to create stereotypes using shapescripts and making the rectangle at the left end of the partition to appear filled with a colour.  A messy and cumbersome approach but a workaround to meet your need that creates reusable partitions.  

If you want to experiment with this approach here is the shapescript.
----------------
shape main

{

noshadow = true;


//Create Rectangle for colour

setfillcolor(0,150,0);

rectangle(0,0,5,100); // (x1,y1,x2,y2)


//Create lines for rest of Partition

startpath(); // Start to trace out a path

moveto(5,100);

lineto(100,100);

moveto(5,0);

lineto(100,0);

endpath(); //  End tracing out a path

fillandstrokepath(); // Fill the traced path with the fill color

}
----------------

I suggest you consider issues like need, maintenance downstream and overhead before you adopt any option.

Please post here if you find another alternative.

Cheers

sargasso

  • EA Practitioner
  • ***
  • Posts: 1406
  • Karma: +1/-2
  • 10 COMFROM 30; 20 HALT; 30 ONSUB(50,90,10)
    • View Profile
Re: How can I get the Swimlanes to have a fill col
« Reply #3 on: April 18, 2006, 04:04:12 pm »
or...

Either use boundary elements to fill your swimlanes.  These can be filled.

or...
use Partitions (from the Activity toolbox) instead of swimlanes. These can be filled and are more modern than swimlanes and have much more tricks up their sleeves.

hth
bruce
"It is not so expressed, but what of that?
'Twere good you do so much for charity."

Oh I forgot, we aren't doing him are we.

nara_c

  • EA User
  • **
  • Posts: 45
  • Karma: +0/-0
    • View Profile
Re: How can I get the Swimlanes to have a fill col
« Reply #4 on: April 18, 2006, 06:32:27 pm »
Quote
or...

or...
use Partitions (from the Activity toolbox) instead of swimlanes. These can be filled and are more modern than swimlanes and have much more tricks up their sleeves.


Bruce,  

how do you fill up the partitions from Activity toolbox?  I have tried it and was not able to change the fill colour.  Even after applying colours from element toolbox or changing the default colour it is not refreshing on the diagram.  Hence my work arounds.

Am I doing something totally wrong while trying to change colours or is there some other setting that needs to be modified to enable filling partitions with different colours.

KP

  • EA Administrator
  • EA Expert
  • *****
  • Posts: 2919
  • Karma: +54/-3
    • View Profile
Re: How can I get the Swimlanes to have a fill col
« Reply #5 on: April 18, 2006, 06:42:30 pm »
Quote
how do you fill up the partitions from Activity toolbox?


This was introduced with build 6.1.789. From the release notes:
Quote
Interaction Fragments, Activity Partitions, and Boundary elements may now have custom background colours
Just select and F4...
The Sparx Team
[email protected]

Roger A. Shepherd

  • EA User
  • **
  • Posts: 35
  • Karma: +0/-0
    • View Profile
Re: How can I get the Swimlanes to have a fill col
« Reply #6 on: April 19, 2006, 04:34:07 pm »
Just downloaded and installed Build 789. I had 788 which was my problem.
It works great. Just select the swim lane and press F4.....the rest is the typical pallete dialog that lets you select standard colors or create custom colors.
Thanks, KP for your help.
Dang, this BPMN model is looking pretty ;)
« Last Edit: April 19, 2006, 04:35:03 pm by ea1205 »

CaptainXsp

  • EA Novice
  • *
  • Posts: 1
  • Karma: +0/-0
  • I love Informagic Technology!
    • View Profile
Re: How can I get the Swimlanes to have a fill col
« Reply #7 on: April 20, 2006, 12:24:54 am »
To add a background color to a swimlane right click on the diagram window, select swimlanes form the popup menu, select the desired swimlane and chose modify, then you will see back color box: here you can change the color.

Bye Bye
Luca