ParentEdgeStyle

ParentEdgeStyle

Tree 及相关函数的一个选项,指定应为边设置何种样式.

更多信息

  • ParentEdgeStyle 允许指定树的根节点的父边的样式,以及与模式匹配的位置上任何子树的边的样式.
  • 可使用以下选项设置:
  • Automaticuse the automatic style
    styleuse style for the edge »
    Allstyleuse style for all edges »
    TreeCases[pattern]styleuse style for edges at nodes with data matching pattern »
    "Leaves"styleuse style for edges at leaves »
    "NonLeaves"styleuse style for edges at non-leaves »
    {pos1style1,pos2style2,}use stylei for the edge at relative position posi »
    {patt1lbl1,patt2lbl2,}use stylei for edges at positions matching the pattern patti »
  • 没有明确的 posstyle 边样式的子树被视为采用自动设置的样式.
  • ParentEdgeStyle 可用于线和面.
  • 请使用 Directive[style1,style2,] 指定多个样式指令.
  • 实际上按 ParentEdgeStyleParentEdgeStyleFunctionParentEdgeShapeFunction 的顺序应用边样式指定,后来的指定将覆盖前面的指定.

范例

打开所有单元关闭所有单元

基本范例  (4)

设置一条边的样式:

指定一组边的样式:

所有的边都使用同样的样式:

Specify styles for the leaf and non-leaf edges:

范围  (2)

用位置模式指定位置:

用数据模式指定位置:

属性和关系  (4)

可通过位置指定边的样式:

子树指定的样式优先于其祖先指定的样式:

子树内的位置 {i,j,} 指代的是相对位置 {i,j,} 处的子树:

{1} 处的相对位置 {2} 指代的是全局位置 {1,2}

通常情况下,模式 patt 应用于与 patt 匹配的全局位置 {i,j,} 处的子树:

模式列表 {patt1,patt2,} 应用于与 patti 匹配的相对位置 {i,j,}

Wolfram Research (2022),ParentEdgeStyle,Wolfram 语言函数,https://reference.wolfram.com/language/ref/ParentEdgeStyle.html.

文本

Wolfram Research (2022),ParentEdgeStyle,Wolfram 语言函数,https://reference.wolfram.com/language/ref/ParentEdgeStyle.html.

CMS

Wolfram 语言. 2022. "ParentEdgeStyle." Wolfram 语言与系统参考资料中心. Wolfram Research. https://reference.wolfram.com/language/ref/ParentEdgeStyle.html.

APA

Wolfram 语言. (2022). ParentEdgeStyle. Wolfram 语言与系统参考资料中心. 追溯自 https://reference.wolfram.com/language/ref/ParentEdgeStyle.html 年

BibTeX

@misc{reference.wolfram_2025_parentedgestyle, author="Wolfram Research", title="{ParentEdgeStyle}", year="2022", howpublished="\url{https://reference.wolfram.com/language/ref/ParentEdgeStyle.html}", note=[Accessed: 02-February-2025 ]}

BibLaTeX

@online{reference.wolfram_2025_parentedgestyle, organization={Wolfram Research}, title={ParentEdgeStyle}, year={2022}, url={https://reference.wolfram.com/language/ref/ParentEdgeStyle.html}, note=[Accessed: 02-February-2025 ]}