• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC SKILL
  3. Information areas in one-dimensional forms

Stats

  • Locked Locked
  • Replies 3
  • Subscribers 143
  • Views 13344
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Information areas in one-dimensional forms

skillprogramme
skillprogramme over 12 years ago

Hi all!

I want to create a simple forms with some fields and a text area providing some information to the user explaining what is about to happen. I want to keep my code as simple as possible and I am therefore using only one-dimensional form layout. However, I can't find a good field for displaying the information to the user. hiCreateOutputStringField() seems to have a defined size, irregardless of the number of newlines in the string provided as input. This leads to part of the string being impossible to see. A simple example:

theString = hiCreateOutputStringField( ?name gensym() ?value "a rather long\nstring with a\nlot of lineshifts\nfor illustration\nonly\n")
theForm = hiCreateAppForm( ?name gensym() ?fields list(theString) ?formTitle "A form")
hiDisplayForm(theForm)

I have tried hiCreateLabel with similar results. hiCreateMLTextField with "?editable nil" seems like a too big hack-around and doesn't look good. Is there a better field for doing what I want? I know it is possible to achieve this by using two dimensional forms, with the extra cost of having to define specific coordinates for every field, so I want to stick to one-dimensional ones. 
 
Best regards,
Max 

 

  • Cancel
Parents
  • skillUser
    skillUser over 12 years ago

    Hi Max,

    This is not too elegant, but as a quick hack it works - each line is converted into a single output string field and they are returned together as a list.  Note that other fields will need to be appended to this list, or otherwise combined in a new list (see append or nconc as possible examples)

    str = "a rather long\nstring with a\nlot of lineshifts\nfor illustration\nonly\n"
    strFields = foreach(mapcar strPiece parseString(str "\n")
        hiCreateOutputStringField(?name gensym('strPiece) ?value strPiece)
      )
    theForm = hiCreateAppForm( ?name gensym() ?fields strFields ?formTitle "A form")
    hiDisplayForm(theForm)
    

     Hopefully this helps?

    regards,

    Lawrence.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • skillUser
    skillUser over 12 years ago

    Hi Max,

    This is not too elegant, but as a quick hack it works - each line is converted into a single output string field and they are returned together as a list.  Note that other fields will need to be appended to this list, or otherwise combined in a new list (see append or nconc as possible examples)

    str = "a rather long\nstring with a\nlot of lineshifts\nfor illustration\nonly\n"
    strFields = foreach(mapcar strPiece parseString(str "\n")
        hiCreateOutputStringField(?name gensym('strPiece) ?value strPiece)
      )
    theForm = hiCreateAppForm( ?name gensym() ?fields strFields ?formTitle "A form")
    hiDisplayForm(theForm)
    

     Hopefully this helps?

    regards,

    Lawrence.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information