SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 2 of 2
  1. #1
    Senior Member
    Join Date
    Nov 2001
    Location
    UK, Oxford
    Posts
    150
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    CellRenderers and toString()

    I am evaluating ST on a java swing app.
    We have many ListViews which use our own custom built cell renderers.
    I was having a problem selecting from a list:
    blah.blah.Select("type3")
    would not select.
    I then discovered that ST uses the toString method of whatever object was placed in the list, and so I wrote a script to modify all
    our toString methods when in TESTING mode, so that they did not spurt out all the usual
    object information, but instead called our own 'display' methods.
    This worked fine. For most cases.
    However, there are situations where a cell renderer will concatenate a whole load of info together, from different objects, and
    consequently I cannot simply alter a toString method in any one class.
    The question:
    can I get ST to select upon what is displayed
    to screen, not on what the toString method of the object in the list returns...?

    ------------------
    Tempus fugit, Carpe Diem, et al

  2. #2
    Member
    Join Date
    Feb 2000
    Posts
    98
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: CellRenderers and toString()

    You may want to look into using InvokeMethods or InvokeJava to call your Java code directly to handle this situation. Examples are in the online help.

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Search Engine Optimisation provided by DragonByte SEO v2.0.40 (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 11.54%
vBulletin Optimisation provided by vB Optimise v2.7.1 (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.3.0 (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
vBNominate (Lite) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 08:10 PM.

Copyright BetaSoft Inc.