Package org.newdawn.slick.font.effects

Examples of org.newdawn.slick.font.effects.ConfigurableEffect$Value


            throw new SlickException("Unable to create effect instance: " + value, ex);
          }
        } else if (name.startsWith("effect.")) {
          // Set an effect value on the last added effect.
          name = name.substring(7);
          ConfigurableEffect effect = (ConfigurableEffect)effects.get(effects.size() - 1);
          List values = effect.getValues();
          for (Iterator iter = values.iterator(); iter.hasNext();) {
            Value effectValue = (Value)iter.next();
            if (effectValue.getName().equals(name)) {
              effectValue.setString(value);
              break;
            }
          }
          effect.setValues(values);
        }
      }
      reader.close();
    } catch (Exception ex) {
      throw new SlickException("Unable to load Hiero font file: " + hieroFileRef, ex);
View Full Code Here


    out.println();
    out.println("glyph.page.width=" + glyphPageWidth);
    out.println("glyph.page.height=" + glyphPageHeight);
    out.println();
    for (Iterator iter = effects.iterator(); iter.hasNext();) {
      ConfigurableEffect effect = (ConfigurableEffect)iter.next();
      out.println("effect.class=" + effect.getClass().getName());
      for (Iterator iter2 = effect.getValues().iterator(); iter2.hasNext();) {
        Value value = (Value)iter2.next();
        out.println("effect." + value.getName() + "=" + value.getString());
      }
      out.println();
    }
View Full Code Here

    padAdvanceXSpinner.setValue(new Integer(settings.getPaddingAdvanceX()));
    padAdvanceYSpinner.setValue(new Integer(settings.getPaddingAdvanceY()));
    glyphPageWidthCombo.setSelectedItem(new Integer(settings.getGlyphPageWidth()));
    glyphPageHeightCombo.setSelectedItem(new Integer(settings.getGlyphPageHeight()));
    for (Iterator iter = settings.getEffects().iterator(); iter.hasNext();) {
      ConfigurableEffect settingsEffect = (ConfigurableEffect)iter.next();
      for (int i = 0, n = effectsListModel.getSize(); i < n; i++) {
        ConfigurableEffect effect = (ConfigurableEffect)effectsListModel.getElementAt(i);
        if (effect.getClass() == settingsEffect.getClass()) {
          effect.setValues(settingsEffect.getValues());
          new EffectPanel(effect);
          break;
        }
      }
    }
View Full Code Here

      }
    });

    effectsList.addListSelectionListener(new ListSelectionListener() {
      public void valueChanged (ListSelectionEvent evt) {
        ConfigurableEffect selectedEffect = (ConfigurableEffect)effectsList.getSelectedValue();
        boolean enabled = selectedEffect != null;
        for (Iterator iter = effectPanels.iterator(); iter.hasNext();) {
          ConfigurableEffect effect = ((EffectPanel)iter.next()).getEffect();
          if (effect == selectedEffect) {
            enabled = false;
            break;
          }
        }
View Full Code Here

            throw new SlickException("Unable to create effect instance: " + value, ex);
          }
        } else if (name.startsWith("effect.")) {
          // Set an effect value on the last added effect.
          name = name.substring(7);
          ConfigurableEffect effect = (ConfigurableEffect)effects.get(effects.size() - 1);
          List values = effect.getValues();
          for (Iterator iter = values.iterator(); iter.hasNext();) {
            Value effectValue = (Value)iter.next();
            if (effectValue.getName().equals(name)) {
              effectValue.setString(value);
              break;
            }
          }
          effect.setValues(values);
        }
      }
      reader.close();
    } catch (Exception ex) {
      throw new SlickException("Unable to load Hiero font file", ex);
View Full Code Here

    out.println();
    out.println("glyph.page.width=" + glyphPageWidth);
    out.println("glyph.page.height=" + glyphPageHeight);
    out.println();
    for (Iterator iter = effects.iterator(); iter.hasNext();) {
      ConfigurableEffect effect = (ConfigurableEffect)iter.next();
      out.println("effect.class=" + effect.getClass().getName());
      for (Iterator iter2 = effect.getValues().iterator(); iter2.hasNext();) {
        Value value = (Value)iter2.next();
        out.println("effect." + value.getName() + "=" + value.getString());
      }
      out.println();
    }
View Full Code Here

TOP

Related Classes of org.newdawn.slick.font.effects.ConfigurableEffect$Value

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.