The Omni Group
These forums are now read-only. Please visit our new forums to participate in discussion. A new account will be required to post in the new forums. For more info on the switch, see this post. Thank you!

Go Back   The Omni Group Forums > OmniFocus > OmniFocus 1 for Mac
FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
On desktop banner of current action Thread Tools Search this Thread Display Modes
Quote:
Originally Posted by fathom View Post
How the heck did you do that?!!!! That's even better!
0% opacity background
check "Always on Top"
use Lucida Grande 14 (I think) pt Font to blend in

(annoyed that it's a little fuzzy, but good enough for now)

then just drag the window on top of the titlebar.

The caveat is that I only want to have 1 action showing, more and I might need to make it output in a line. I might also play around with exporting attributed text so I can the the note in there as well in a non-bold font.
 
I had some fun playing with this tonight and made a few enhancements. My updated version is below. Significant changes:
  • got rid of the alert dialog that would appear if no items were selected,
  • added bullets in front of the items,
  • added a property to set the maximum length of displayed actions. Any actions longer than this are truncated now. Set it really large to avoid truncation.

Install instructions above still apply, but here's the updated code:
Code:
(*
	This script works with GeekTool to display the currently selected actions in OmniFocus. This script is modified from a script originally designed to display the currently selected actions in Growl.
	
	version 0.2, by James A. Jones
	version 0.1, by Curt Clifton

	Copyright © 2009, James A. Jones
	Copyright © 2007-2009, Curtis Clifton
	
	All rights reserved.
	
	Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
	
		• Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
		
		• Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
		
	THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
	
	version 0.2.1: Eliminated alert dialog for no actions selected, misc. enhancements
	version 0.2: GeekTool modification
	version 0.1: Original release
*)

-- Edit the number in the line below to control maximum number of characters for each displayed action:
property maximumLength : 25

property actionBullet : "* "
property noSelectionMessage : "[no actions selected in OmniFocus]"

tell application "OmniFocus"
	tell front document
		tell content of document window 1
			set theSelectedItems to name of every selected tree
			if ((count of theSelectedItems) < 1) then
				return noSelectionMessage
			end if
		end tell
	end tell
end tell

set theSelectedItems to my trimItems(theSelectedItems, {})

-- Standard Applescript incantation to turn a list into a delimited string:
set oldDelim to AppleScript's text item delimiters
set AppleScript's text item delimiters to (return & actionBullet)
set theItemsText to theSelectedItems as text
set AppleScript's text item delimiters to oldDelim
-- Slaps a bullet on the front and returns the string:
return actionBullet & theItemsText

on trimItems(xs, accum)
	if xs is {} then return reverse of accum
	set truncatedItem to item 1 of xs
	if ((length of truncatedItem) > maximumLength) then
		set truncatedItem to text from character 1 to character maximumLength of truncatedItem
		set truncatedItem to truncatedItem & "..."
	end if
	set accum to {truncatedItem} & accum
	return trimItems(rest of xs, accum)
end trimItems
__________________
Cheers,

Curt
 
Quote:
Originally Posted by xmas View Post
0% opacity background
check "Always on Top"
use Lucida Grande 14 (I think) pt Font to blend in

(annoyed that it's a little fuzzy, but good enough for now)

then just drag the window on top of the titlebar.

The caveat is that I only want to have 1 action showing, more and I might need to make it output in a line. I might also play around with exporting attributed text so I can the the note in there as well in a non-bold font.
Ohhh. That's funny. So, it isn't really on the title bar, it is just a transparent window sitting on top of it. Such a simple solution that I never would have thought of :-) Good job! Thanks!

Last edited by fathom; 2009-08-26 at 07:51 PM..
 
I want ALL my Due tasks exportet to GeekTool, but I am not a scripter, so I can not get the text out. (I just want the task names and the project)

Do you now the trick?
 
CVN,

That's a harder problem. To completely automated it you need a script that "walks" the entire tree of projects and actions in OF, calculates which ones are due (based on action due date or parent due dates), and outputs the right text. Additionally the script probably should detect which tasks are available and only show those.

That's an interesting problem, so I might take a crack at it sometime.

In the interim, you can open the Due perspective in OF and select all the actions by click the first one and shift-clicking the last one. Then the script above will do what you want.
__________________
Cheers,

Curt
 
Yes, Curt, it if selected, it will act as wanted.... but it is not handy to keep all due items selected at all times ;-)

I dont know about OF scripting, but If it is possible to take all tasks from an inactive perspecitve, is this a way to get the proper tasks together... then the display part still remains.

I have found theese, but cannot make them work:

http://rany.posterous.com/using-omnifocus-with-geektool
http://concisionandconcinnity.blogsp...ocus-with.html

The last one seems to be the right way, but gives an error:
"OmniFocus got an error: Can’t get name of value of tree 1 of content of document window id 4338 of document id "oi_WtYRN0cI"."

Last edited by CVN; 2009-09-04 at 07:46 AM..
 
Quote:
Originally Posted by CVN View Post
Yes, Curt, it if selected, it will act as wanted.... but it is not handy to keep all due items selected at all times ;-)

I dont know about OF scripting, but If it is possible to take all tasks from an inactive perspecitve, is this a way to get the proper tasks together... then the display part still remains.
There's no automatic way in OF to get the items of a perspective without displaying the perspective.
__________________
Cheers,

Curt
 
OK. As mentioned, I do not know much about the scripting possibilities.

If you figure it out it will be much appreciated!

I have tried to modify the listet scripts, but with no luck.
 
Fathom - that's a great script.

Is there a way to change the script to do two things

(1) show me everything in my "Due" perspective?
(2) have it run w/o OmniFocus having to be open?


I know this original post was about a focus on the most important thing...

But I'm hoping to keep what is due soon and due this week. If the app is open, it is real easy to view the window to look at the list - but if I want to make that list persistent on my desktop with GeekTool... what do you think?

Thanks for your help!

- Paul
 
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Script: custom OmniFocus action lists on the desktop, using Geektool RobTrew OmniFocus Extras 79 2014-01-09 09:48 AM
Feature request: current action on-top sticky Craig OmniFocus 1 for Mac 7 2012-11-08 05:04 AM
New OmniFocus Banner spye OmniFocus for iPad 1 2010-07-30 04:50 AM
make OF action out of current emacs buffer jklymak OmniFocus Extras 3 2009-08-16 12:11 PM
Wanted: Growl-style bubble for current action matt_good OmniFocus Extras 18 2009-06-21 09:22 AM


All times are GMT -8. The time now is 01:06 AM.


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