The Omni Group Forums

The Omni Group Forums (http://forums.omnigroup.com/index.php)
-   OmniGraffle General (http://forums.omnigroup.com/forumdisplay.php?f=10)
-   -   Applescript for “pro-only” fill patterns? (http://forums.omnigroup.com/showthread.php?t=28134)

gshenaut 2013-02-05 03:36 PM

Applescript for “pro-only” fill patterns?
 
I'm trying to script a graph in which rectangles are filled with things like diagonal lines and so on. The “pro-only” fill mode, on the right in the color dialog in the fill inspector, looks great, but when I save a shape filled in that manner as applescript, I always get a property “fill color: {0.000000, 0.000000, 0.000000, 0.000000}” regardless of the fill pattern used.

Is this just something that can't be scripted, or is there some way to do it that the “save as applescript” function is ignoring?

RobTrew 2013-02-07 02:32 AM

That does look like a gap.

For a similar effect, you might experiment with fill.image

john.gersh 2013-02-08 06:48 AM

I agree it's a gap.

I checked the XML of an OG file containing an object with a patterned fill color. It looks like the fill color is represented as Base64-encoded TIFF image data. I take that to mean that OG doesn't use an enumeration or other parameterization to specify pattern types, which would make it hard to turn pattern into an Applescript property.

On the other hand, the patterns are stored as png files in the OG application bundle, with names following "patternX.png" with integer X, so there probably is an enumeration used somewhere within the color picker.

Why copy-as-Applescript returns a four-parameter zero color for patterned fill is a mystery.


All times are GMT -8. The time now is 03:42 PM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2020, vBulletin Solutions, Inc.