Tina Viessmann

Greenhorn
+ Follow
since Jun 01, 2011
Merit badge: grant badges
For More
Germany
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Tina Viessmann

Hi,

thank you for your answer. I'm kind of irritated. If a JPanel is not focusable by default, why does WHEN_FOCUSED work?

Thank you
12 years ago
Hi,

I've got an application consisting of a JPanel containing an image and some focusable controls. Initially the focusable controls are disabled so that the panel has the focus. I want the image to be zoomed in / out if a specific button is typed. The shortcuts shall be executed independent of the control that has the focus. I'm doing that using the JPanels InputMap and ActionMap.

The javadoc states for JComponent.WHEN_ANCESTOR_OF_FOCUSED_COMPONENT:

Constant used for registerKeyboardAction that means that the command should be invoked when the receiving component is an ancestor of the focused component or is itself the focused component.



Because of that my first attempt was the following:

Contrary to the javadoc, the related actions have not been executed if the panel itself has been focused.

To get my application to work as imagined, I need to do the following:

Can anyone explain to me why my first attempt is not working as I thought it would do, please?

Thank you
Tina
12 years ago
@Rob
Thank you for your effort! I've read your other thread and it describes my problem very well. Let's see what solution results from this.

@Michael
Unfortunately folder navigation is needed. Otherwise I would have put it into a list. Thank you anyway.
12 years ago
Hi Rob, thank you for your solution. Unfortunately its not exactly what I'm looking for. I want to remove the 'New Folder' option from the menue and disable the rename functionality for files/folders. (when you double click the file/folder slowly, you can rename it.)
That's what setting the client property should do.

Thank you anyway.

~Tina
12 years ago
Hi,

I've tried to disable the create new folder and rename for a JFileChooser. I know I can use the client property FileChooser.readOnly. I've experiencing some difficulties using that.
Because I only wanted to change the property for one specific file chooser, i've tried:Unfortunately that does not work. But this way i've alread used successfully :
I know I can useBut I don't want to fool arround with the UIManager.

Does anyone have any ideas?

Thank you!
12 years ago
Hi,

I need to display a pixmap stored in the memory by an x-server. My application only knows the memory address to start at.
While searching, I found the JIMI SDK. Right now I'm not sure if that can do what I want.

So, how can that be done (using JIMI or something else)?
Ideally some example-code would be helpfull.

Thanks

~Tina
13 years ago
My fault, I should have said that right from the start: I'm not logging anything.
I'm producing kind of a html page. I need to write my output on the standard output stream, because it's a requirement of the system my program runs on.
13 years ago
Hi,

I need to write a very large block of text on system.out. I would prefere to do that in the most performant way. How is that done?

The text is generated step by step while processing different information. Therefore I can think of three ways to handle the output:
- Write out every part of the when immediately when it's created.
- Buffer the whole text (using a StringBuffer) and write it out as whole when the processing has finished.
- Use a mix of both approaches: Buffer a larger amount (the result of several processing steps) of text, write it out, go on buffering, write again and so on.

What's the best approach? How else can it be done?

Thanks in advance!
Tina
13 years ago