<table><tr><td style="">tobiasdeiminger added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D13203">View Revision</a></tr></table><br /><div><div><blockquote style="border-left: 3px solid #8C98B8;
          color: #6B748C;
          font-style: italic;
          margin: 4px 0 12px 0;
          padding: 8px 12px;
          background-color: #F8F9FC;">
<div style="font-style: normal;
          padding-bottom: 4px;">In <a href="https://phabricator.kde.org/D13203#270910" style="background-color: #e7e7e7;
          border-color: #e7e7e7;
          border-radius: 3px;
          padding: 0 4px;
          font-weight: bold;
          color: black;text-decoration: none;">D13203#270910</a>, <a href="https://phabricator.kde.org/p/dileepsankhla/" style="
              border-color: #f1f7ff;
              color: #19558d;
              background-color: #f1f7ff;
                border: 1px solid transparent;
                border-radius: 3px;
                font-weight: bold;
                padding: 0 4px;">@dileepsankhla</a> wrote:</div>
<div style="margin: 0;
          padding: 0;
          border: 0;
          color: rgb(107, 116, 140);"><p>In ui/pagepainter.cpp L 668, we can comment out <tt style="background: #ebebeb; font-size: 13px;">acolor.setAlpha( opacity )</tt> as here the value of opacity is 255 but changing the L 659 or 668 should be consistent in the case of other annotations too. Is commenting out L 668 accepted?</p></div>
</blockquote>

<p>Hm, if you just comment L.668, how would you control transparency of ordinary inline notes and popup notes? Preferably without changing the look of existing annotations created in earlier Okular versions?</p>

<p>Let's reconsider. We have two transparency parameters for each annotation:</p>

<ul class="remarkup-list">
<li class="remarkup-list-item">Alpha channel of QColor Style::color</li>
<li class="remarkup-list-item">double Style::opacity</li>
</ul>

<p>Sadly it seems like PagePainter and Poppler currently have different interpretations of those two values:</p>

<ul class="remarkup-list">
<li class="remarkup-list-item">Poppler: Use alpha channel of Style::color to control transparency of background color. Use Style::opacity to control transparency of the whole appearance=border+background+font.</li>
<li class="remarkup-list-item">PagePainter: Ignore alpha channel of Style::color. Use Style::opacity to control transparency of background color. No way to control transparency of the whole appearance=border+background+font.</li>
</ul>

<p>This is a inconsistent. I think we could either fix this inconsistency in Poppler or PagePainter (more effort), or hardcode some kind of</p>

<div class="remarkup-code-block" style="margin: 12px 0;" data-code-lang="text" data-sigil="remarkup-code-block"><pre class="remarkup-code" style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; padding: 12px; margin: 0; background: rgba(71, 87, 120, 0.08);">if ( inplaceIntent == Okular::TextAnnotation::InplaceIntent ) acolor.setAlpha(0);</pre></div>

<p>in PagePainter.</p>

<p>Any other ideas?</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R223 Okular</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D13203">https://phabricator.kde.org/D13203</a></div></div><br /><div><strong>To: </strong>dileepsankhla<br /><strong>Cc: </strong>ltoscano, ngraham, tobiasdeiminger, aacid, okular-devel<br /></div>