Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I am unclear on this, because I have heard mention of a proposed API for Unity Lenses, and such an API would be extremely useful for projects involving home automation.

I am interested in developing in that direction, but I haven't been able to find the API for Unity Lenses. It would make the most sense of libunity was to include Unity Lenses because it would put all the functionality of the Unity launcher into one place. If libunity is not the API for Lenses, does such an API exist, and how would I find it?

share|improve this question
add comment

1 Answer 1

Note: The user visible name is Lenses, however in the code and packages they're still referred to as Places. "Places" as a term will be fully retired in 11.10

Both default Lenses, unity-place-files and unity-place-applications, are in fact based on public API exposed via libunity.

Unfortunately there are no API docs available for libunity yet - but that will change in the weeks to come. Monitor planet.ubuntu.com or watch the Natty archives for a libunity-doc package. For now there is a simple example in lp:unity-place-sample, if you cross ref that with https://wiki.ubuntu.com/Unity/Lenses you may have a chance of getting something going.

Another important library when writing lenses for Unity is Dee. It's a data model library used to do ad-hoc sharing of data models between processes (in this case the place daemon and Unity). Dee is fully documented and you can find the docs in the libdee-doc package (or you can build it yourself from lp:dee).

To grab the code for either project you can do:

bzr branch lp:unity-place-sample
bzr branch lp:dee
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.