SPONSORS:






User Tag List

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)

    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
    rg
    rg is offline
    Member
    Join Date
    Feb 2000
    Posts
    98
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    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
  •  

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 04:18 AM.

Copyright BetaSoft Inc.