<div dir="ltr">Please review and let me know if you approve this.<br><br><div class="gmail_quote"><div dir="ltr">---------- Forwarded message ---------<br>From: Orhan Kavrakoğlu <<a href="mailto:notifications@github.com">notifications@github.com</a>><br>Date: Mon, Jun 1, 2015 at 4:55 AM<br>Subject: [mlt] Add a preferred-width attribute to kdenlivetitle text content properties (#78)<br>To: mltframework/mlt <<a href="mailto:mlt@noreply.github.com">mlt@noreply.github.com</a>><br></div><br><br><p>Would you be interested in such a solution for centered text? It's a requested feature:</p>

<p><a href="https://kdenlive.org/forum/title-template-aligning-doesnt-work" target="_blank">https://kdenlive.org/forum/title-template-aligning-doesnt-work</a><br>
<a href="https://kdenlive.org/forum/center-align-template-title" target="_blank">https://kdenlive.org/forum/center-align-template-title</a><br>
<a href="https://kdenlive.org/forum/template-documentation" target="_blank">https://kdenlive.org/forum/template-documentation</a></p>

<p>The current implementation sets the preferred width to be the text item's actual width (src/modules/qt/kdenlivetitle_wrapper.cpp:229), making center- and right-alignment meaningless unless the text is multiline. (When it <em>is</em> multiline, it merely aligns shorter lines according to the longest one)</p>

<p>With this change, you can set preferred-width="x" and it will act as though the text item had that width. Set x to the video's width and you can have perfectly centered (or right-aligned) titles.</p>

<hr>

<h4>You can view, comment on, or merge this pull request online at:</h4>
<p>  <a href="https://github.com/mltframework/mlt/pull/78" target="_blank">https://github.com/mltframework/mlt/pull/78</a></p>

<h4>Commit Summary</h4>
<ul>
  <li>Add a preferred-width attribute to kdenlivetitle text content properties so we can actually center text</li>
</ul>

<h4>File Changes</h4>
<ul>
  <li>
    <strong>M</strong>
    <a href="https://github.com/mltframework/mlt/pull/78/files#diff-0" target="_blank">src/modules/qt/kdenlivetitle_wrapper.cpp</a>
    (4)
  </li>
</ul>

<h4>Patch Links:</h4>
<ul>
  <li><a href="https://github.com/mltframework/mlt/pull/78.patch" target="_blank">https://github.com/mltframework/mlt/pull/78.patch</a></li>
  <li><a href="https://github.com/mltframework/mlt/pull/78.diff" target="_blank">https://github.com/mltframework/mlt/pull/78.diff</a></li>
</ul>

<p style="font-size:small;color:#666">—<br>Reply to this email directly or <a href="https://github.com/mltframework/mlt/pull/78" target="_blank">view it on GitHub</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/ABF_O7NzOztID959V6a3D-Hrx-EVW_kZks5oPD-3gaJpZM4EyvP3.gif" width="1"></p>
<div>
  <div>
    
    
  </div>
  
</div>

</div></div>