Welcome to Telelogic Product Support
  Home Downloads Knowledgebase Case Tracking Licensing Help Telelogic Passport
Telelogic DOORS (steve huntington)
Decrease font size
Increase font size
Topic Title: DOORS 7.0 Takes Layout DXL coloring away!!!
Topic Summary:
Created On: 2-Dec-2003 21:26
Status: Post and Reply
Linear : Threading : Single : Branch
Search Topic Search Topic
Topic Tools Topic Tools
Quick Reply Quick Reply
Subscribe to this topic Subscribe to this topic
E-mail this topic to someone. E-mail this topic
Bookmark this topic Bookmark this topic
View similar topics View similar topics
View topic in raw text format. Print this topic.
 2-Dec-2003 21:26
User is offline View Users Profile Print this message


Douglas Zawacki

Posts: 97
Joined: 14-Aug-2003

I just posted an article on how to color your DXL Layout Columns. Well, I apologize that I neglected to say that was for Version 5.2. I foolishly assumed that DOORS 7.0 would not break that feature but it did.

Has anyone gotten the column coloring to work with DOORS 7.0?

This is so frustrating to try and get things working with a specific version only to move to a newer (Supposedly better) version and something so simple can be broken.

Tell me that's not a bug on DOORS part.
Report this to a Moderator Report this to a Moderator
 3-Dec-2003 06:07
User is offline View Users Profile Print this message


Paul Miller

Posts: 376
Joined: 2-Oct-2002

Hi Douglas,

As as example, the method that I use to apply a red colour to some DXL Layout text and then return the text back to a black colour is shown at the bottom of this posting (This works in DOORS v5, 6 and 7).

It's all based around the canvas "colour" function (you'll need to look it up in the DXL ref manual). This function requires you to identify a canvas scheme and which colour you would like to apply to text.

The colours are all predefined constants, the names of these constants and the colours that they will display are based on the display scheme that has been set under the Tools > Options > Display tab (These are known as logical colors). I'm not sure where they are listed in the DOORS7 DXL Ref manual, but if you can find the definition of the "colour" function (in the section covering canvas functions), this should provide a cross-ref to where the colour constant names are defined. As a postscript, I recommend to DOORS users that they leave the colour

\\Sample code
columnDisplay = getCanvas \\Get the current canvas text pallette that is defined under the Tools > Options > Display tab

color(columnDisplay, logicalDeletedTextColor) \\change the text colour to whatever has been assigned to "logicalDeletedTextColor"

display <your display text goes in here> \\display the text

color(columnDisplay, logicalReadOnlyTextColor) \\return the text colour back to black


-------------------------
Paul Miller
Specification Practices Specialist,
EuroCyber,
Melbourne, Australia.
Mobile: +61 (0)418 135 103
Web Site: http://www.eurocyber.biz
E-mail: miller@eurocyber.biz">pmiller@eurocyber.biz
Report this to a Moderator Report this to a Moderator
 4-Dec-2003 14:18
User is offline View Users Profile Print this message


Douglas Zawacki

Posts: 97
Joined: 14-Aug-2003

Paul,

Thanks for that tip. But the problem I'm having is that: I can change the background color of the canvas for any given row but it appears that calling displayRich seems to repaint the background color back to white.

The following code should demonstrate the problem:
When the text is displayed the background of that cell will revert back to white.

DBE theCanvas = getCanvas()
background(theCanvas, logicalLinkTextBackgroundColor)
color(theCanvas, logicalLinkDataTextColor)
displayRich "This text will now be on a white background"
Report this to a Moderator Report this to a Moderator
 8-Dec-2003 21:06
User is offline View Users Profile Print this message


Paul Miller

Posts: 376
Joined: 2-Oct-2002

Yep,

I tried your code and can now see the problem. There is some sort of interference between the recently introduced RTF functions, such as "displayRich", and the older colour control functions which have been around in DXL for a long time. The RTF standard has it's own methods for managing colour and I suspect that these are causing the interference to the background color at least.

Initially, I experienced all manner of weird problems when using the DXL RTF functions, the only way that I could get an understanding of why some RTF functions work and others fail was to have an understanding of the RTF standard which can be found if you click here.

-------------------------
Paul Miller
Specification Practices Specialist,
EuroCyber,
Melbourne, Australia.
Mobile: +61 (0)418 135 103
Web Site: http://www.eurocyber.biz
E-mail: miller@eurocyber.biz">pmiller@eurocyber.biz
Report this to a Moderator Report this to a Moderator
 9-Dec-2003 09:48
User is offline View Users Profile Print this message


Paul Tiplady

Posts: 176
Joined: 28-Oct-2003

Sadly DXL does not support all the RTF standard by any means. One of the things it ignores is colours. You can set up a colour table in the RTF snippet you want to put in the layout DXL, and you can reference the colours using \cf and \cb, but DXL ignores the references. The foreground colour still changes with the 'old' colour commands, but the background seems fixed white. Maybe Telelogic will expand their RTF parser to cover all the options in some later release...

-------------------------


Paul dot Tiplady at TRW dot com
TRW Automotive
Report this to a Moderator Report this to a Moderator
 9-Dec-2003 14:40
User is offline View Users Profile Print this message


Douglas Zawacki

Posts: 97
Joined: 14-Aug-2003

The problem is that it displayRich appears to work properly in DOORS 5.2 and does not work the same way in DOORs 7.0 SR1. This is very frustating when a feature works in an older version and does not in the newer version.
Report this to a Moderator Report this to a Moderator
 2-Sep-2004 12:48
User is offline View Users Profile Print this message


Dave Robbins

Posts: 36
Joined: 9-Dec-2003

Have you tried using displayRichWithColor in place of displayRich ?

-------------------------
Dave
+44 (0)23 9270 5711
david.robbins@astrium.eads.net
~~~~~~~~~~~~~~~~~~~~
EADS Astrium, Anchorage Road
Portsmouth. Hampshire. UK PO3 5PU
Report this to a Moderator Report this to a Moderator
Statistics
20925 users are registered to the Telelogic DOORS forum.
There are currently 1 users logged in.
The most users ever online was 15 on 15-Jan-2009 at 16:36.
There are currently 0 guests browsing this forum, which makes a total of 1 users using this forum.
You have posted 0 messages to this forum. 0 overall.

FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.