After loading configuration file, open selected tab - java

I have a question in regards to a Java GUI I'm creating at the moment, it's an application that runs offsite backups.
When the application initially loads you are presented with this screen:
After loading the configuration file it fills out each field in the tabs below; at this stage it is staying on the "Run" tab after I load the configuration file, but I'd like it (after filling out each field) to bring the "Configuration" tab to the screen.
How do I go about doing this? In the method I've written to load config after the JFileChooser window is closed, I'd imagine I'll need to add something to tell it to select the Configuration tab.
I can provide the classes if necessary.

Exposing the component, then using the method:
CTabFolder#setSelection(int);
worked fine.
Thanks #MadProgrammer and #Vulcan

Related

Many attributes are missing in attributes in design in Intellij Idea for android app develop

I use the design part to design the android application in Intellij Idea, but I cannot design because many features such as "textColor", "textSize", "backgroundColor" are missing in the attributes part. When I try to write to the XML file manually, the automatic code completion does not work and does not recognize the functions.
I did a lot of research but couldn't find anything on this topic. I would be glad if you help.
I tried creating new project, invalidating the cache but it didn't work.
attributes-----
I'm looking for the attributes but nothing comes up------
I'm trying the XML file
-----------------update-------------
When I add a property to the XML file, it starts to appear in the attributes panel, but if I do not add it, it does not appear in the panel.
I couldn't understand why.
For example, when I add these properties to the textView, the properties appear on the panel, but when I add a new textView in the same project, the properties are not visible on the panel again.
How can I make these properties available in the attributes panel by default in the project?
In picture 1, the property does not appear in the attributes panel. When I add it manually to the XML file in Picture 2, it starts to appear on the panel.
picture 1
picture 2

Change android application adaptive drawable?

Is it possible to change an application icon directly from the program?
I mean, change icon.png in the res\drawable folder.
I would like to let users to change application's icon from the program so next time they would see the previously selected icon in the launcher.
Assuming you mean changing the icon shown on the home screen, this could easily be done by creating a widget that does exactly this. Here's an article that demonstrate how that can be accomplished for a "new messages" type application similar to iPhone:
http://www.cnet.com/8301-19736_1-10278814-251.html

How to write dynamic about menu in eclipse

I need to add dynamic content inside about menu in eclipse application.
Any idea about the About menu plugin??
In the Branding tab inside product file i am adding static content in the About dialog. Now i need to add some dynamic content that will be decided in the run time of the application.
Is there any method to override to get the dynamic content inside the About menu???
Please can anyone help me.
The about dialog org.eclipse.ui.internal.dialogs.AboutDialog does not support any dynamic context.
The main text comes from the aboutText property defined in the org.eclipse.core.runtime.products product definition.
The images come from the installed bundle groups.
The data on the branding / feature dialog just comes from the feature and branding plugin and is also not dynamic.

Changing Splash Screen Dynamically

I have an application (Java, Windows) that when opened, shows a splash screen (Good, right?). I want to know how I could change it each time the application loads (or set it to load from a location outside the app cuz I could change that). I'm using netbeans if that helps. Also, this application gets installed to their program files directory. Ideally, I would like to be able to load from %AppData%. I can't seem to figure out this part though! Thanks!
UPDATE*
Here is my folder structure and some more info!

Eclipse RCP: Why is the view missing when running as a Product?

I'm brushing up my Eclipse RCP skill by trying to enhance my one-year-old side RCP application. This application has one perspective, and this perspective has 3 views, and I'm adding another view into the same perspective. To add this new view, I added it in the MANIFEST.MF file under Extensions tab and created the Java file for it.
When I run it as an Application, it works. I see all 4 views in the application. But, when I run it as a Product, that new view is missing. It almost seems like the new view is not registered in the Product. There's no error in the console log either. I think I must be missing a step here, but I can't seem figure out here... pretty frustrating!
Note: The views are added into the perspective programmatically (in Java code), not through MANIFEST.MF file. I just realized that even when I change the existing view's layout (ex: size, or location), it doesn't get reflected when running as a Product either, but it works when running as an Application... sigh!
Note: I commented out all the code in my perspective class, in another word, all the views are removed from the perspective. When I launch the Product, I'm still seeing 3 views in the application. I'm thinking there's something to do with caching, but I'm just bummed now.
Any helps are greatly appreciated here! Thanks much,
Okay, after aimlessly clicking around, I figured out the solution. The workspace data needs to be cleared to pick up changes from the perspective.
To do so...
Right click the product file
Choose "Run Configurations..."
Under "Main" tab, check "Clear" checkbox and "workspace" radio button.
Run it.
Hope this will save some of you from troubles.
I've been bitten by this a couple of times until I figured out the easiest workaround: it's sufficient to reset the perspective. There are two ways to achieve this:
Right-click on your perspective in the perspective selector bar at the top right and click on Reset.
Switch to your perspective and then go to Window | Reset perspective....
After that, the changes to your perspective should be picked up.

Categories

Resources