Solved

How to create a non-resizable JDialog with icon

Posted on 2001-07-13
4
767 Views
Last Modified: 2007-12-19
Hi all,
       The login screen of an application need to have a icon on the dialog's top left(left to the title). I am using JDialog for the login screen. If this JDialog is resizeble the dialoge automatically take the icon from its parennt window. But when it become non re-sizable this icon disappears. Can anybody suggest is there any way to display icon on the top left of a non resizable JDialoge?

Thanks in  advance.
Shimit
0
Comment
Question by:a-1220
4 Comments
 
LVL 3

Expert Comment

by:stimpyjcat
ID: 6281535
What platform/window manager?

The only control you get over the JDialog icon is with the setIcon method.  This is probably preferable to relying on the parent component icon if you want a specific icon for your dialog.

Whether the dialog is resizable is irrelevant to Java when setting the frame's icon.  It is entirely possible, however, that your platform's window manager does things differently if the native window is not resizable; if that's the case, you'd have to reconfigure your window manager.

I have a non-resizable dialog for which the icon appears just fine under win32 (I've used setIcon).  The default window manager on RedHat 6.2 GNU/Linux, however, shows no icon for *any* window (the icon only shows up when the window is iconified).
0
 
LVL 1

Expert Comment

by:boazbl1
ID: 6283133
if you are using windows 2000 / NT 4 u cant use nonresiseable JDialog with icon
0
 
LVL 5

Expert Comment

by:vemul
ID: 7669835
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
- To be PAQ'ed and points NOT refunded
Please leave any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER !

vemul
Cleanup Volunteer
0
 

Accepted Solution

by:
modulo earned 0 total points
ID: 7729129
Finalized as proposed

modulo

Community Support Moderator
Experts Exchange
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For customizing the look of your lightweight component and making it look lucid like it was made of glass. Or: how to make your component more Apple-ish ;) This tip assumes your component to be of rectangular shape and completely opaque. (COD…
Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
This theoretical tutorial explains exceptions, reasons for exceptions, different categories of exception and exception hierarchy.

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question