I would really like to drop MS Office and switch to the Apple apps but I have some applescripts for powerpoint that I need to replace. I need to do things like change the font or the opacity of the currently SELECTED text. I can't figure out how to get access to the selected text so that I can change its attributes. Help would be appreciated.
1 Answers
David
For PowerPoint: the text range
property, of the selection
object, has a property called font
that includes a transparency
property described as a real number.
For Keynote: the slide
object inherits from iWork container
that contains text items
that have an opacity
property described as a percent.
I got this from the respective application dictionaries.
Upon further review based on comments, there does not seem to be an indicator in the Keynote app that delivers the currently selected object of a container (shape, text object, etc.) automagically.
What I'm thinking is that you could send the menu events to perform a copy of whatever is selected and then iterate through the properties and contained objects of the slide to find a match. This is ugly but I am at a loss otherwise.

- 7,758
- 4
- 35
- 45
-
I appreciate the response --- the issue for me, as I said in my question is that I don't know how to get hold of the "selection" object . I have access to those dictionaries with Script Debugger but I find it very difficult in general to figure out how to use those names, commands, properties etc in actual applescript code. In other words, I understand what's available but I don't know how to get at the stuff! – David Dec 02 '15 at 19:14
-
@David - Understood... I will tool around locally (I am on El Cap.) and edit/update my answer. – Frank C. Dec 02 '15 at 22:01
-
Thanks for the edited update --- really bizarre that one can't find the selected text directly in Keynote. – David Dec 12 '15 at 18:39