|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object cello.tablet.JTablet
public class JTablet
The entrance JTablet class. Tablet information is stateless, but this class allows it to function as a class entity.
To construct a JTablet object, you must catch JTabletException
.
try { JTablet jtablet = new JTablet(); } catch (JTabletException jte) { System.err.println("Could not load JTablet! (" + jte.toString() + ")."); } `
JTabletCursor
,
JTabletException
Field Summary | |
---|---|
protected JTabletCursor |
currentCursor
|
protected boolean |
pollModeLatest
|
Constructor Summary | |
---|---|
JTablet()
Creates a new JTablet object without full control. |
|
JTablet(boolean fullControl)
Creates a new JTablet object. |
Method Summary | |
---|---|
void |
close()
Unloads the native driver for JTablet |
void |
finalize()
Unloads the native driver for JTablet |
int |
getAngle()
Deprecated. |
int |
getButtons()
Deprecated. |
JTabletCursor |
getCursor()
Returns the last JTabletCursor that was polled from |
static java.lang.String |
getLibraryVersion()
Retrieves the current JTablet version of the loaded library. |
int |
getOrientation()
Deprecated. |
int |
getPressure()
Retrieves the current pressure of the tablet as an int. |
int |
getPressureExtent()
Retrieves the maximum possible pressure of getPressure() . |
java.lang.String |
getVersion()
Retrieves the current JTablet version. |
int |
getX()
Deprecated. |
int |
getY()
Deprecated. |
int |
getZ()
Deprecated. |
boolean |
hasCursor()
Checks if JTablet has a cursor. |
boolean |
isPollModeLatest()
Returns if Poll mode is retrieving the latest information. |
boolean |
poll()
Polls the tablet for the latest tablet information. |
void |
setPollModeLatest(boolean b)
If this option is enabled (by default), whenever JTablet.poll() is called the latest information will be retrieved, rather than the next available information. |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected JTabletCursor currentCursor
protected boolean pollModeLatest
Constructor Detail |
---|
public JTablet() throws JTabletException
JTabletException
- if the native library could not be loaded or no tablet is available.JTablet(boolean)
public JTablet(boolean fullControl) throws JTabletException
fullControl
- Tries to access the tablet with full control for digitizing purposes.
JTabletException
- if the native library could not be loaded or no tablet is availableMethod Detail |
---|
public boolean hasCursor()
public JTabletCursor getCursor()
public boolean isPollModeLatest()
setPollModeLatest(boolean)
public void setPollModeLatest(boolean b)
isPollModeLatest()
,
poll()
public void finalize() throws JTabletException
finalize
in class java.lang.Object
JTabletException
- if there was an error unloading the tabletpublic void close()
JTabletException
- if there was an error unloading the tabletpublic java.lang.String getVersion()
public static java.lang.String getLibraryVersion()
public boolean poll() throws JTabletException
JTabletException
- if there was an error reading the tabletisPollModeLatest()
,
setPollModeLatest(boolean)
public int getPressure()
getPressureExtent()
to find the maximum value.
JTabletCursor.getPressure()
,
getPressureExtent()
public int getPressureExtent()
getPressure()
.
JTabletCursor.getPressureExtent()
,
getPressure()
public int getAngle()
public int getX()
public int getY()
public int getZ()
public int getOrientation()
JTabletCursor.getData(int)
public int getButtons()
JTabletCursor.getData(int)
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |