• 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 PCB Editor
  3. drawing text with skill function

Stats

  • Replies 14
  • Subscribers 163
  • Views 16365
  • Members are here 0
More Content

drawing text with skill function

skillnewbie
skillnewbie over 16 years ago

Hi,

I have been wanting to draw some text in my mcm layout.

as far as i understand, the axlDBCreateText function will require user to allocate

a textblock for the text to be created. but I want to make the text independent of

any textblock...

i thought of converting the text to lines (after it is created) but it seems not possible,

and (correct me if i am wrong) the axlGPRDrwText can only draw the text on the forms.

anyone can help? thanks in advance =)

 

 

  • Sign in to reply
  • Cancel
  • PCB Librarian
    PCB Librarian over 15 years ago

    Hi,

    I have a skill where to view the max & min component height (the skill will showing the max value only). I want to modify the skill where to have the output as MAX_HEIGHT = 'value' height (I need to have the text "MAX_HEIGHT=" before the max height value). Anybody can help me on this?

    show_height.il
    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • eDave
    eDave over 15 years ago

    Use something like:

    sprintf(myVar "MAX_HEIGHT = %2.3f", value)

    Regards,

    Dave

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • PCB Librarian
    PCB Librarian over 15 years ago

    Hi Dave,

    Thanks for u'r fast feedback. From this coding, it will print for MAX HEIGHT & MIN HEIGHT (it use sprintf(s_prop "%s", prop)) & will print the value only. I'm still new in CDS skill and I'm not very sure where is the correct place to make sure the output to have text with 'MAX_HEIGHT' & "MIN_HEIGHT" before the value by using u'r aabove advice:-(

    if( l_props!=nil

    then ;check to make sure there are attached properties.

    foreach( prop l_props ;step through each property

    sprintf(s_prop "%s", prop)

    if( s_prop == max

    then

    if( length(l_props)>2 ;Are both min and max defined?

    then

    max_ht=cadr(l_props->?)

    else

    max_ht=car(l_props->?)

    );endif length

     

    y=y1+max_offset

    if( shape->layer== place_top

    then

    axlDBCreateText( max_ht x:y txt_orient_top t_layer_top shape)

    else

    axlDBCreateText( max_ht x:y txt_orient_bot t_layer_bot shape)

    );endif layer

    else

    if( s_prop == min

    then

    shape_layer=shape->layer

    min_ht=car(l_props->?)

    y=y1+min_offset

    if( shape->layer == place_top

    then

    axlDBCreateText( min_ht x:y txt_orient_top t_layer_top shape)

    else

    axlDBCreateText( min_ht x:y txt_orient_bot t_layer_bot shape)

    );endif layer

    );end if prop min

    );end if prop max

    );end foreach

    );end if

    );end foreach

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • aCraig
    aCraig over 15 years ago

    Place a print statement where you find the height with the text for that height. So when you find MAX_HEIGHT do:

    axlMsgPut("MAX_HEIGHT = %s" s_prop)

    Then do the same for minimum height.

    - Craig

    • 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