|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
de.sciss.gui.SpringPanel
de.sciss.io.AudioFileFormatPane
public class AudioFileFormatPane
A multi component panel
that provides gadgets for
specification of the output
format of an audio file,
such as file format, resolution
or sample rate. It implements
the PreferenceNodeSync
interface, allowing the automatic
saving and recalling of its gadget's
values from/to preferences.
PreferenceNodeSync
,
AudioFileDescr
,
Serialized FormNested Class Summary |
---|
Nested classes/interfaces inherited from class de.sciss.gui.SpringPanel |
---|
SpringPanel.ComponentHeightRatioSpring, SpringPanel.ComponentWidthRatioSpring, SpringPanel.RatioSpring |
Nested classes/interfaces inherited from class javax.swing.JPanel |
---|
javax.swing.JPanel.AccessibleJPanel |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
javax.swing.JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
java.awt.Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
Field Summary | |
---|---|
static int |
CHANNELS
Constructor-Flag : create channel num gadgets |
static int |
ENCODING
Constructor-Flag : create sample encoding gadget |
static int |
FORMAT
Constructor-Flag : create file type gadget |
static int |
FORMAT_ENCODING_RATE
Constructor-Flag : conventient combination of FORMAT , ENCODING and RATE . |
static int |
GAIN
Constructor-Flag : create gain gadget |
static int |
GAIN_NORMALIZE
Constructor-Flag : conventient combination of GAIN and NORMALIZE . |
static int |
NEW_FILE_FLAGS
Constructor-Flag : conventient combination of FORMAT , ENCODING , RATE , CHANNELS . |
static int |
NORMALIZE
Constructor-Flag : create normalize option |
static int |
RATE
Constructor-Flag : create sample rate gadget |
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
AudioFileFormatPane()
|
|
AudioFileFormatPane(int flags)
Construct a new AudioFileFormatPane with the shown components specified by the given flags. |
Method Summary | |
---|---|
void |
automaticFileSuffix(PathField ggPath)
Registers a PathField to
be updated upon format switches. |
void |
fromDescr(AudioFileDescr source)
Copy a sound format from the given AudioFileDescr to the
corresponding gadgets in the pane. |
java.lang.String |
getEncodingString()
Returns a text representation of the encoding (integer/floating point and bit depth). |
int |
getFlags()
|
java.lang.String |
getFormatString()
Returns a text representation of the file format type. |
double |
getGain()
Return the value of the gain gadget (in decibels). |
boolean |
getNormalized()
Return the state of the 'normalized' checkbox of the pane. |
void |
itemStateChanged(java.awt.event.ItemEvent e)
|
void |
setFlags(int flags)
|
void |
setPreferences(java.util.prefs.Preferences prefs)
Enables Preferences synchronization. |
void |
toDescr(AudioFileDescr target)
Copy the internal state of the AudioFileFormatPane into the
AudioFileDescr object. |
Methods inherited from class de.sciss.gui.SpringPanel |
---|
gridAdd, gridAdd, gridAdd, makeCompactGrid, makeCompactGrid, makeGrid, setInitialX, setInitialY, setPadding, setTitle, setXPad, setYPad |
Methods inherited from class javax.swing.JPanel |
---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
Methods inherited from class javax.swing.JComponent |
---|
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
Methods inherited from class java.awt.Container |
---|
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree |
Methods inherited from class java.awt.Component |
---|
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int FORMAT
public static final int ENCODING
public static final int RATE
public static final int GAIN
public static final int NORMALIZE
public static final int CHANNELS
public static final int FORMAT_ENCODING_RATE
FORMAT
, ENCODING
and RATE
.
public static final int NEW_FILE_FLAGS
FORMAT
, ENCODING
, RATE
, CHANNELS
.
public static final int GAIN_NORMALIZE
GAIN
and NORMALIZE
.
Constructor Detail |
---|
public AudioFileFormatPane()
public AudioFileFormatPane(int flags)
flags
- a bitwise OR combination of
gadget creation flags such as FORMAT or GAIN_NORMALIZEMethod Detail |
---|
public void setFlags(int flags)
public int getFlags()
public void toDescr(AudioFileDescr target)
AudioFileFormatPane
into the
AudioFileDescr
object. This will
fill in the type
,
bitsPerSample
, sampleFormat
,
rate
and channels
fields,
provided that the pane was specified
to contain corresponding gadgets
target
- the description whose
format values are to be overwritten.public double getGain()
public java.lang.String getEncodingString()
/b_write
command.
"int16"
public java.lang.String getFormatString()
/b_write
command.
"aiff"
public boolean getNormalized()
true
if the pane's
'normalized' checkbox was checked,
false
otherwise or if no checkbox
gadget exists.public void automaticFileSuffix(PathField ggPath)
PathField
to
be updated upon format switches.
When the user selects a different format,
the path's suffix will be updated accordingly.
ggPath
- the path field to update
or null
to stop
updating.public void fromDescr(AudioFileDescr source)
AudioFileDescr
to the
corresponding gadgets in the pane.
public void itemStateChanged(java.awt.event.ItemEvent e)
itemStateChanged
in interface java.awt.event.ItemListener
public void setPreferences(java.util.prefs.Preferences prefs)
PreferenceNodeSync
setPreferences
in interface PreferenceNodeSync
prefs
- the preferences node in which
the values are stored, or null
to disable prefs sync.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |