Re: What should okular background color be

2017-08-09 Thread Oliver Sander
Can you please add 'okular' as reviewer (under Reviewers --> groups).  Because 
it is not on me
to decide whether this features is wanted at all.



smime.p7s
Description: S/MIME Cryptographic Signature


Re: What should okular background color be

2017-08-09 Thread Albert Freeman
https://git.reviewboard.kde.org/r/130219/

On 9 August 2017 at 22:23, Oliver Sander  wrote:
> Hi Albert,
>
> can you please upload the patch to
>
>https://git.reviewboard.kde.org/
>
> It is easier to review there.
>
> Thanks,
> Oliver
>
>


Re: What should okular background color be

2017-08-09 Thread Oliver Sander
Hi Albert,

can you please upload the patch to

   https://git.reviewboard.kde.org/

It is easier to review there.

Thanks,
Oliver




smime.p7s
Description: S/MIME Cryptographic Signature


Re: What should okular background color be

2017-08-08 Thread Albert Freeman
I did this because I wanted to be able to set black as the background color.

On 9 Aug. 2017 11:15 am, "Albert Freeman"  wrote:

> I have added the ability for the background color in okular to be changed
> via the settings, but currently what I have done is set the default
> background color to the RGB value of QPalette::Dark since I don't think it
> is a good idea to construct a QPalette in conf/okular.kcfg just to access
> QPalette::Dark which is what is used for the background color currently in
> okular .
>
> Is this okay, what should the background color be?
>
> diff --git a/conf/dlggeneralbase.ui b/conf/dlggeneralbase.ui
> index cf4ebca0..fe373a71 100644
> --- a/conf/dlggeneralbase.ui
> +++ b/conf/dlggeneralbase.ui
> @@ -7,7 +7,7 @@
>  0
>  0
>  558
> -575
> +632
> 
>
>
> @@ -120,7 +120,7 @@
> 
>  
>   
> -  Display file name only
> +  Display file name only
>   
>   
>true
> @@ -130,7 +130,7 @@
> 
>  
>   
> -  Display full file path
> +  Display full file path
>   
>   
>false
> @@ -141,6 +141,29 @@
>   
>  
>  
> + 
> +  
> +   6
> +  
> +  
> +   0
> +  
> +  
> +   
> +
> + Background color:
> +
> +
> + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
> +
> +   
> +  
> +  
> +   
> +  
> + 
> +
> +
>   
>
> 4
> @@ -319,7 +342,7 @@
>
> 
>  
> - Overview columns:
> + Overview columns:
>  
>  
>   Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
> @@ -345,7 +368,7 @@
>   Defines how much of the current viewing area will
> still be visible when pressing the Page Up/Down keys.
>  
>  
> - Page Up/Down overlap:
> + Page Up/Down overlap:
>  
>  
>   Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
> @@ -439,6 +462,13 @@ For files which were opened before the previous
> zoom is applied.
> 
>
>   
> + 
> +  
> +   KColorButton
> +   QPushButton
> +   kcolorbutton.h
> +  
> + 
>   
>kiconloader.h
>   
> diff --git a/conf/okular.kcfg b/conf/okular.kcfg
> index 69ea8cf6..07113f87 100644
> --- a/conf/okular.kcfg
> +++ b/conf/okular.kcfg
> @@ -290,6 +290,9 @@
>
> false
>
> +  
> +  QColor(136, 142, 147)
> +  
>   
>   
>
> diff --git a/ui/pageview.cpp b/ui/pageview.cpp
> index 3d935a2e..8c6ac3ca 100644
> --- a/ui/pageview.cpp
> +++ b/ui/pageview.cpp
> @@ -3416,7 +3416,7 @@ QList< Okular::RegularAreaRect * >
> PageView::textSelections( const QPoint& start
>
>  void PageView::drawDocumentOnPainter( const QRect & contentsRect,
> QPainter * p )
>  {
> -QColor backColor = viewport()->palette().color( QPalette::Dark );
> +QColor backColor = Okular::Settings::backgroundColor();
>
>  // when checking if an Item is contained in contentsRect, instead of
>  // growing PageViewItems rects (for keeping outline into account), we
>
>
>