# Access coloring by smproperties.xml in Python Plugin

**URL:** https://discourse.paraview.org/t/access-coloring-by-smproperties-xml-in-python-plugin/5124
**Category:** ParaView Support
**Tags:** python
**Created:** [August 18, 2020, 7:00am UTC](https://discourse.paraview.org/t/access-coloring-by-smproperties-xml-in-python-plugin/5124 "2020-08-18T07:00:29Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Fabian\_Mueller](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/f/35a633/32.png) [@Fabian\_Mueller](https://discourse.paraview.org/u/Fabian_Mueller)
#### Post date: [August 18, 2020, 7:00am UTC](https://discourse.paraview.org/t/access-coloring-by-smproperties-xml-in-python-plugin/5124/1 "2020-08-18T07:00:29Z")

</div>

Dear Paraview Developpers,

I wrote a Python Plugin to visualize solutions of our inhouse FE-software. Everything works fine and now I’m implementing some comfort features for my colleagues, such as which output should be visible after loading the data. Consecutively, I want to set the coloring of an output from “Solid Color” to “Material”.

The smproperties.xml looks at the moment like this, but I can’t figure out how to access the Coloring.  
Thanks for your time and help.  
Yours sincerely,  
Fabian Müller

* * *

@smproperty.xml(’’’

```
<OutputPort index="0" name="Mesh" > </OutputPort>
<OutputPort index="1" name="Outline" > </OutputPort>
<OutputPort index="2" name="Materials" > </OutputPort>
<OutputPort index="3" name="Boundaries" > </OutputPort>
<OutputPort index="4" name="Vector Potential (2D)" > </OutputPort>
<OutputPort index="5" name="Flux Density" > </OutputPort>
<Hints>
<!-- Which Views should be active on default -->
<RepresentationType view="RenderView" type="Surface With Edges" port="0" />
<RepresentationType view="RenderView" type="Wireframe" coloring="Material" port="1" />
<!-- ColoringType ColorByArrayComponent="Material" port=1 / -->
<!-- ColorArrayName name="Materials" port="1" / -->
<View type="None" port="2" />
<View type="None" port="3" />
<View type="None" port="4" />
<View type="None" port="5" />
</Hints>
''')
```

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [August 31, 2020, 9:30am UTC](https://discourse.paraview.org/t/access-coloring-by-smproperties-xml-in-python-plugin/5124/2 "2020-08-31T09:30:34Z")

</div>

> [@Fabian\_Mueller](#):
>
> `coloring=`

This is not supported afaik.  
[https://kitware.github.io/paraview-docs/latest/cxx/ProxyHints.html](https://kitware.github.io/paraview-docs/latest/cxx/ProxyHints.html)

---

<div class="post-metadata">

### Author: ![Fabian\_Mueller](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/f/35a633/32.png) [@Fabian\_Mueller](https://discourse.paraview.org/u/Fabian_Mueller)
#### Post date: [September 8, 2020, 6:28am UTC](https://discourse.paraview.org/t/access-coloring-by-smproperties-xml-in-python-plugin/5124/3 "2020-09-08T06:28:25Z")

</div>

Dear Mr. Westphal,

thanks for your answer. I wrote a workaround by using the smproperty in a first step for the rendering types and in a consecutive step I now use a python macro to color everything as I wish too.

Yours sincerely,  
Fabian Müller
