Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / April 2007

Tip: Looking for answers? Try searching our database.

AWT Cursor in vista problem

Thread view: 
yaron - 01 Apr 2007 10:00 GMT
Hi,
i have an applet with a black background.
when i set the Cursor to Cursor.TEXT_CURSOR in Vista the cursor is
displayed also in black, and it is not seen.
any idea???
Andrew Thompson - 01 Apr 2007 12:39 GMT
..
>i have an applet with a black background.

Do you have a 'shift key'?  Please apply it once at
the start of each sentence, and anytime you use the
word 'I'.  Correct capitalisation helps readers to scan
text, looking for the important parts of a post.

>when i set the Cursor to Cursor.TEXT_CURSOR in Vista the cursor is
>displayed also in black, and it is not seen.
>any idea???

Also please fix that sticky '?' key - one is enough.

But to your question.

I think it is silly to have an applet with a black background,
yet expect that the default Cursor.TEXT_CURSOR would be
of a color that is compatible with it.  

There are two strategies (I can think of) that might
work here..
1) Leave all colors and cursors as the default, and trust
the underlying PLAF to ensure that there is enough contrast
to make the cursor visible.

I am guessing that strategy is not suitable for an applet
where you specifically set the background black, which
leads me to..
2) When you change or overried, any single color, make
sure you specifically set not only every other color (borders,
text color etc.), but also define custom cursors.  Defining
a custom cursor can be done by calling..
<http://java.sun.com/javase/6/docs/api/java/awt/Toolkit.html#createCustomCursor(j
ava.awt.Image,%20java.awt.Point,%20java.lang.String

)>

HTH

Signature

Andrew Thompson
http://www.athompson.info/andrew/



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.