Solved

What is a "custom" swing component?

Posted on 2011-09-13
4
303 Views
Last Modified: 2012-05-12
I am reading javadocs of an API (see attached).
One line says:
Implement this class if you are using custom Swing or AWT components, ...

What exactly is meant by "custom"?
If I have a class that extends say, JCheckbox, is that a custom component?
package-summary.html
0
Comment
Question by:allelopath
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 7

Expert Comment

by:dimaj
ID: 36530281
If I were to take a guess, I'd say that it's a custom component that was implemented with the help of swing libraries.

I could be wrong though.
0
 
LVL 47

Assisted Solution

by:for_yan
for_yan earned 100 total points
ID: 36530811
My guess is that custom Swing or AWT component is the class which you wrote yourself but which extends Swing or AWT compohnent

Say you wrote

 class MyPanel extends JPanel {
..

}

so MyPanel is your custom swing coponent
0
 
LVL 41

Accepted Solution

by:
HonorGod earned 400 total points
ID: 36530812
From "How to Support Assistive Technologies"

http://download.oracle.com/javase/tutorial/uiswing/misc/access.html
----------------------------------------------------------------------
If you create a custom component, make sure it supports accessibility. In particular, be aware that subclasses of JComponent are not automatically accessible. Custom components that are descendants of other Swing components should override inherited accessibility information as necessary. For more information, see Concepts: How Accessibility Works and Making Custom Components Accessible.
----------------------------------------------------------------------

From this we can infer the answer to your question

Q: If I have a class that extends say, JCheckbox, is that a custom component?
A: Yes

0
 
LVL 41

Expert Comment

by:HonorGod
ID: 36532507
Thanks for the grade & points.

Good luck & have a great day
0

Featured Post

The Ultimate Checklist to Optimize Your Website

Websites are getting bigger and complicated by the day. Video, images, custom fonts are all great for showcasing your product/service. But the price to pay in terms of reduced page load times and ultimately, decreased sales, can lead to some difficult decisions about what to cut.

Question has a verified solution.

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

INTRODUCTION Working with files is a moderately common task in Java.  For most projects hard coding the file names, using parameters in configuration files, or using command-line arguments is sufficient.   However, when your application has vi…
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 will learn about arithmetic and Boolean expressions in Java and the logical operators used to create Boolean expressions. We will cover the symbols used for arithmetic expressions and define each logical operator and how to use them in Boole…
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:

690 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