RE: TextField Border [Ref:C436802]

TextGraphics do not automatically wordwrap, but the text can span multiple lines
by using \n in the text as line breaks.
Steve Elvin
Systems Developer
Frontline Ltd
UK
-----Original Message-----
From: INTERNET [email protected]
Sent: Wednesday, December 02, 1998 1:38 PM
To: Steve Elvin; X400
p=NET;a=CWMAIL;c=GB;DDA:RFC-822=forte-users(a)sagesoln.com;
Subject: TextField Border [Ref:C436802]
Hi All,
We have a message window in our system which displays a system message to our us
ers. If the message is not acknowledged within 1 minute, the window will automat
ically timeout and disappear; for this reason we created our own window with a t
imer which shuts it down. The message is placed into a TextField in the window,
but when we converted our system to Forte v3.0 the TextField displayed with a bo
rder around it. We tried to remove this border with no luck. We also tried chang
ing the widget to a TextEditField but this would not allow WordWrap so most of t
he message would disappear.
Is there anyway to get rid of the border on the TextField or use another which t
hat will allow WordWrap? Basically we want the window to look exactly like the F
orte MessageDialog or QuestionDialog windows.
Many Thanks,
Michael Mamarot
EMail : [email protected]
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

Well, I've determined the cause of the problem has to do with the lack of support provided by the Adobe XML Form Object Model. Every TextField encapsulates a caption object. This object has two properties, placement and reserve, that can be used to manipulate the placement of the "Caption", hence the cursor when it enters the TextField.
The problem is that we only have one placement property per caption object. This limits the ability to specify both the height and width of the caption region. According to the XML Form Object Model 2.2, "the effect of the reserve property is determined by the placement property. When the caption is placed at the left or right, the reserve property specifies the height of the caption region. When the caption is placed at the top or bottom the reserve property specifies the width." A more ideal Object Model would specify two placement properties with corresponding reserve properties so that both the width and height can be manipulated at the same time, allowing us to squeeze the caption region within the boundary of the TextField border.
I initially though the cursor was overlaying the TextField border but now Im convinced it is the caption object overlaying the TextField. By adjusting the reserve property of the caption object I began to see more of the underlying border changing color when the enter event fired, the problem is that I can only adjust the width or height but not both.
I'm still trying to find a workaround so if you happen to know one please let me know.
Alex

Similar Messages

  • TextField Border

    Hi All,
    We have a message window in our system which displays a system message to our users. If the message is not acknowledged within 1 minute, the window will automatically timeout and disappear; for this reason we created our own window with a timer which shuts it down. The message is placed into a TextField in the window, but when we converted our system to Forte v3.0 the TextField displayed with a border around it. We tried to remove this border with no luck. We also tried changing the widget to a TextEditField but this would not allow WordWrap so most of the message would disappear.
    Is there anyway to get rid of the border on the TextField or use another which that will allow WordWrap? Basically we want the window to look exactly like the Forte MessageDialog or QuestionDialog windows.
    Many Thanks,
    Michael Mamarot
    EMail : [email protected]
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

    Here is a method using the Flash graphics API.

  • How can i remove the border of TextField

    Hi,first i set the border of textfield in my program now i want to remove this border and want to set the default border.how can i do that.
    thanks

    try this,
    UIManager.put("TextField.border", new EmptyBorder());
    or maybe set the border part to null. I think it works.
    by the way put this line right at the start of your program so that all text fields will be shown without borders.
    Jim

  • Code for changing a TextField BackGround color?

    Hello again!
    I can´t find anywhere the code for changing the background color of a TextField, anyone knows?
    I tried:
         TextField.border.fill.color.value = "255,255,255";      // doesn´t change bg color
         TextField.caption.font.fill.color.value = "255,255,255";     // doesn´t change bg color
         TextField.value.rectangle.fill.color.value = "153,153,153";      // doesn´t change bg color
    Bur none of them works!

    The script works fine..please show here..
    https://workspaces.acrobat.com/?d=EKbH6jmrJ-5RXnVNyxPiPA
    Kind regards,
    Mandy

  • NullPointerException - Cannot get the value from variable f_cashGiven

    In SubCheckout.java (a POS), what I want is when Payment button (f_cashPayment) is pressed, the action "Cash" is performed, get the value from Cash Given (f_cashGiven), do the subtraction and post the value as Cash Return (f_cashReturn). The code is filled in actionPerformed. But I cannot get the value by using f_cashGiven.getValue() from VNumber class. It returns NULL. This should be quite straight forward, but I do not know what is wrong. Please help!
    Enclosed please find the source code of SubCheckout.java and VNumber.java
    This is the code of SubCheckout.java :
    * The contents of this file are subject to the   Compiere License  Version 1.1
    * ("License"); You may not use this file except in compliance with the License
    * You may obtain a copy of the License at http://www.compiere.org/license.html
    * Software distributed under the License is distributed on an  "AS IS"  basis,
    * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
    * the specific language governing rights and limitations under the License.
    * The Original Code is Compiere ERP & CRM Smart Business Solution. The Initial
    * Developer of the Original Code is Jorg Janke. Portions created by Jorg Janke
    * are Copyright (C) 1999-2005 Jorg Janke.
    * All parts are Copyright (C) 1999-2005 ComPiere, Inc.  All Rights Reserved.
    * Contributor(s): ______________________________________.
    package org.compiere.pos;
    import java.awt.*;
    import java.awt.event.*;
    import java.math.BigDecimal;
    import javax.swing.border.*;
    import org.compiere.grid.ed.*;
    import org.compiere.swing.*;
    import org.compiere.util.*;
    *     POS Checkout Sub Panel
    *  @author Jorg Janke
    *  @version $Id: SubCheckout.java,v 1.3 2005/03/11 20:28:22 jjanke Exp $
    public class SubCheckout extends PosSubPanel implements ActionListener
          *      Constructor
          *     @param posPanel POS Panel
         public SubCheckout (PosPanel posPanel)
              super (posPanel);
         }     //     PosSubCheckout
         private CButton f_register = null;
         private CButton f_summary = null;
         private CButton f_process = null;
         private CButton f_print = null;
         private CLabel f_lcreditCardNumber = null;
         private CTextField f_creditCardNumber = null;
         private CLabel f_lcreditCardExp = null;
         private CTextField f_creditCardExp = null;
         private CLabel f_lcreditCardVV = null;
         private CTextField f_creditCardVV = null;
         private CButton f_cashPayment = null;
         private CLabel f_lcashGiven = null;
         private VNumber f_cashGiven = null;
         private CLabel f_lcashReturn = null;
         private VNumber f_cashReturn = null;
         private CButton f_creditPayment = null;
         /**     Logger               */
         private static CLogger log = CLogger.getCLogger(SubCheckout.class);
          *      Initialize
         public void init()
              //     Title
              TitledBorder border = new TitledBorder(Msg.getMsg(Env.getCtx(), "Checkout"));
              setBorder(border);
              //     Content
              setLayout(new GridBagLayout());
              GridBagConstraints gbc = new GridBagConstraints();
              gbc.insets = INSETS2;
              //     --     0
              gbc.gridx = 0;
              f_register = createButtonAction("Register", null);
              gbc.gridy = 0;
              add (f_register, gbc);
              f_summary = createButtonAction("Summary", null);
              gbc.gridy = 1;
              add (f_summary, gbc);
              f_process = createButtonAction("Process", null);
              gbc.gridy = 2;
              add (f_process, gbc);
              f_print = createButtonAction("Print", null);
              gbc.gridy = 3;
              add (f_print, gbc);
              //     --     1 -- Cash
              gbc.gridx = 1;
              gbc.gridheight = 2;
              gbc.fill = GridBagConstraints.BOTH;
              gbc.weightx = .1;
              CPanel cash = new CPanel(new GridBagLayout());
              cash.setBorder(new TitledBorder(Msg.getMsg(Env.getCtx(), "Cash")));
              gbc.gridy = 0;
              add (cash, gbc);
              GridBagConstraints gbc0 = new GridBagConstraints();
              gbc0.insets = INSETS2;
              gbc0.anchor = GridBagConstraints.WEST;
              f_lcashGiven = new CLabel(Msg.getMsg(Env.getCtx(),"CashGiven"));
              cash.add (f_lcashGiven, gbc0);
              f_cashGiven = new VNumber("CashGiven", false, false, true, DisplayType.Amount,
                   Msg.translate(Env.getCtx(), "CashGiven"));
              f_cashGiven.addActionListener(this);
              f_cashGiven.setColumns(10, 25);
              cash.add (f_cashGiven, gbc0);
              f_cashGiven.setValue(Env.ZERO);
              f_lcashReturn = new CLabel(Msg.getMsg(Env.getCtx(),"CashReturn"));
              cash.add (f_lcashReturn, gbc0);
              f_cashReturn = new VNumber("CashReturn", false, true, false, DisplayType.Amount,
                   "CashReturn");
              f_cashReturn.setColumns(10, 25);
              cash.add (f_cashReturn, gbc0);
              f_cashReturn.setValue(Env.ZERO);
              f_cashPayment = createButtonAction("Payment", null);
              f_cashPayment.setActionCommand("Cash");
              gbc0.anchor = GridBagConstraints.EAST;
              gbc0.weightx = 0.1;
              cash.add (f_cashPayment, gbc0);
              //     --     1 -- Creditcard
              CPanel creditcard = new CPanel(new GridBagLayout());
              creditcard.setBorder(new TitledBorder(Msg.translate(Env.getCtx(), "CreditCardType")));
              gbc.gridy = 2;
              add (creditcard, gbc);
              GridBagConstraints gbc1 = new GridBagConstraints();
              gbc1.insets = INSETS2;
              gbc1.anchor = GridBagConstraints.WEST;
              gbc1.gridx = 0;
              gbc1.gridy = 0;
              f_lcreditCardNumber = new CLabel(Msg.translate(Env.getCtx(), "CreditCardNumber"));
              creditcard.add (f_lcreditCardNumber, gbc1);
              gbc1.gridy = 1;
              f_creditCardNumber = new CTextField(18);
              creditcard.add (f_creditCardNumber, gbc1);
              gbc1.gridx = 1;
              gbc1.gridy = 0;
              f_lcreditCardExp = new CLabel(Msg.translate(Env.getCtx(),"CreditCardExp"));
              creditcard.add (f_lcreditCardExp, gbc1);
              gbc1.gridy = 1;
              f_creditCardExp = new CTextField(5);
              creditcard.add (f_creditCardExp, gbc1);
              gbc1.gridx = 2;
              gbc1.gridy = 0;
              f_lcreditCardVV = new CLabel(Msg.translate(Env.getCtx(), "CreditCardVV"));
              creditcard.add (f_lcreditCardVV, gbc1);
              gbc1.gridy = 1;
              f_creditCardVV = new CTextField(5);
              creditcard.add (f_creditCardVV, gbc1);
              gbc1.gridx = 3;
              gbc1.gridy = 0;
              gbc1.gridheight = 2;
              f_creditPayment = createButtonAction("Payment", null);
              f_creditPayment.setActionCommand("CreditCard");
              gbc1.anchor = GridBagConstraints.EAST;
              gbc1.weightx = 0.1;
              creditcard.add (f_creditPayment, gbc1);
         }     //     init
          *      Get Panel Position
         public GridBagConstraints getGridBagConstraints()
              GridBagConstraints gbc = super.getGridBagConstraints();
              gbc.gridx = 0;
              gbc.gridy = 3;
              return gbc;
         }     //     getGridBagConstraints
          *      Dispose - Free Resources
         public void dispose()
              super.dispose();
         }     //     dispose
          *      Action Listener
          *     @param e event
         public void actionPerformed (ActionEvent e)
              String action = e.getActionCommand();
              if (action == null || action.length() == 0)
                   return;
              log.info( "PosSubCheckout - actionPerformed: " + action);
              if (e.getSource() == f_cashGiven) {
                   f_cashGiven.setValue(f_cashGiven.getValue());
                   System.out.println("f_cashGiven"+f_cashGiven.getDisplay());
              //     Register
              //     Summary
              //     Print
              if (action.equals("Cash")) {
                   BigDecimal CashGiven, GrandTotal, CashReturn;
                   System.out.println("Cash given is "+f_cashGiven.getDisplay());
                   CashGiven = (BigDecimal)f_cashGiven.getValue();
                   GrandTotal = (BigDecimal)p_posPanel.f_curLine.getOrder().getGrandTotal();
                   CashReturn = CashGiven.subtract(GrandTotal);
                   f_cashReturn.setValue(CashReturn);
              //     Cash (Payment)
              //     CreditCard (Payment)
         }     //     actionPerformed
    }     //     PosSubCheckoutThis is the code of VNumber.java :
    * The contents of this file are subject to the   Compiere License  Version 1.1
    * ("License"); You may not use this file except in compliance with the License
    * You may obtain a copy of the License at http://www.compiere.org/license.html
    * Software distributed under the License is distributed on an  "AS IS"  basis,
    * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
    * the specific language governing rights and limitations under the License.
    * The Original Code is Compiere ERP & CRM Smart Business Solution. The Initial
    * Developer of the Original Code is Jorg Janke. Portions created by Jorg Janke
    * are Copyright (C) 1999-2005 Jorg Janke.
    * All parts are Copyright (C) 1999-2005 ComPiere, Inc.  All Rights Reserved.
    * Contributor(s): ______________________________________.
    package org.compiere.grid.ed;
    import java.awt.*;
    import java.awt.event.*;
    import java.beans.*;
    import java.math.*;
    import java.text.*;
    import java.util.logging.*;
    import javax.swing.*;
    import javax.swing.text.*;
    import org.compiere.apps.*;
    import org.compiere.model.*;
    import org.compiere.swing.*;
    import org.compiere.util.*;
    *     Number Control
    *      @author      Jorg Janke
    *      @version      $Id: VNumber.java,v 1.41 2005/09/03 01:57:16 jjanke Exp $
    public final class VNumber extends JComponent
         implements VEditor, ActionListener, KeyListener, FocusListener
         /**     Number of Columns (12)          */
         public final static int SIZE = 12;
          *  IDE Bean Constructor
         public VNumber()
              this("Number", false, false, true, DisplayType.Number, "Number");
         }   //  VNumber
          *     Create right aligned Number field.
          *     no popup, if WindowNo == 0 (for IDs)
          *  @param columnName column name
          *  @param mandatory mandatory
          *  @param isReadOnly read only
          *  @param isUpdateable updateable
          *  @param displayType display type
          *  @param title title
         public VNumber(String columnName, boolean mandatory, boolean isReadOnly, boolean isUpdateable,
              int displayType, String title)
              super();
              super.setName(columnName);
              m_columnName = columnName;
              m_title = title;
              setDisplayType(displayType);
              LookAndFeel.installBorder(this, "TextField.border");
              this.setLayout(new BorderLayout());
    //          this.setPreferredSize(m_text.getPreferredSize());          //     causes r/o to be the same length
    //          int height = m_text.getPreferredSize().height;
    //          setMinimumSize(new Dimension (30,height));
              //     ***     Text     ***
              m_text.setBorder(null);
              m_text.setHorizontalAlignment(JTextField.TRAILING);
              m_text.addKeyListener(this);
              m_text.addFocusListener(this);
              //     Background
              setMandatory(mandatory);
              this.add(m_text, BorderLayout.CENTER);
              //     ***     Button     ***
              m_button.setIcon(Env.getImageIcon("Calculator10.gif"));
              m_button.setMargin(new Insets(0, 0, 0, 0));
              m_button.setFocusable(false);
              m_button.addActionListener(this);
              this.add (m_button, BorderLayout.EAST);
              //     Prefereed Size
              this.setPreferredSize(this.getPreferredSize());          //     causes r/o to be the same length
              //  Size
              setColumns(SIZE, CComboBox.FIELD_HIGHT-4);     
              //     ReadWrite
              if (isReadOnly || !isUpdateable)
                   setReadWrite(false);
              else
                   setReadWrite(true);
         }     //     VNumber
          *  Dispose
         public void dispose()
              m_text = null;
              m_button = null;
              m_mField = null;
         }   //  dispose
          *     Set Document
          *  @param doc document
         protected void setDocument(Document doc)
              m_text.setDocument(doc);
         }     //     getDocument
         private String               m_columnName;
         protected int               m_displayType;     //  Currency / UoM via Context
         private DecimalFormat     m_format;
         private String               m_title;
         private boolean               m_setting;
         private String               m_oldText;
         private String               m_initialText;
         private boolean               m_rangeSet = false;
         private Double               m_minValue;
         private Double               m_maxValue;
         private boolean               m_modified = false;
         /**  The Field                  */
         private CTextField          m_text = new CTextField(SIZE);     //     Standard
         /** The Button                  */
         private CButton              m_button = new CButton();
         private MField          m_mField = null;
         /**     Logger               */
         private static CLogger log = CLogger.getCLogger(VNumber.class);
          *      Set no of Columns
          *     @param columns columns
         public void setColumns (int columns, int height)
              m_text.setPreferredSize(null);
              m_text.setColumns(columns);
              Dimension size = m_text.getPreferredSize();
              if (height > size.height)               //     default 16
                   size.height = height;
              if (CComboBox.FIELD_HIGHT-4 > size.height)
                   size.height = VLookup.FIELD_HIGHT-4;
              this.setPreferredSize(size);          //     causes r/o to be the same length
              this.setMinimumSize(new Dimension (columns*10, size.height));
              m_button.setPreferredSize(new Dimension(size.height, size.height));
         }     //     setColumns
          *     Set Range with min & max
          *  @param minValue min value
          *  @param maxValue max value
          *     @return true, if accepted
         public boolean setRange(Double minValue, Double maxValue)
              m_rangeSet = true;
              m_minValue = minValue;
              m_maxValue = maxValue;
              return m_rangeSet;
         }     //     setRange
          *     Set Range with min & max = parse US style number w/o Gouping
          *  @param minValue min value
          *  @param maxValue max value
          *  @return true if accepted
         public boolean setRange(String minValue, String maxValue)
              if (minValue == null || maxValue == null)
                   return false;
              try
                   m_minValue = Double.valueOf(minValue);
                   m_maxValue = Double.valueOf(maxValue);
              catch (NumberFormatException nfe)
                   return false;
              m_rangeSet = true;
              return m_rangeSet;
         }     //     setRange
          *  Set and check DisplayType
          *  @param displayType display type
         public void setDisplayType (int displayType)
              m_displayType = displayType;
              if (!DisplayType.isNumeric(displayType))
                   m_displayType = DisplayType.Number;
              m_format = DisplayType.getNumberFormat(displayType);
              m_text.setDocument (new MDocNumber(displayType, m_format, m_text, m_title));
         }   //  setDisplayType
          *     Set ReadWrite
          *  @param value value
         public void setReadWrite (boolean value)
              if (m_text.isReadWrite() != value)
                   m_text.setReadWrite(value);
              if (m_button.isReadWrite() != value)
                   m_button.setReadWrite(value);
              //     Don't show button if not ReadWrite
              if (m_button.isVisible() != value)
                   m_button.setVisible(value);
         }     //     setReadWrite
          *     IsReadWrite
          *  @return true if rw
         public boolean isReadWrite()
              return m_text.isReadWrite();
         }     //     isReadWrite
          *     Set Mandatory (and back bolor)
          *  @param mandatory mandatory
         public void setMandatory (boolean mandatory)
              m_text.setMandatory(mandatory);
         }     //     setMandatory
          *     Is it mandatory
          *  @return true if mandatory
         public boolean isMandatory()
              return m_text.isMandatory();
         }     //     isMandatory
          *     Set Background
          *  @param color color
         public void setBackground(Color color)
              m_text.setBackground(color);
         }     //     setBackground
          *     Set Background
          *  @param error error
         public void setBackground (boolean error)
              m_text.setBackground(error);
         }     //     setBackground
          *  Set Foreground
          *  @param fg foreground
         public void setForeground(Color fg)
              m_text.setForeground(fg);
         }   //  setForeground
          *     Set Editor to value
          *  @param value value
         public void setValue(Object value)
              log.finest("Value=" + value);
              if (value == null)
                   m_oldText = "";
              else
                   m_oldText = m_format.format(value);
              //     only set when not updated here
              if (m_setting)
                   return;
              m_text.setText (m_oldText);
              m_initialText = m_oldText;
              m_modified = false;
         }     //     setValue
          *  Property Change Listener
          *  @param evt event
         public void propertyChange (PropertyChangeEvent evt)
              if (evt.getPropertyName().equals(org.compiere.model.MField.PROPERTY))
                   setValue(evt.getNewValue());
         }   //  propertyChange
          *     Return Editor value
          *  @return value value (big decimal or integer)
         public Object getValue()
              if (m_text == null || m_text.getText() == null || m_text.getText().length() == 0)
                   return null;
              String value = m_text.getText();
              //     return 0 if text deleted
              if (value == null || value.length() == 0)
                   if (!m_modified)
                        return null;
                   if (m_displayType == DisplayType.Integer)
                        return new Integer(0);
                   return Env.ZERO;
              if (value.equals(".") || value.equals(",") || value.equals("-"))
                   value = "0";
              try
                   Number number = m_format.parse(value);
                   value = number.toString();      //     converts it to US w/o thousands
                   BigDecimal bd = new BigDecimal(value);
                   if (m_displayType == DisplayType.Integer)
                        return new Integer(bd.intValue());
                   if (bd.signum() == 0)
                        return bd;
                   return bd.setScale(m_format.getMaximumFractionDigits(), BigDecimal.ROUND_HALF_UP);
              catch (Exception e)
                   log.log(Level.SEVERE, "Value=" + value, e);
              if (m_displayType == DisplayType.Integer)
                   return new Integer(0);
              return Env.ZERO;
         }     //     getValue
          *  Return Display Value
          *  @return value
         public String getDisplay()
              return m_text.getText();
         }   //  getDisplay
          *      Get Title
          *     @return title
         public String getTitle()
              return m_title;
         }     //     getTitle
          *      Plus - add one.
          *      Also sets Value
          *     @return new value
         public Object plus()
              Object value = getValue();
              if (value == null)
                   if (m_displayType == DisplayType.Integer)
                        value = new Integer(0);
                   else
                        value = Env.ZERO;
              //     Add
              if (value instanceof BigDecimal)
                   value = ((BigDecimal)value).add(Env.ONE);
              else
                   value = new Integer(((Integer)value).intValue() + 1);
              setValue(value);
              return value;
         }     //     plus
          *      Minus - subtract one, but not below minimum.
          *      Also sets Value
          *     @param minimum minimum
          *     @return new value
         public Object minus (int minimum)
              Object value = getValue();
              if (value == null)
                   if (m_displayType == DisplayType.Integer)
                        value = new Integer(minimum);
                   else
                        value = new BigDecimal(minimum);
                   setValue(value);
                   return value;
              //     Subtract
              if (value instanceof BigDecimal)
                   BigDecimal bd = ((BigDecimal)value).subtract(Env.ONE);
                   BigDecimal min = new BigDecimal(minimum);
                   if (bd.compareTo(min) < 0)
                        value = min;
                   else
                        value = bd;
              else
                   int i = ((Integer)value).intValue();
                   i--;
                   if (i < minimum)
                        i = minimum;
                   value = new Integer(i);
              setValue(value);
              return value;
         }     //     minus
          *     Action Listener
          *  @param e event
         public void actionPerformed (ActionEvent e)
              log.config(e.getActionCommand());
              if (ValuePreference.NAME.equals(e.getActionCommand()))
                   if (MRole.getDefault().isShowPreference())
                        ValuePreference.start (m_mField, getValue());
                   return;
              if (e.getSource() == m_button)
                   m_button.setEnabled(false);
                   String str = startCalculator(this, m_text.getText(), m_format, m_displayType, m_title);
                   m_text.setText(str);
                   m_button.setEnabled(true);
                   try
                        fireVetoableChange (m_columnName, m_oldText, getValue());
                   catch (PropertyVetoException pve)     {}
                   m_text.requestFocus();
         }     //     actionPerformed
          *     Key Listener Interface
          *  @param e event
         public void keyTyped(KeyEvent e)    {}
         public void keyPressed(KeyEvent e)  {}
          *     Key Listener.
          *          - Escape           - Restore old Text
          *          - firstChange     - signal change
          *  @param e event
         public void keyReleased(KeyEvent e)
              log.finest("Key=" + e.getKeyCode() + " - " + e.getKeyChar()
                           + " -> " + m_text.getText());
              //  ESC
              if (e.getKeyCode() == KeyEvent.VK_ESCAPE)
                   m_text.setText(m_initialText);
              m_modified = true;
              m_setting = true;
              try
                   if (e.getKeyCode() == KeyEvent.VK_ENTER)     //     10
                        fireVetoableChange (m_columnName, m_oldText, getValue());
                        fireActionPerformed();
                   else     //     indicate change
                        fireVetoableChange (m_columnName, m_oldText, null);     
              catch (PropertyVetoException pve)     {}
              m_setting = false;
         }     //     keyReleased
          *     Focus Gained
          *  @param e event
         public void focusGained (FocusEvent e)
              if (m_text != null)
                   m_text.selectAll();
         }     //     focusGained
          *     Data Binding to MTable (via GridController.vetoableChange).
          *  @param e event
         public void focusLost (FocusEvent e)
         //          log.finest(e.toString());
              //     APanel - Escape
              if (e.getOppositeComponent() instanceof AGlassPane)
                   m_text.setText(m_initialText);
                   return;
              try
                   fireVetoableChange (m_columnName, m_initialText, getValue());
                   fireActionPerformed();
              catch (PropertyVetoException pve)     {}
         }   //  focusLost
          *     Invalid Entry - Start Calculator
          *  @param jc parent
          *  @param value value
          *  @param format format
          *  @param displayType display type
          *  @param title title
          *  @return value
         public static String startCalculator(Container jc, String value,
              DecimalFormat format, int displayType, String title)
              log.config("Value=" + value);
              BigDecimal startValue = new BigDecimal(0.0);
              try
                   if (value != null && value.length() > 0)
                        Number number = format.parse(value);
                        startValue = new BigDecimal (number.toString());
              catch (ParseException pe)
                   log.info("InvalidEntry - " + pe.getMessage());
              //     Find frame
              Frame frame = Env.getFrame(jc);
              //     Actual Call
              Calculator calc = new Calculator(frame, title,
                   displayType, format, startValue);
              AEnv.showCenterWindow(frame, calc);
              BigDecimal result = calc.getNumber();
              log.config( "Result=" + result);
              calc = null;
              if (result != null)
                   return format.format(result);
              else
                   return value;          //     original value
         }     //     startCalculator
          *  Set Field/WindowNo for ValuePreference
          *  @param mField field
         public void setField (MField mField)
              m_mField = mField;
              if (m_mField != null
                   && MRole.getDefault().isShowPreference())
                   ValuePreference.addMenu (this, popupMenu);
         }   //  setField
          *      Remove Action Listner
          *      @param l Action Listener
         public void removeActionListener(ActionListener l)
              listenerList.remove(ActionListener.class, l);
         }     //     removeActionListener
          *      Add Action Listner
          *      @param l Action Listener
         public void addActionListener(ActionListener l)
              listenerList.add(ActionListener.class, l);
         }     //     addActionListener
          *      Fire Action Event to listeners
         protected void fireActionPerformed()
              int modifiers = 0;
              AWTEvent currentEvent = EventQueue.getCurrentEvent();
              if (currentEvent instanceof InputEvent)
                   modifiers = ((InputEvent)currentEvent).getModifiers();
              else if (currentEvent instanceof ActionEvent)
                   modifiers = ((ActionEvent)currentEvent).getModifiers();
              ActionEvent ae = new ActionEvent (this, ActionEvent.ACTION_PERFORMED,
                   "VNumber", EventQueue.getMostRecentEventTime(), modifiers);
              // Guaranteed to return a non-null array
              Object[] listeners = listenerList.getListenerList();
              // Process the listeners last to first, notifying those that are interested in this event
              for (int i = listeners.length-2; i>=0; i-=2)
                   if (listeners==ActionListener.class)
                        ((ActionListener)listeners[i+1]).actionPerformed(ae);
         }     //     fireActionPerformed
    }     //     VNumber

    If getValue() returns null, you need to trace the execution of the code and figure out which sequence of code is leading to the return of null. This method looks complex - a lot of if statements. If you do not have a debugger, put System.out.println statements inside the method to figure out what's going on.

  • Embedding Font in FB 4.7 AIR 3.9

    Hello,
    Is there a different way to embed fonts with Air 3.9 or FB 4.7? I've recently upgrading and I am experience tempremental results with embedding fonts.
    With FB 4.6 and Air 3.7 the following works fine -
    [Embed(source="/assets/fonts/SEGOEUIL.TTF", fontName="Segoe UI Light", mimeType="application/x-font-truetype")]
                        public static var EverydayFont:Class;
                                            var textFormat:TextFormat = new TextFormat();
                                            var mainFont:Font = new EverydayFont();
                                            textFormat.font = mainFont.fontName;
                                  var textfield:TextField = new TextField();
                                  textfield.mouseEnabled = false;
                                  textfield.selectable = false;
      textfield.defaultTextFormat = textFormat;
                                  textfield.multiline = false;
                                  textfield.border = true;
                                  textfield.embedFonts = embedFont;
                                  textfield.width = width;
      textfield.antiAliasType = antiAliasStyle;
                                  textfield.htmlText = label;
    However now with the latest versions the text box is just blank..??

    Ok, I'm gonna give you the code that worked for me when I was working on a project back than, cause I also had a simillar, if not the same (can't remember), problem.
    So here it goes:
    [Embed(source="SuchFont.ttf", fontName="SuchFont", mimeType="application/x-font", embedAsCFF="true")]
    public static var SuchFont:Class;
    var font:Font = new SuchFont;
    var format:TextFormat = new TextFormat(font.fontName, 20, 0xFFFFFF, true, null, null, null, null, TextAlign.LEFT);
    awesomeText = new TextField;
    awesomeText.defaultTextFormat = format;
    awesomeText.embedFonts = true;
    awesomeText.width = 158;
    awesomeText.height = 56;
    awesomeText.x = 106;
    awesomeText.y = 420;
    I think the trick is using embedAsCFF="true", but the issue here could be that you're using htmlText, have you tried with text?

  • AS3: How to get height of a dynamically created text field

    I am importing text from an XML file and want the lines of text to display in separate text fields beneath each other. How can I set the y value of each succeeding text field so that there is some space (40 pixels or so) from the above field, regardless of the length of the text? Here is my current code. Any help would be greatly appreciated.
    var textArray:Array = new Array();
    for (var i:int; i <myXML.TOPIC[0].QUERY.length(); i++) {
    var textField:TextField = new TextField();
    textField.htmlText = myXML.TOPIC[0].QUERY[i].QUESTION;
    textField.x = 100;
    //below is my problem....I want the y value to be based on the height of all the previous text fields that have been created
    textField.y = 100+(40*i);
    textField.border = true;
    textField.width = 800;
    textField.textColor = 0x000000;
    textField.multiline = true;
    textField.wordWrap = true;
    textField.selectable = false;
    addChild(textField);
    textArray.push(textField);

    There's nothing wrong with the approach you took... retain it as is.  What I was suggesting is basically the same, just a slightly different angle that doesn't need the conditional....
    var currentY:Number = 100;
    for (var j:int = 0; j <myXML.TOPIC[0].QUERY.length(); j++) {
       textArray[j].y =  currentY;
        // text gets added somewhere in here
        currentY =  currentY+textArray[j].height+5;

  • Need basic control of a TextArea component

    I am dynamically creating a TextArea on the stage and want to
    do 2 things:
    1. Remove the border so it's not visible
    I think doing this with AS2 was something like
    setStyle("borderStyle", "none");
    2. Make the text not selectable (this is different that
    editable)
    In TextField instances, you can control this. Can it be
    controlled for a TextArea, though?

    That seems easy enough, thanks for pointing me in that
    direction. But, when I set the following...
    myTextArea.textField.selectable = false;
    myTextArea.textField.border = false;
    ...nothing changes. It's odd, though, that I can trace both
    of these properties afterwards and see that they are indeed set to
    false; the text is still selectable and the border is still shown.
    How do you properly affect these properties for a TextArea
    ?

  • How can I refer to a value of the textfield1 into the textfield2 and set readonly textfield2, and join the value of various textfields in just one textfield multiline ?

    I am new in acroforms.
    I have a form with 5 pages, in the first page the user fill personal information, the fields are (names, addres, birtdate, ocupation,etc ) all are texboxes, I need to get the same value of every textboxes of the first page into the 2d and 3, 4 and 5 pages, I have created another textboxes in the 2, 3 .. pages with the same names in order to duplicate the value of each one, but if I make some of them readonly, every textboxes in every page are readonly...
    For that reaseon, I tried changin the name of the texboxes of the 2, 3, 4 and 5 pages to names1, names2, names3, names4, and so on for the other fields, I have written some scripts, but no lucky, because I used this line in every new textbox, as the following (for the textbox names1)
    this.getField("names").Value
    Without results, the textboxes apears in blank
    And also, in the last page I need to join some texboxes values in only one multiline textbox
    Please any advice will be welcome..
    Muchas gracias
    Rafsys

    For the information in the second text box to be the same as the first text box (i.e. - on later pages), simply give the fields the same name. The second on could be set to readonly and you could even remove the borders and such so it looked like it was just part of the page. This last trick would get around the need to combine the fields for the display as you mention. Combining the fields would have to be done with JavaScript.

  • Mouse over textInput goes over textField inside textInput

    Hi,
    I got a textInput field, to which I attach a listener for mouseOver event.  When mouse goes over this field it should do some basic stuff, like get the field's ID.  But I get error becouse the 'e.target' object doesn't have the 'ID' property. Debugger shows that 'e.target' is a textField not a textInput. It seems that mouse is over textField which is inside my textInput, and that textField doesn't have an 'ID' property.
    My listener works only when mouse is over the thin border of textInput. This border is around the textField, which is inside my textInput.
    Does anybody have an idea how to repair this situation?

    Use the event currentTarget property. With controls like TextInput and Button, etc. that have sub-controls, you need to refer to the currentTarget property, not the target property.
    If this post answers your question or helps, please mark it as such.
    Greg Lafrance - Flex 2 and 3 ACE certified
    www.ChikaraDev.com
    Flex Training and Support Services

  • Android, backspace doesn't work properly in a flash.text.TextField

    Hello,
    I have a bug on my Nexus 5 Android 4.4 Air 4.0.
    when I scroll the text in the textField and I select the text (in my example near "subclass" word), the TextField get focus, if I put on the backspace key, the character deleted is the previous character the first time, and if I put again on the backspace key, the caracter deleted is the first character and not the previous character.
    package{
    import flash.text.TextField;
    import flash.display.Sprite;
    import flash.events.Event;
    import flash.display.StageAlign;
    import flash.display.StageScaleMode;
    public class Main extends Sprite {
      private var myTextField:TextField = new TextField();
      public function Main() {
        stage.scaleMode = StageScaleMode.NO_SCALE;
        stage.align = StageAlign.TOP_LEFT;
        addEventListener(Event.ADDED_TO_STAGE, init);
      private function init(event:Event):void {
        myTextField.type="input";
        myTextField.text="The TextField class is used to create display objects for text display and input. You can give a text field an instance name in the Property inspector and use the methods and properties of the TextField class to manipulate it with ActionScript. TextField instance names are displayed in the Movie Explorer and in the Insert Target Path dialog box in the Actions panel.\nTo create a text field dynamically, use the TextField() constructor.\n\nThe methods of the TextField class let you set, select, and manipulate text in a dynamic or input text field that you create during authoring or at runtime.\n\nActionScript provides several ways to format your text at runtime. The TextFormat class lets you set character and paragraph formatting for TextField objects. You can apply Cascading Style Sheets (CSS) styles to text fields by using the TextField.styleSheet property and the StyleSheet class. You can use CSS to style built-in HTML tags, define new formatting tags, or apply styles. You can assign HTML formatted text, which optionally uses CSS styles, directly to a text field. HTML text that you assign to a text field can contain embedded media (movie clips, SWF files, GIF files, PNG files, and JPEG files). The text wraps around the embedded media in the same way that a web browser wraps text around media embedded in an HTML document.\n\nFlash Player supports a subset of HTML tags that you can use to format text. See the list of supported HTML tags in the description of the htmlText property.\n\nView the examples\n\nMore examples\n\nModifying the text field contents\nDisplaying HTML text\nUsing images in text fields\nScrolling text in a text field\nSelecting and manipulating text\nCapturing text input\nRestricting text input\nFormatting text\nWorking with static text\nTextField Example: Newspaper-style text formatting\nLearn more\n\nUse native features with a soft keyboard\nDisplay programming\nBasics of display programming\nCore display classes\nChoosing a DisplayObject subclass\nBasics of Working with text\nUsing the TextField class\nDisplaying text\nAdvanced text rendering\nRelated API Elements\n\nflash.text.TextFormat\nflash.text.StyleSheet\nhtmlText\n\nPublic Properties\n Show Inherited Public Properties\n   Property  Defined By\n      alwaysShowSelection : Boolean\nWhen set to true and the text field is not in focus, Flash Player highlights the selection in the text field in gray.\nTextField\n      antiAliasType : String\nThe type of anti-aliasing used for this text field.\nTextField\n      autoSize : String\nControls automatic sizing and alignment of text fields.\nTextField\n      background : Boolean\nSpecifies whether the text field has a background fill.\nTextField\n      backgroundColor : uint\nThe color of the text field background.\nTextField\n      border : Boolean\nSpecifies whether the text field has a border.\nTextField\n      borderColor : uint\nThe color of the text field border.\nTextField\n      bottomScrollV : int\n[read-only] An integer (1-based index) that indicates the bottommost line that is currently visible in the specified text field.\nTextField\n      caretIndex : int\n[read-only] The index of the insertion point (caret) position.\nTextField\n      condenseWhite : Boolean\nA Boolean value that specifies whether extra white space (spaces, line breaks, and so on) in a text field with HTML text is removed.\nTextField\n      defaultTextFormat : flash.text:TextFormat\nSpecifies the format applied to newly inserted text, such as text entered by a user or text inserted with the replaceSelectedText() method.\nTextField\n      displayAsPassword : Boolean\nSpecifies whether the text field is a password text field.\nTextField\n      embedFonts : Boolean\nSpecifies whether to render by using embedded font outlines.\nTextField\n      gridFitType : String\nThe type of grid fitting used for this text field.\nTextField\n      htmlText : String\nContains the HTML representation of the text field contents.\nTextField\n      length : int\n[read-only] The number of characters in a text field.\nTextField\n      maxChars : int\nThe maximum number of characters that the text field can contain, as entered by a user.\nTextField\n      maxScrollH : int\n[read-only] The maximum value of scrollH.\nTextField\n      maxScrollV : int\n[read-only] The maximum value of scrollV.\nTextField\n      mouseWheelEnabled : Boolean\nA Boolean value that indicates whether Flash Player automatically scrolls multiline text fields when the user clicks a text field and rolls the mouse wheel.\nTextField\n      multiline : Boolean\nIndicates whether field is a multiline text field.\nTextField\n      numLines : int\n[read-only] Defines the number of text lines in a multiline text field.\nTextField\n      restrict : String\nIndicates the set of characters that a user can enter into the text field.\nTextField\n      scrollH : int\nThe current horizontal scrolling position.\nTextField\n      scrollV : int\nThe vertical position of text in a text field.\nTextField\n      selectable : Boolean\nA Boolean value that indicates whether the text field is selectable.\nTextField\n      selectionBeginIndex : int\n[read-only] The zero-based character index value of the first character in the current selection.\nTextField\n      selectionEndIndex : int\n[read-only] The zero-based character index value of the last character in the current selection.\nTextField\n      sharpness : Number\nThe sharpness of the glyph edges in this text field.\nTextField\n      styleSheet : StyleSheet\nAttaches a style sheet to the text field.\nTextField\n      text : String\nA string that is the current text in the text field.\nTextField\n      textColor : uint\nThe color of the text in a text field, in hexadecimal format.\nTextField\n      textHeight : Number\n[read-only] The height of the text in pixels.\nTextField\n      textInteractionMode : String\n[read-only] The interaction mode property, Default value is TextInteractionMode.NORMAL.\nTextField\n      textWidth : Number\n[read-only] The width of the text in pixels.\nTextField\n      thickness : Number\nThe thickness of the glyph edges in this text field.\nTextField\n      type : String\nThe type of the text field.\nTextField\n      useRichTextClipboard : Boolean\nSpecifies whether to copy and paste the text formatting along with the text.\nTextField\n      wordWrap : Boolean\nA Boolean value that indicates whether the text field has word wrap.\nTextField";
        myTextField.border=true;
        myTextField.width=myTextField.height=300;
        addChild(myTextField);
    Thanks.

    I have this bug on Galaxy Nexus Android 4.3, I don't have this bug on Galaxy S Android 2.3, the bug occurs with the new Google Keyboard 3.0
    the app descriptor
    <?xml version="1.0" encoding="utf-8" standalone="no"?>
    <application xmlns="http://ns.adobe.com/air/application/4.0">
    <!-- Adobe AIR Application Descriptor File Template.
              Specifies parameters for identifying, installing, and launching AIR applications.
              xmlns - The Adobe AIR namespace: http://ns.adobe.com/air/application/3.5
                                  The last segment of the namespace specifies the version
                                  of the AIR runtime required for this application to run.
              minimumPatchLevel - The minimum patch level of the AIR runtime required to run
                                  the application. Optional.
    -->
              <!-- A universally unique application identifier. Must be unique across all AIR applications.
              Using a reverse DNS-style name as the id is recommended. (Eg. com.example.ExampleApplication.) Required. -->
              <id>TextFieldFB</id>
              <!-- Used as the filename for the application. Required. -->
              <filename>TextFieldFB</filename>
              <!-- The name that is displayed in the AIR application installer.
              May have multiple values for each language. See samples or xsd schema file. Optional. -->
              <name>TextFieldFB</name>
              <!-- A string value of the format <0-999>.<0-999>.<0-999> that represents application version which can be used to check for application upgrade.
              Values can also be 1-part or 2-part. It is not necessary to have a 3-part value.
              An updated version of application must have a versionNumber value higher than the previous version. Required for namespace >= 2.5 . -->
              <versionNumber>0.0.1</versionNumber>
              <!-- A string value (such as "v1", "2.5", or "Alpha 1") that represents the version of the application, as it should be shown to users. Optional. -->
              <!-- <versionLabel></versionLabel> -->
              <!-- Description, displayed in the AIR application installer.
              May have multiple values for each language. See samples or xsd schema file. Optional. -->
              <!-- <description></description> -->
              <!-- Copyright information. Optional -->
              <!-- <copyright></copyright> -->
              <!-- Publisher ID. Used if you're updating an application created prior to 1.5.3 -->
              <!-- <publisherID></publisherID> -->
              <!-- Settings for the application's initial window. Required. -->
              <initialWindow>
                        <!-- The main SWF or HTML file of the application. Required. -->
                        <!-- Note: In Flash Builder, the SWF reference is set automatically. -->
                        <content>[Cette valeur sera remplacée par Flash Builder dans le fichier app.xml de sortie]</content>
                        <!-- The title of the main window. Optional. -->
                        <!-- <title></title> -->
                        <!-- The type of system chrome to use (either "standard" or "none"). Optional. Default standard. -->
                        <!-- <systemChrome></systemChrome> -->
                        <!-- Whether the window is transparent. Only applicable when systemChrome is none. Optional. Default false. -->
                        <!-- <transparent></transparent> -->
                        <!-- Whether the window is initially visible. Optional. Default false. -->
                        <!-- <visible></visible> -->
                        <!-- Whether the user can minimize the window. Optional. Default true. -->
                        <!-- <minimizable></minimizable> -->
                        <!-- Whether the user can maximize the window. Optional. Default true. -->
                        <!-- <maximizable></maximizable> -->
                        <!-- Whether the user can resize the window. Optional. Default true. -->
                        <!-- <resizable></resizable> -->
                        <!-- The window's initial width in pixels. Optional. -->
                        <!-- <width></width> -->
                        <!-- The window's initial height in pixels. Optional. -->
                        <!-- <height></height> -->
                        <!-- The window's initial x position. Optional. -->
                        <!-- <x></x> -->
                        <!-- The window's initial y position. Optional. -->
                        <!-- <y></y> -->
                        <!-- The window's minimum size, specified as a width/height pair in pixels, such as "400 200". Optional. -->
                        <!-- <minSize></minSize> -->
                        <!-- The window's initial maximum size, specified as a width/height pair in pixels, such as "1600 1200". Optional. -->
                        <!-- <maxSize></maxSize> -->
            <!-- The aspect ratio of the app ("portrait" or "landscape" or "any"). Optional. Mobile only. Default is the natural orientation of the device -->
            <!-- <aspectRatio></aspectRatio> -->
            <!-- Whether the app will begin auto-orienting on launch. Optional. Mobile only. Default false -->
            <!-- <autoOrients></autoOrients> -->
            <!-- Whether the app launches in full screen. Optional. Mobile only. Default false -->
            <!-- <fullScreen></fullScreen> -->
            <!-- The render mode for the app (either auto, cpu, gpu, or direct). Optional. Default auto -->
            <!-- <renderMode></renderMode> -->
            <!-- Whether the default direct mode rendering context allocates storage for depth and stencil buffers.  Optional.  Default false. -->
            <!-- <depthAndStencil></depthAndStencil> -->
                        <!-- Whether or not to pan when a soft keyboard is raised or lowered (either "pan" or "none").  Optional.  Defaults "pan." -->
                        <!-- <softKeyboardBehavior></softKeyboardBehavior> -->
                        <!-- Display Resolution for the app (either "standard" or "high"). Optional, OSX-only. Default "standard" -->
                        <!-- <requestedDisplayResolution></requestedDisplayResolution> -->
              <autoOrients>true</autoOrients>
            <fullScreen>false</fullScreen>
            <visible>true</visible>
        </initialWindow>
              <!-- We recommend omitting the supportedProfiles element, -->
              <!-- which in turn permits your application to be deployed to all -->
              <!-- devices supported by AIR. If you wish to restrict deployment -->
              <!-- (i.e., to only mobile devices) then add this element and list -->
              <!-- only the profiles which your application does support. -->
              <!-- <supportedProfiles>desktop extendedDesktop mobileDevice extendedMobileDevice</supportedProfiles> -->
              <!-- Languages supported by application -->
              <!-- Only these languages can be specified -->
              <!-- <supportedLanguages>en de cs es fr it ja ko nl pl pt ru sv tr zh</supportedLanguages> -->
              <!-- The subpath of the standard default installation location to use. Optional. -->
              <!-- <installFolder></installFolder> -->
              <!-- The subpath of the Programs menu to use. (Ignored on operating systems without a Programs menu.) Optional. -->
              <!-- <programMenuFolder></programMenuFolder> -->
              <!-- The icon the system uses for the application. For at least one resolution,
              specify the path to a PNG file included in the AIR package. Optional. -->
              <!-- <icon>
                        <image16x16></image16x16>
                        <image29x29></image29x29>
                        <image32x32></image32x32>
                        <image36x36></image36x36>
                        <image40x40></image40x40>
                        <image48x48></image48x48>
                        <image50x50></image50x50>
                        <image57x57></image57x57>
                        <image58x58></image58x58>
                        <image72x72></image72x72>
                        <image76x76></image76x76>
                        <image80x80></image80x80>
                        <image96x96></image96x96>
                        <image100x100></image100x100>
                        <image114x114></image114x114>
                        <image120x120></image120x120>
                        <image128x128></image128x128>
                        <image144x144></image144x144>
                        <image152x152></image152x152>
                        <image512x512></image512x512>
                        <image732x412></image732x412>
                        <image1024x1024></image1024x1024>
              </icon> -->
              <!-- Whether the application handles the update when a user double-clicks an update version
              of the AIR file (true), or the default AIR application installer handles the update (false).
              Optional. Default false. -->
              <!-- <customUpdateUI></customUpdateUI> -->
              <!-- Whether the application can be launched when the user clicks a link in a web browser.
              Optional. Default false. -->
              <!-- <allowBrowserInvocation></allowBrowserInvocation> -->
              <!-- Listing of file types for which the application can register. Optional. -->
              <!-- <fileTypes> -->
                        <!-- Defines one file type. Optional. -->
                        <!-- <fileType> -->
                                  <!-- The name that the system displays for the registered file type. Required. -->
                                  <!-- <name></name> -->
                                  <!-- The extension to register. Required. -->
                                  <!-- <extension></extension> -->
                                  <!-- The description of the file type. Optional. -->
                                  <!-- <description></description> -->
                                  <!-- The MIME content type. -->
                                  <!-- <contentType></contentType> -->
                                  <!-- The icon to display for the file type. Optional. -->
                                  <!-- <icon>
                                            <image16x16></image16x16>
                                            <image32x32></image32x32>
                                            <image48x48></image48x48>
                                            <image128x128></image128x128>
                                  </icon> -->
                        <!-- </fileType> -->
              <!-- </fileTypes> -->
        <!-- iOS specific capabilities -->
              <!-- <iPhone> -->
                        <!-- A list of plist key/value pairs to be added to the application Info.plist -->
                        <!-- <InfoAdditions>
                <![CDATA[
                    <key>UIDeviceFamily</key>
                    <array>
                        <string>1</string>
                        <string>2</string>
                    </array>
                    <key>UIStatusBarStyle</key>
                    <string>UIStatusBarStyleBlackOpaque</string>
                    <key>UIRequiresPersistentWiFi</key>
                    <string>YES</string>
                ]]>
            </InfoAdditions> -->
            <!-- A list of plist key/value pairs to be added to the application Entitlements.plist -->
                        <!-- <Entitlements>
                <![CDATA[
                    <key>keychain-access-groups</key>
                    <array>
                        <string></string>
                        <string></string>
                    </array>
                ]]>
            </Entitlements> -->
              <!-- Display Resolution for the app (either "standard" or "high"). Optional. Default "standard" -->
              <!-- <requestedDisplayResolution></requestedDisplayResolution> -->
              <!-- Forcing Render Mode CPU for the devices mentioned. Optional  -->
              <!-- <forceCPURenderModeForDevices></forceCPURenderModeForDevices> -->
              <!-- File containing line separated list of external swf paths. These swfs won't be
              packaged inside the application and corresponding stripped swfs will be output in
              externalStrippedSwfs folder. -->
              <!-- <externalSwfs></externalSwfs> -->
              <!-- </iPhone> -->
              <!-- Specify Android specific tags that get passed to AndroidManifest.xml file. -->
        <!--<android> -->
        <!--          <manifestAdditions>
                        <![CDATA[
                                  <manifest android:installLocation="auto">
                                            <uses-permission android:name="android.permission.INTERNET"/>
                                            <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
                                            <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
                                            <uses-feature android:required="true" android:name="android.hardware.touchscreen.multitouch"/>
                                            <application android:enabled="true">
                                                      <activity android:excludeFromRecents="false">
                                                                <intent-filter>
                                                                          <action android:name="android.intent.action.MAIN"/>
                                                                          <category android:name="android.intent.category.LAUNCHER"/>
                                                                </intent-filter>
                                                      </activity>
                                            </application>
                </manifest>
                        ]]>
            </manifestAdditions> -->
                  <!-- Color depth for the app (either "32bit" or "16bit"). Optional. Default 16bit before namespace 3.0, 32bit after -->
            <!-- <colorDepth></colorDepth> -->
            <!-- Indicates if the app contains video or not. Necessary for ordering of video planes with graphics plane, especially in Jellybean - if you app does video this must be set to true - valid values are true or false -->
            <!-- <containsVideo></containsVideo> -->
        <!-- </android> -->
              <!-- End of the schema for adding the android specific tags in AndroidManifest.xml file -->
    <android>
            <manifestAdditions><![CDATA[
                                  <manifest android:installLocation="auto">
                                      <!--See the Adobe AIR documentation for more information about setting Google Android permissions-->
                                      <!--La suppression de l’autorisation android.permission.INTERNET aura comme effet secondaire
                        de vous empêcher de déboguer l’application sur le périphérique.-->
                                      <!--<uses-permission android:name="android.permission.INTERNET"/>-->
                                      <!--<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>-->
                                      <!--<uses-permission android:name="android.permission.READ_PHONE_STATE"/>-->
                                      <!--<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>-->
                                      <!--Les autorisations DISABLE_KEYGUARD et WAKE_LOCK doivent être permutées
                        afin d’accéder aux API SystemIdleMode d’AIR.-->
                                      <!--<uses-permission android:name="android.permission.DISABLE_KEYGUARD"/>-->
                                      <!--<uses-permission android:name="android.permission.WAKE_LOCK"/>-->
                                      <!--<uses-permission android:name="android.permission.CAMERA"/>-->
                                      <!--<uses-permission android:name="android.permission.RECORD_AUDIO"/>-->
                                      <!--Les autorisations ACCESS_NETWORK_STATE et ACCESS_WIFI_STATE doivent être
                        permutées afin d’utiliser les API NetworkInfo d’AIR.-->
                                      <!--<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>-->
                                      <!--<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>-->
                                  </manifest>
                        ]]></manifestAdditions>
        </android>
        <iPhone>
            <InfoAdditions><![CDATA[
                                  <key>UIDeviceFamily</key>
                                  <array>
                                            <string>1</string>
                                            <string>2</string>
                                  </array>
                        ]]></InfoAdditions>
            <requestedDisplayResolution>high</requestedDisplayResolution>
        </iPhone>
    </application>

  • How to increment a value in a textfield based on page number

    Hi,
    I am doing PDF based print forms which is non interactive, i got a requirment where i have to increment the binded value of a text field based on page number.
    presently i am using this code in initialize event of that textfield.
    var curpage = $layout.page ( ref ( $ ) )
    var totpages = $layout.pageCount()
    $.rawValue = $.rawValue - totpages
    $.rawValue = $.rawValue + curpage
    but this is not helping me, can anyone help me regarding this

    Thanks for yor reply.please you can tellme clearly how to set use 'NQ_SESSION.USER' to set the value to logged in User.i.e i have circle table in that users and circle names will be there.it is teradata database.so how can i set that in to the dashboard prompt and one thing along with that prompt the follwing prompts will be there
    mobile no<>
    date<>
    circle name<"user">
    this is my requirement so please help me step by step what to do for achiving this.
    thanking oyu

  • How can I set a gap in a JTextField, before the active Textfield starts?

    Hi,
    how can I set a gap in a JTextField, before the active Textfield starts?
    I'll avoid, that the input text starts immediately after the border of the JTextField.
    Btw, how can I set the height of the JTextField in a BoxLayout?
    Thx.
    Hans

    Yes, that was also my thinking, but nothing happens.
    Maybe You have an idea :-)
    Thx, Hans
    Here a part of my code:
      private JPanel createEntry(String label, JTextField jtf, String initJtf, boolean editable) {
        jtf.setColumns(15);
        if (editable) {
          jtf.setEditable(true);
          jtf.setBackground(new Color(191, 191, 255));
        else {
          jtf.setEditable(false);
          jtf.setBackground(SystemColor.control);
        jtf.setText(initJtf);
        jtf.setForeground(Color.black);
        jtf.setBorder(BorderFactory.createLoweredBevelBorder());
        jtf.setMargin(new Insets(50, 20, 50, 40));   // <-  The PROBLEM
        JPanel panel = new JPanel();
        GridLayout gl = new GridLayout(1, 2);
        gl.setHgap(1);
        panel.setLayout(gl);
        panel.add(BxpCdmUtils.Utils.createLabel(label, Color.darkGray, Font.BOLD, 11));
        panel.add(jtf);
        JPanel superpanel = new JPanel();
        superpanel.setLayout(new BoxLayout(superpanel, BoxLayout.X_AXIS));
        superpanel.add(panel);
        superpanel.add(new JLabel(" "));
        return superpanel;
      }

  • No border in cl_gui_docking_container

    Hi. I have a progrm:
    DATA:
    docking TYPE REF TO cl_gui_docking_container,
    picture_control_1 TYPE REF TO cl_gui_picture,
    url(256) TYPE c .
    PARAMETERS: p_dummy TYPE c .
    AT SELECTION-SCREEN OUTPUT.
    PERFORM show_pic.
    START-OF-SELECTION.
    *& Form show_pic
    FORM show_pic.
    DATA: repid LIKE sy-repid.
    DATA: file_name LIKE sapb-sapfiles,
    file_type LIKE bdn_con-mimetype.
    repid = sy-repid.
    IF docking IS INITIAL .
    CREATE OBJECT docking
    EXPORTING
    repid = repid
    dynnr = sy-dynnr
    side = cl_gui_docking_container=>dock_at_right
    extension = '200'
    EXCEPTIONS
    cntl_error = 1
    cntl_system_error = 2
    create_error = 3
    lifetime_error = 4
    lifetime_dynpro_dynpro_link = 5.
    CREATE OBJECT picture_control_1 EXPORTING parent = docking.
    CHECK sy-subrc = 0.
    CALL FUNCTION 'DP_PUBLISH_WWW_URL'
    EXPORTING
    objid = 'HTMLCNTL_TESTHTM2_SAP_AG'
    lifetime = 'T'
    IMPORTING
    url = url
    EXCEPTIONS
    OTHERS = 1.
    * Load the picture by using the url generated by the data provider.
    IF sy-subrc = 0.
    CALL METHOD picture_control_1->load_picture_from_url_async
    EXPORTING
    url = url.
    ENDIF.
    ENDIF .
    ENDFORM. "show_pic
    The docking container appears with border. Could You tell me how to remove that border? Greetings. P.

    Not sure you can remove it completely... you can make it smaller with the following (see the "l_style" setting):
    data:
      go_docking            type ref to cl_gui_docking_container,
      go_picture_control_1  type ref to cl_gui_picture,
      url(256)              type c .
    parameters:
      p_dummy               type c .
    at selection-screen output.
      perform show_pic.
    *&      Form  show_pic
    form show_pic.
      data:
        l_style            type i,
        l_repid            like sy-repid.
      l_repid = sy-repid.
    *" Create docking container for image
      if not go_docking is bound.
    *" Set the style we want:
    *" Inside the cl_gui_docking_container it defaults the following for
    *" Style, if nothing is set by caller:
    *    l_style = cl_gui_control=>ws_child
    *            + cl_gui_control=>ws_thickframe
    *            + cl_gui_control=>ws_border
    *            + cl_gui_control=>ws_visible.
    *" So let's remove one or two of these:
        l_style = cl_gui_control=>ws_child
    *"          + cl_gui_control=>ws_thickframe  "Take this out
    *"          + cl_gui_control=>ws_border      "And this too
                + cl_gui_control=>ws_visible.
        create object go_docking
          exporting
            repid                       = l_repid
            dynnr                       = sy-dynnr
            side                   = cl_gui_docking_container=>dock_at_right
            extension                   = '200'
            style                       = l_style
          exceptions
            cntl_error                  = 1
            cntl_system_error           = 2
            create_error                = 3
            lifetime_error              = 4
            lifetime_dynpro_dynpro_link = 5.
        create object go_picture_control_1
          exporting
            parent = go_docking.
        check sy-subrc is initial.
        call function 'DP_PUBLISH_WWW_URL'
          exporting
            objid    = 'HTMLCNTL_TESTHTM2_SAP_AG'
            lifetime = 'T'
          importing
            url      = url
          exceptions
            others   = 1.
    * Load the picture by using the url generated by the data provider.
        if sy-subrc is initial.
          call method go_picture_control_1->load_picture_from_url_async
            exporting
              url = url.
        endif.
      endif .
    endform. "show_pic

  • Howto: Display text in the border line of the JPanel

    I create a JPanel and set it's border, later i add a textField at the border line of the JPanel, but when the words i type in, the line of border still at the center of the textField. Pls Help

    try this:
    import javax.swing.border.*;
    TitledBorder myBorder = new TitledBorder(" my Title ");
    myPanel.setBorder(myBorder);
    null

Maybe you are looking for

  • ITunes sending at least -20db to airport express after security update

    Hi all, did anyone notice anything strange after this week's security update? My airport express is conected to a receiver and the volume was ok, 65w per channel and a pair of decent JBL speakers. Now i need to set up my receiver to 0 db (maximum vol

  • Files made from one template don't all render the same

    I have made a template using a table layout, and created all the site pages from the template.   When viewed in a browser, some (not all) of the pages jump slightly to the side.  Compare these 2 pages, or click through the navbar menu and you will se

  • Want to change my server incoming mail, how?

    Want to change my server incoming mail, how?

  • Rounded toolbar Search box in WebHelp?

    The powers that be want a help facelift... One request is a search box with round ends. Preferably with the Search button inside the box, much like what Apple does in Safari etc. Any hints on what file(s) to edit and how? A ready made piece of code w

  • Crystal report viewer suppressing pages

    I have a crystal 8.5 report that is group by: - report type    - name      - contract number        -date detail                                    -date footer (suppressed)    - contract footer - name footer (suppressed) - report type footer (suppre