• 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. Allegro X Scripting - Skill
  3. about lines startend points

Stats

  • Replies 17
  • Subscribers 17
  • Views 14712
  • Members are here 0
More Content

about lines startend points

tennywhy
tennywhy over 7 years ago

i want get all lines start and end points on outline layer, there is the code

defun( apl ()
    let( (RLP symbPg symbPth allSymbols allSymbolss)
    ;print all lines startend point
    axlSetFindFilter(?enabled list("noall" "lines")
        ?onButtons list("noall" "lines"))
    allSymbols = axlGetSelSet(axlAddSelectAll())
    axlClearSelSet()
    foreach( everyLine allSymbols
            axlMsgPut("startis %L" everyLine->startEnd) ; it doesnt work
            ;axlMsgPut("startis %L" everyLine->?) ;checked it has startEnd properties
            ;axlMsgPut("startis %L" everyLine->??) ;checked it has startEnd properties  
            )
 ))

what's the right way ?  and in the skill UG there is a starEnd attribute as in image below. how could i do it ?

  • Cancel
  • Sign in to reply
Parents
  • eDave
    eDave over 7 years ago

    startEnd is and attribute of a line segment - not the symbol itself.

    use something like

    foreach(symbol, allSymbols

      foreach(pathObj setof(obj, symbol ->children, obj ->objType == "path")

        foreach(segment, pathObj, ends = segment ->startEnd

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • tennywhy
    tennywhy over 7 years ago in reply to eDave

    hi dave very appreciate your reply.  i tried it ,  it cant work. it's seem as there is no children attibutes, and there is no children attibutes in line attributes shown in the image above.

    i tried other attributes in the line attributes table also , cant get work still.  could you give me some moer advice please ? i have stucked here several days

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • tennywhy
    tennywhy over 7 years ago in reply to eDave

    its get work, thank you very much Dave.  i have two question reserved.

    one; how do you kown it has a segments attributions, i check the skill UG, it just as the image i post above there arent a segments attributions in the list, where can find the explain about this?    

    two: what's the different between  ->? and ->??   ?

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • eDave
    eDave over 7 years ago in reply to tennywhy

    1. Refer to the Allegro Skill Reference (algroskill.pdf) Path Attributes.

    2. ->? returns a list of the names. ->?? returns the list of names and values (much more useful usually)

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Jason Hsu
    Jason Hsu over 6 years ago in reply to eDave

    Hi Dave,

      Do you know how to get the width for path? I want to know the width of lines on "PACKAGE GEOMETRY/ASSEMBLY_TOP". But the line's objType is path. you know only line has width attribute, how could I get the information for path? Please give me your suggestion. Thanks in advance.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Jason Hsu
    Jason Hsu over 6 years ago in reply to eDave

    It seems I can get the width by car(myline->segments) ->width, is it correct? Or it is detour way?

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • eDave
    eDave over 6 years ago in reply to Jason Hsu

    axlPathGetWidth or axlPathSegGetWidth

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Reply
  • eDave
    eDave over 6 years ago in reply to Jason Hsu

    axlPathGetWidth or axlPathSegGetWidth

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Children
  • Jason Hsu
    Jason Hsu over 6 years ago in reply to eDave

    Dave,

      axlPathGetWidth or axlPathSegGetWidth require a r_path parameter, it means _axlPath@. But here, I can get many lines(path) from an existing layer. It will be dbid: -number format. It seems I can't use axlPathGetWidth or axlPathSegGetWidth to get the width's information directly. Any other idea from you? Or I have to use car( myline ->segments) ->width? Thanks for your help.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • eDave
    eDave over 6 years ago in reply to Jason Hsu

    Just get the width attribute of the line segments. If your line dbid is lineDBID then car(lineDBID ->segments) ->width will give you a value

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Cadence Guidelines

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