Lines Matching defs:states

93  * <p>NimbusStyle allows you to specify custom states, or modify the order of
94 * states. Synth (and thus Nimbus) has the concept of a "state". For example,
96 * "DISABLED" state. These are all "standard" states which are defined in synth,
101 * you specify these custom states by including a special key in UIDefaults.
102 * The following UIDefaults entries define three states for this button:</p>
111 * <p>As you can see, the <code>JButton.States</code> entry lists the states
114 * then the standard Synth states will be assumed. If you specify the entry
115 * but the list of states is empty or null, then the standard synth states
146 * states or on LAF changes or updates. This DEFAULT_COLOR is used to
177 * Data structure containing all of the defaults, insets, states, and other
282 //a list of the different types of states used by this style. This
283 //list may contain only "standard" states (those defined by Synth),
284 //or it may contain custom states, or it may contain only "standard"
285 //states but list them in a non-standard order.
286 List<State> states = new ArrayList<State>();
293 //determine whether there are any custom states, or custom state
294 //order. If so, then read all those custom states and define the
297 //there are no custom states or custom state ordering
309 states.add(customState);
312 states.add(State.getStandardState(s[i]));
316 //if there were any states defined, then set the stateTypes array
318 //standard synth states).
319 if (states.size() > 0) {
320 values.stateTypes = states.toArray(new State[states.size()]);
325 for (State state : states) {
330 //since there were no custom states defined, setup the list of
331 //standard synth states. Note that the "v.stateTypes" is not
333 //routines should use standard synth states instead of custom
334 //states. I do need to popuplate this temp list now though, so that
336 states.add(State.Enabled);
337 states.add(State.MouseOver);
338 states.add(State.Pressed);
339 states.add(State.Disabled);
340 states.add(State.Focused);
341 states.add(State.Selected);
342 states.add(State.Default);
344 //assign codes for the states
371 //parse out the states and the property
408 //Multiple states may be specified in the string, such as
458 //now that I've collected all the runtime states, I'll sort them based
462 //finally, set the array of runtime states on the values object
463 values.states = runtimeStates.toArray(new RuntimeState[runtimeStates.size()]);
666 // Search exact matching states and then lesser matching states
670 (s = getNextState(v.states, lastIndex, xstate)) != null) {
714 while ((s = getNextState(v.states, lastIndex, xstate)) != null) {
749 while ((s = getNextState(v.states, lastIndex, xstate)) != null) {
784 while ((s = getNextState(v.states, lastIndex, xstate)) != null) {
833 * ability to define custom states. The algorithm used for choosing what
837 * reported in the SynthContext, in addition to custom states, to determine
865 String[] states = stateNames.split("\\+");
867 // standard states only
868 for (String stateStr : states) {
873 // custom states
875 if (contains(states, s.getName())) {
882 //if there are no custom states defined, then simply return the
886 //there are custom states on this values, so I'll have to iterate
904 * <p>For example, if you had the following three states:
926 private RuntimeState getNextState(RuntimeState[] states,
933 // Consider if we have 3 StateInfos a, b and c with states:
944 if (states != null && states.length > 0) {
952 for (int counter = states.length - 1; counter >= 0; counter--) {
953 if (states[counter].state == 0) {
955 return states[counter];
969 states.length : lastState[0];
972 int oState = states[counter].state;
1001 return states[bestIndex];
1005 return states[wildIndex];
1056 * as Enabled, Default, WindowFocused, etc. These can be custom states.
1062 * several states together, and have associated properties, data, etc.
1064 RuntimeState[] states = null;