Simple collection of the months component (without corresponding calendar?)
I feel that it can be ridiculously easy to answer...I am looking for a component of the months picking it is simply an extension of something that already exists.
My first instinct was to look at the JXMonthView that is included inside SwingX. Basically, my ideal component would be one that includes only the month part up to the selection page of the JXMonthView component with "traversable' set to true. In other words, a control that allows you to choose a month in the year using a schema of forward/reverse. Unfortunately, I can't find a good way to replace the functionality of the class such that only the top header is included.
I tried to get into the guts of the code, but it was like the best thing to do was to replace the layoutContainer inside BasicMonthViewUI function. Then I realized that this feature is part of a private class. I missed a great way to hide just that little of the Panel? I also considered replacing the functions of the painting, but my fear is that the component request too much space because it's just not 'paint' the month but still allocates space for this.
I think that, perhaps, a self-made simple control may be the best solution? I'm just trying to stay away from possible much custom work I hope to make the control as portable as possible between platforms.
Thank you!
aardvarkk wrote:
I'm looking for what you might call a "horizontal spinner" or scroll bar, in which you have a front and back button on each side of months he throws back a month and back. Also it should technically go back into previous years and to enter in the new.
Here is something of a JSlider in months and JButtons in the years. Because I'm not that familiar with Date/calendar, there is probably a better way to extract the necessary information (exercise for the OP), but this comes from the Swing stuff demos:
import java.awt.*;
import java.awt.event.*;
import java.text.*;
import java.util.*;
import javax.swing.*;
import javax.swing.event.*;
public class MonthScroller extends JPanel
{
String[] months;
JSlider slider;
JButton btnPrevious, btnNext;
JLabel displayMonth, displayYear;
int month, year;
public MonthScroller()
{
months = Arrays.copyOf(
DateFormatSymbols.getInstance().getShortMonths(), 12);
month = Calendar.getInstance().get(Calendar.MONTH);
year = Calendar.getInstance().get(Calendar.YEAR);
displayMonth = new JLabel(months[month]);
displayYear = new JLabel(String.valueOf(year));
slider = new JSlider(0, 11, month);
slider.setMinorTickSpacing(1);
slider.setPaintTicks(true);
slider.setPaintLabels(true);
slider.addChangeListener(new ChangeListener(){
public void stateChanged(ChangeEvent e)
{
month = slider.getValue();
displayMonth.setText(months[month]);
}
});
btnPrevious = new JButton("<");
btnPrevious.addActionListener(new YearIncrementer(-1));
btnNext = new JButton(">");
btnNext.addActionListener(new YearIncrementer(1));
add(btnPrevious);
add(slider);
add(btnNext);
add(displayMonth);
add(displayYear);
}
private static void createAndShowUI()
{
JFrame frame = new JFrame("Month Scroller");
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.add(new MonthScroller());
frame.pack();
frame.setLocationRelativeTo( null );
frame.setVisible( true );
}
public static void main(String[] args)
{
EventQueue.invokeLater(new Runnable()
{
public void run()
{
createAndShowUI();
}
});
}
class YearIncrementer implements ActionListener
{
int increment;
YearIncrementer(int increment)
{
this.increment = increment;
}
public void actionPerformed(ActionEvent e)
{
year += increment;
displayYear.setText(String.valueOf(year));
}
}
}
Tags: Java
Similar Questions
-
Hi, I have a question, I m interested in buying cc for oligo, but I didn't how will look at payment collected monthly from my account. I m from Poland, is if there is any conversion related to the collection to the monthly fee? Is beyond the $ 19.99 euros will be ordered to pay the money transfer from zlotys to the euro.
Hello
In order to know the payment process, you can contact Adobe support:
https://helpx.Adobe.com/contact.html?step=CCSN
To know the offers and different plans, you can visit the Adobe Web site:
Pricing plans and creative Cloud membership | Adobe Creative Cloud
Let us know if you need more information.
-
cancel the monthly association without renewal
THE MONTH LAST, I BOUGHT A MONTH MEMBERSHIP. MY INTENTION WAS ONLY A MONTH.
I JUST GOT A MESSAGE FROM MY CREDIT CARD MONTHLY U $ 24.99 A NEW WAS MADE TODAY, JULY 4
I HAVE NO INTENTION OF RENEWAL WITHOUT ASKING ME FIRST. I REQUEST THE CANCELLATION AND REFUND OF THE INVOICED AMOUNT IMMEDIATE
Unfortunately, these are public forums, supported mainly by users, no contact with Adobe customer service. You must contact customer support directly to resolve account problems. They do not normally support the weekend.
How to cancel a subscription cloud creative
To the link below, click on the still need help? option in the blue box below and choose the option to chat or by phone...
-
How to use the declarative component without deployed as JAR
Hi all
I want to create a reusable component (declarative component) for PanelHeader with default features packed in I want to use in my application. Because this component will be used only in my project, I don't see a use to go through the process of creating a jar and deploying it before using it. Is it possible to use this component without creating a JAR.
Thank you
-Srini.User 895137,
your welcome to ignore the best practices in the development of the ADF. The declarative elements are deployed in the libraries of the ADF. If you keep the declarative component in the application then project you will have a chance to deploy independent of the application (which means that your ADF library contain more than just the source of the component (which is where your nightmare begins)). Therefore, best practices
1. create the declarative component in a new project in JDeveloper. Follow
http://download.Oracle.com/docs/CD/E21764_01/Web.1111/b31973/af_reuse.htm#BABJBFDD
2. If you don't ant to deploy components in a tag library, use declarative dynamic components (will not deploy-able in many applications, as you mentioned your future plan is), as shown here
http://download.Oracle.com/docs/CD/E21764_01/apirefs.1111/e12419/tagdoc/af_declarativeComponent.html
http://download.Oracle.com/docs/CD/E21764_01/apirefs.1111/e12419/tagdoc/af_componentDef.html
http://download.Oracle.com/docs/CD/E21764_01/apirefs.1111/e12419/tagdoc/af_xmlContent.htmlFrank
-
install master collection on the second laptop without cd player
Hello experts,
How can I install the master collection that I bought on the second laptop, which doesn't have a cd player?
I do not download the product, but I have CD fpr licensed teacher.
Your help is very appreciated!
Best, Christiane
Download & install instructions https://forums.adobe.com/thread/2003339 can help
-includes a way to go to a page to download the Adobe programs if you do not have a disk or drive
-you will need to enter your original serial number during the installation for non-Cloud programs
-Cloud desktop http://helpx.adobe.com/creative-cloud/help/creative-cloud-desktop.html
-Cloud Getting Started https://helpx.adobe.com/creative-cloud.html
-Membership questions and problems https://forums.adobe.com/thread/1146459
- or kglad links in response to #1 here can help https://forums.adobe.com/thread/2081216
-for Lightroom https://helpx.adobe.com/lightroom/kb/lightroom-downloads.html
Also go to https://forums.adobe.com/community/creative_cloud/creative_cloud_faq
-
Add custom property to the MXML component without extension
Hello
I want to add a custom property to a bunch of ignition buttons.
A bit like the HTML5 data-* feature.
Is this possible without extending the Spark Button class?
I tried to use the id and the setting is a const static of a class AS public, but it does not compile the names of the time ID in MXML. (for example < s:Button id = {SomeClass.aStaticConst} / >)
I could create buttons in AS3 and it be allowed to set identifiers as described above, the way in which its configuration is to allow other people to add new items in MXML for ease of use so I prefer to keep it so.
Thank you.
Hi, crush,
You cannot bind the property id to a constant, but I think that you can bind to the name property:
Dany
-
How to view the monthly/annual statistics in terms of time past/calories burned, broken down by each individual activity such as run elliptical/outside etc. Y at - it a third party application that can help me to collect and display these data?
Hello
It is not currently possible to review the data the application integrated in activity or training on this basis. If you want Apple to consider adding this feature, you can suggest here:
https://www.Apple.com/feedback/watch.html
However, health and fitness data from other sources, iPhone, and Apple Watch are registered and grouped within the health on iPhone app. These data can be exported, which you may find useful to track the cumulative progress and/or analyze your activity more in detail.
IPhone app activity also has a button for sharing (top right of the screen) that allows to share data - including social media, Messages, Mail, Notes, and a printer.
Include third-party applications that can be useful, for example:
Access to QS
-"Access your HealthKit data in a table so you can Explorer using numbers, Excel, R, or any other tool compatible CSV."
- https://itunes.apple.com/gb/app/qs-access/id920297614?mt=8
SpectaRun workouts
-"View from the workouts of your Apple Watch on your iPhone and to export these workouts so you can download them to your favorite online running community."
- https://itunes.apple.com/gb/app/spectarun-workouts/id991723862?mt=8
Data can also be exported directly from the application of the health (Health Data > All - Share at the top button on the right).
Check the descriptions and support resources for third party applications for supported details of import and data analysis features.
More information:
Use the activity on your Apple Watch - Apple Support
-
Win2012 Server. Y at - it a shortcut to reach the Collections to the remote desktop Services without going through the Server Manager?
Hello
Post your question in the TechNet Server Forums, as your question kindly is beyond the scope of these Forums.
http://social.technet.Microsoft.com/forums/WindowsServer/en-us/home?category=WindowsServer
See you soon.
-
I have paid the monthly fee and have been using Acrobat Pro DC. I had a problem where I broke my previous laptop and want to continue to use this product. I bought another laptop, and I don't know how to download the program without having to pay again. I pay $14,99 per month for this service, how can I download it without having to pay again?
Hello
Please download Acrobat Pro ms of the here. After you download the application, install and activate it by providing your Adobe ID
Thank you
Abhishek
-
Is there a way to buy dreamweaver CS6 right, I mean without the monthly subscription?
Is there a way to buy dreamweaver CS6 right, I mean without the monthly subscription?
Please check: Creative Suite 6
We ask that allows you to check the system requirements for | Dreamweaver as well.
-
Hello
I work with Adobe InDesign CC 2015 on Windows 7.
I'm developing a digital magazine for iPad and Android tablets.
I do not have a developer account Apple or Google.
Until the accounts are created, is it possible to preview the items or collections on a real Tablet without signing the application?
Thank you
OK, I totally missed that you said article and the collection in the title. Laughing out loud. Oops
For iOS, you must have a developer account, you can create the mobileprovision file and certificates to sign and install the preview application. You don't need to have a certificate to sign for Android, but you don't need a developer account to do. You can generate a certificate using the keytool app utility that comes with Java, sign your insight to a .apk file and install it on your Android device.
Neil
-
I plan to buy Dreamweaver, but I'm confused how monthly plan without clouding, pls tell me the details, how can I buy it. ?
The monthly plan is associated with creative cloud, you can buy only Dreamweaver CC app, for this you need to download the application of CC desktop & then install it, you can also install the version of CS6 of Dreamweaver from here.
You can also buy the perpetual version of Dreamweaver CS6. The limitation is that the perpetual version will have all future updated. High graduation will be only through CC.
Concerning
Baudier
-
Calendar events hotmail disappeared days corresponding to the monthly calendar
My hotmail calendar displays more events that I posted in my monthly calendar display. They appear at the far left of the first day of each week in the monthly calendar. They appear correctly in all other views of the calendar. This just happened recently. What can I do about it?
Hello
I'm sorry, but we cannot help with hotmail problems in these forums in response to vista
Please repost your question in hotmail in the hotmail link below forums
http://windowslivehelp.com/product.aspx?ProductID=1
ForumsConsult with Microsoft Certified Solutions____________________________________________Welcome to Windows Live Solution Center -
Increase of the monthly, without receiving notification!
Hello. I have an individual CC academic subscription. It automatically renewed last October (2014), however the monthly rate increased from €19.99 h €30,74 h
I was not informed beforehand about this increase, according to my contract, which States that:
"the price is valid for 12 full months. After that, we will renew your contract automatically unless you cancel. The price is subject to change, but we will always notify you in advance. »
It is very dishonest of Adobe and breaks by also the terms of my contract. Does anyone else have this problem?
Thanks in advance.
A.
There is nothing dishonest. Do you have a discount for the first year and now pay the regular full price. This isn't a rise in prices, your discount simply missed.
Mylenium
-
Images not showing in moments, the collections or the years
MacBook Pro 2.66 GHz
Mac OS 10.10.5
Pictures 1.0.1
Images import from Apple Mail to all photo album, but not displayed in Moments, Collections or years. When I right-click (Ctrl-click) on the image in the photo album and select Show in the Moment, nothing happens. How can I get the images imported into Moments?
In the library of Photos of the masters record shows the lower level folders by date (ex 16 June 2015) and the images contained in these files. Upgrade to Mac OS 10.10.5 records being titled 06, 08, 12 etc. for the month and every month folder contains lower level folders for the day of the month. The images are stored in the day of the month records. Different method to organize the main images would be the source of the problem?
Which indicates a database corrupted - back up your library of Photos and then launch Photos while you hold down the option and command keys - repair the database
And I strongly suggest that you stay out of the photo library - it is there no user repairable in and a simple, small error on your part it can damage
LN
Maybe you are looking for
-
Just bought my first toshiba laptop... There is a sticker that onenote is installed on it.But despite all my efforts, it will not start. I need a key code but I have no one. Someone knows what to do and how to get onenote? Thank you!
-
Satellite L750D - update in Win 7 32 bit for win 10 64 bit
The installation was successful? Well win 10 came and I changed a few things in the start when the laptop computer just restarted. Windows 10 tried to solve the problem and said that it was impossible.I tried various recovery options that are offered
-
I have some trouble transfer my image file on a DVD + R?
I use one: computer Hp Pavilion DV5237CL. My operating system is: Windows XP Media Center Edition, SP3. I r: Matshita DVD - RAM UJ-years 840 catagoried under CD-ROM/DVD-ROM drives. I have also studied this desire to discover that he is able to write
-
I am wanting to print Grayscale / black only, still does not allow me to print because I have empty color cartridges. How can I get around this? I tried changing the settings Thank you very much
-
After opening an e-mail message and tab and then on the button 'send '. set the contents of the email go 'Send' but is there... In other words it does not 'Outbox' move in my "Sent items" folder However, the message transmits to recipients. What can