AbtHtmlTableColumn: change colour of heading? 
Author Message
 AbtHtmlTableColumn: change colour of heading?

We found the table widget very restrictive so we wrote our own table
code that makes the html the way we want it and the put that into a
simple text holder. That way we leave the data as is and extend the
html at will.



Quote:
>Thanks, Rav,

>I've done that one before, but you are modifying the data model with HTML
>code.  We use the same data model in both the web client and desktop client,
>therefore, HTML changes would mess up the desktop.  I used my changes on
>three projects so far and it keeps me from writing inline HTML.

>Good luck!
>-rich


>> Rich Snarski and a colleague of mine came up with 2 different solutions.
>> For a simple change, there is quite a bit of work involved (see
>> correspondance below).

>> Thanks Rich.  It is ironic that such a simple change to the UI would
>involve
>> so much work.  I spoke with a collegue and he explained to me that he had
>> different problems with the HTML table.  He also came up with a solution
>as
>> well.

>> He said:

>> 1.  Do not set the heading property for the column part
>> 2.  Set the column part's literal property to true.
>> 3.  Before passing the oc to the table, "addFirst:" the heading
>information
>> with HTML tagging.

>> Example:

>>  [string := string, '<a href="#">[Descriptions]</a>'].
>>  oc addFirst: (Cust new
>>     cust3: 'Cust Divn';
>>     custAddress1: 'Division Name';
>>     custAddress4: string).

>>  (self subpartNamed: 'table') items: oc.

>> later,

>> r



>> > It's pretty hard to do!

>> > 1.)  Subclass AbtHtmlTable and AbtHtmlTableColumn.
>> > 2.)  In AbtHtmlTableColumn add an instance variable
>> headingExtraAttributes.
>> > 3.)  Change AbtHtmlTable>>abtGenerateHtmlWithin: to use the
>> > headingExtraAttributes.  Add:

>> >     column headingExtraAttributes isNil
>> >         ifFalse: [ cell extraAttributes: column
>headingExtraAttributes ].

>> > 4.)  Do the same for the column:

>> >     column extraAttributes isNil
>> >      ifFalse: [ cell extraAttributes: column extraAttributes ].

>> > HTH's
>> > -rich



>> > > I am working in VAST 5.5 with the Web Connection feature, and I was
>> > > wondering if anyone knew how to change the default black colour for
>the
>> > > heading to a different colour.

>> > > I have tried changing the Properties of the part, but there is nothing
>> for
>> > > the colour of the heading.  I also tried setting the literal property
>to
>> > > true in Properties and tried to enter HTML tagging in the heading
>field,
>> > but
>> > > that did not work.

>> > > Also, I tried creating a visual connection b/w the column part and an
>> > > abtHtmlText part that had the blue font I desired.  This resulted in
>the
>> > > column heading getting the correct string, but not picking up the
>> colour.

>> > > Any ideas welcome,

>> > > Thanks,

>> > > r



>> > I am working in VAST 5.5 with the Web Connection feature, and I was
>> > wondering if anyone knew how to change the default black colour for the
>> > heading to a different colour.

>> > I have tried changing the Properties of the part, but there is nothing
>for
>> > the colour of the heading.  I also tried setting the literal property to
>> > true in Properties and tried to enter HTML tagging in the heading field,
>> but
>> > that did not work.

>> > Also, I tried creating a visual connection b/w the column part and an
>> > abtHtmlText part that had the blue font I desired.  This resulted in the
>> > column heading getting the correct string, but not picking up the
>colour.

>> > Any ideas welcome,

>> > Thanks,

>> > r

GO Smalltalk


http://www.*-*-*.com/ - THE Smalltalk resource

Totally Objects is an IBM Object Connection member



Mon, 26 Apr 2004 05:24:37 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. VW2 Changing Background Colour

2. Changing colour of fields on reports.

3. How to Change Title Bar colour?

4. Scrollbar Color or Colour Change in Clarion

5. Changing heading on a Report FORM

6. Heads up on changes at taygeta

7. get indicator to change colour

8. Changing TextGadgets colour

9. changing background colour of an rc_graphic window

10. Colour Change

11. changing colour

12. NEWBIE: changing the colour of points

 

 
Powered by phpBB® Forum Software