title: How to sum values in xml?
body: <p>Suppose I have 2 dimension values defined in an XML file and want to define a 3rd value that is the sum of the other 2 values. Is there a way to do that in the XML file?</p>
  
  <p>Here is an illustration of what I would like to do.</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;resources&gt;
   &lt;dimen name="top_element_size"&gt;10dp&lt;/dimen&gt;
   &lt;dimen name="element_spacing"&gt;5dp&lt;/dimen&gt;
   &lt;dimen name="bottom_element_top"&gt;@dimen/top_element_size + @dimen/element_spacing&lt;/dimen&gt;
  &lt;/resources&gt;
  </code></pre>
  
  <p>And I would like to define <code>android:layout_marginTop="@dimen/bottom_element_top"</code> for the bottom element in a <code>frame</code> layout.
  But it appears that <code>@dimen/top_element_size + @dimen/element_spacing</code> is not legal.</p>