Discussion:
[Skim-app-users] Page background
Fran Calcraft
2015-05-28 18:02:18 UTC
Permalink
The instructions in the Skim Wiki for changing the page background
colour do not make much sense to me. This is the instruction:

Key : SKPageBackgroundColor
Values : -data, archived color, or an -array of -float
Explanation : Set this to change the default white background color of
pages. This can be an array of one to four floats between 0 and 1, or
data for an archived color.

I got everything entered into the Terminal for the setting, but using a
hexadecimal code for the background colour value did not do anything.
Presumably I misunderstood the meaning? What is an "archived color" anyway?

The colour I want for the background is #FFFF88. Is there any way to
get that? I did not use the "#" in front of the hex digits, since
Terminal treated that as an error.

------------------------------------------------------------------------------
Fran Calcraft
2015-05-28 18:08:44 UTC
Permalink
The instructions in the Skim Wiki for changing the page background
colour do not make much sense to me. This is the instruction:

Key : SKPageBackgroundColor
Values : -data, archived color, or an -array of -float
Explanation : Set this to change the default white background color of
pages. This can be an array of one to four floats between 0 and 1, or
data for an archived color.

I got everything entered into the Terminal for the setting, but using a
hexadecimal code for the background colour value did not do anything.
Presumably I misunderstood the meaning? What is an "archived color" anyway?

The colour I want for the background is #FFFF88. Is there any way to
get that? I did not use the "#" in front of the hex digits, since
Terminal treated that as an error.

This is not working properly. My message was simply returned to me?

------------------------------------------------------------------------------
Christiaan Hofman
2015-05-28 20:23:44 UTC
Permalink
Post by Fran Calcraft
The instructions in the Skim Wiki for changing the page background
Key : SKPageBackgroundColor
Values : -data, archived color, or an -array of -float
Explanation : Set this to change the default white background color of
pages. This can be an array of one to four floats between 0 and 1, or
data for an archived color.
I got everything entered into the Terminal for the setting, but using a
hexadecimal code for the background colour value did not do anything.
Presumably I misunderstood the meaning? What is an "archived color" anyway?
The colour I want for the background is #FFFF88. Is there any way to
get that? I did not use the "#" in front of the hex digits, since
Terminal treated that as an error.
An archived color is a a raw data representation of the AppKit color. But you would never be able to guess what this should be (you could perhaps copy it form some other value.)

Easiest is to use an array of floats, in your case -array -float 1 -float 1 -float 0.53333. You can also use AppleScript to set the page background color, then you can choose one using a color panel.

Christiaan
Fran Calcraft
2015-05-30 19:21:47 UTC
Permalink
This post might be inappropriate. Click to display it.
Christiaan Hofman
2015-05-31 20:54:08 UTC
Permalink
Post by Christiaan Hofman
Post by Fran Calcraft
The instructions in the Skim Wiki for changing the page background
Key : SKPageBackgroundColor
Values : -data, archived color, or an -array of -float
Explanation : Set this to change the default white background color of
pages. This can be an array of one to four floats between 0 and 1, or
data for an archived color.
I got everything entered into the Terminal for the setting, but using a
hexadecimal code for the background colour value did not do anything.
Presumably I misunderstood the meaning? What is an "archived color" anyway?
The colour I want for the background is #FFFF88. Is there any way to
get that? I did not use the "#" in front of the hex digits, since
Terminal treated that as an error.
An archived color is a a raw data representation of the AppKit color. But you would never be able to guess what this should be (you could perhaps copy it form some other value.)
Easiest is to use an array of floats, in your case -array -float 1 -float 1 -float 0.53333. You can also use AppleScript to set the page background color, then you can choose one using a color panel.
Christiaan
defaults write net.sourceforge.skim-app.skim SKPageBackgroundColor -array -float 1 -float 1 -float 0.53333
That does work for me. Are you sure you did this when Skim was not running?
I have no idea how to use Applescript. How do you specify the application it is to control? How is the background colour for all documents to be opened by that application controlled? The help I was able to find assumes some knowledge of Applescript to begin with, and I have none.
This sample script (open in AppleScript Editor.app) does it:


tell application "Skim"
set page background color to (choose color)
end tell


Christiaan
Fran Calcraft
2015-06-01 18:21:49 UTC
Permalink
Post by Christiaan Hofman
Post by Christiaan Hofman
Post by Fran Calcraft
The instructions in the Skim Wiki for changing the page background
Key : SKPageBackgroundColor
Values : -data, archived color, or an -array of -float
Explanation : Set this to change the default white background color of
pages. This can be an array of one to four floats between 0 and 1, or
data for an archived color.
I got everything entered into the Terminal for the setting, but using a
hexadecimal code for the background colour value did not do anything.
Presumably I misunderstood the meaning? What is an "archived color" anyway?
The colour I want for the background is #FFFF88. Is there any way to
get that? I did not use the "#" in front of the hex digits, since
Terminal treated that as an error.
An archived color is a a raw data representation of the AppKit color. But you would never be able to guess what this should be (you could perhaps copy it form some other value.)
Easiest is to use an array of floats, in your case -array -float 1 -float 1 -float 0.53333. You can also use AppleScript to set the page background color, then you can choose one using a color panel.
Christiaan
defaults write net.sourceforge.skim-app.skim SKPageBackgroundColor -array -float 1 -float 1 -float 0.53333
That does work for me. Are you sure you did this when Skim was not running?
I have no idea how to use Applescript. How do you specify the application it is to control? How is the background colour for all documents to be opened by that application controlled? The help I was able to find assumes some knowledge of Applescript to begin with, and I have none.
tell application "Skim"
set page background color to (choose color)
end tell
Christiaan
------------------------------------------------------------------------------
_______________________________________________
Skim-app-users mailing list
https://lists.sourceforge.net/lists/listinfo/skim-app-users
Maybe the file I was using to test was not a typical PDF file. That
terminal command does work with some of the files I have but not all of
them. Is there some way a colour scheme can be locked into a document
to make it impossible to change easily?
Thanks for your efforts so far.

------------------------------------------------------------------------------
Christiaan Hofman
2015-06-01 21:10:53 UTC
Permalink
Post by Fran Calcraft
Post by Christiaan Hofman
Post by Christiaan Hofman
Post by Fran Calcraft
The instructions in the Skim Wiki for changing the page background
Key : SKPageBackgroundColor
Values : -data, archived color, or an -array of -float
Explanation : Set this to change the default white background color of
pages. This can be an array of one to four floats between 0 and 1, or
data for an archived color.
I got everything entered into the Terminal for the setting, but using a
hexadecimal code for the background colour value did not do anything.
Presumably I misunderstood the meaning? What is an "archived color" anyway?
The colour I want for the background is #FFFF88. Is there any way to
get that? I did not use the "#" in front of the hex digits, since
Terminal treated that as an error.
An archived color is a a raw data representation of the AppKit color. But you would never be able to guess what this should be (you could perhaps copy it form some other value.)
Easiest is to use an array of floats, in your case -array -float 1 -float 1 -float 0.53333. You can also use AppleScript to set the page background color, then you can choose one using a color panel.
Christiaan
defaults write net.sourceforge.skim-app.skim SKPageBackgroundColor -array -float 1 -float 1 -float 0.53333
That does work for me. Are you sure you did this when Skim was not running?
I have no idea how to use Applescript. How do you specify the application it is to control? How is the background colour for all documents to be opened by that application controlled? The help I was able to find assumes some knowledge of Applescript to begin with, and I have none.
tell application "Skim"
set page background color to (choose color)
end tell
Christiaan
Maybe the file I was using to test was not a typical PDF file. That
terminal command does work with some of the files I have but not all of
them. Is there some way a colour scheme can be locked into a document
to make it impossible to change easily?
Thanks for your efforts so far.
Well, if the pages in the PDF draw their own background this will draw on top of whatever the page background color is. That should be obvious.

Christiaan

Loading...