PB IDE Tool: Dash Mac OS X API help starter

Mac OSX specific forum
User avatar
Danilo
Addict
Addict
Posts: 3037
Joined: Sat Apr 26, 2003 8:26 am
Location: Planet Earth

PB IDE Tool: Dash Mac OS X API help starter

Post by Danilo »

I downloaded Apple's XCode development environment from AppStore and installed the API documentation within XCode,
and now I wanted a better standalone API help browser.

Today I found Dash (Docs & Snippets) in Apple's AppStore (free to try, in-app purchase was 60% off today: 6,99 Euro)

So here a small PB IDE tool that starts Dash and displays help for the current word under the PB IDE cursor:

Code: Select all

; Open Dash Help System.pb
;
; PB tool to open Dash help system on Mac OS X
; to display help for current word under cursor
;
; Download "Dash (Docs & Snippets)" in Apple's AppStore
; (free To try, purchase is available within the application)
;
; Dash website: http://kapeli.com/dash
;
;
; compile this code to executable "Open Dash Help System" (without .app extension)
;
;    compilation options:
;       Executable format: Console
;       [X] Create unicode executable
;
; Add a new tool to PB IDE:
;    Commandline:                   path to your executable
;    Arguments:
;    Working directory:
;    Name:                          Open Dash Help System
;    Event to trigger the tool:     Menu Or Shortcut
;    Shortcut:                      Alt+F1
;
;    [X] Wait until tool quits
;    [X] Run Hidden
;
currentWord.s = Trim(GetEnvironmentVariable("PB_TOOL_Word"))

If Right(currentWord,1) = "_"
    currentWord = Left(currentWord, Len(currentWord)-1)
EndIf

If OpenWindow(0, 0, 0, 0, 0, "Dash Starter", #PB_Window_Invisible)
    WebGadget(0, 0, 0, 0, 0, "dash://"+currentWord)
    ;Delay(100)
    CloseWindow(0)
EndIf
IDE tool settings:
Image

Currently (PB5.20 beta6) the "Shortcut" does not work within the IDE tool settings. You can change
the shortcut in the file /users/name/.purebasic/tools.prefs like this:

Code: Select all

Shortcut = 262522
This is the number for:

Code: Select all

Debug #PB_Shortcut_Alt | #PB_Shortcut_F1
...so I can open Dash Mac OS X API help with Alt+F1

Dash looks like this when opened with Alt+F1 over the API command "CGMainDisplayID":
Image



Dash supports many more help catalogs for different languages and topics.
You can download more help systems within Dash itself (Preferences > Downloads).

Image
wilbert
PureBasic Expert
PureBasic Expert
Posts: 3870
Joined: Sun Aug 08, 2004 5:21 am
Location: Netherlands

Re: PB IDE Tool: Dash Mac OS X API help starter

Post by wilbert »

There seems to be one that is a bit similar but free
http://www.fileability.net/ingredients/
I don't know if it is as good as Dash.
Windows (x64)
Raspberry Pi OS (Arm64)
User avatar
Danilo
Addict
Addict
Posts: 3037
Joined: Sat Apr 26, 2003 8:26 am
Location: Planet Earth

Re: PB IDE Tool: Dash Mac OS X API help starter

Post by Danilo »

wilbert wrote:There seems to be one that is a bit similar but free
http://www.fileability.net/ingredients/
I don't know if it is as good as Dash.
Yep, I was searching for different help browsers yesterday.

Ingredients didn't work here. It says itself that it could be incompatible to newest XCode version. I tried Ingredients 1.0 and also the 1.1beta.

I also found TakeOff in AppStore. I can't test it before paying money and it supports only a very limited set of docs anyway.

Now I found Dash. Tested it for free, and immediately paid 6,99 Euro for it. Dash comes with 80+ offline documentation sets,
so it is my Mac OS X documentation center from now on. ;)
Mac OS X API docs, C, C++, Mono, HTML5, CSS, Java, JavaScript, Go, Ruby, Perl, PHP, Go, CoffeeScript, jQuery, OpenGL, QT, SQLite, MySQL, PostgreSQL, Drupal, ActionScript, ...and much more... all in one doc center app. Already lovin' it. :D
wilbert
PureBasic Expert
PureBasic Expert
Posts: 3870
Joined: Sun Aug 08, 2004 5:21 am
Location: Netherlands

Re: PB IDE Tool: Dash Mac OS X API help starter

Post by wilbert »

I just tried and you are right Ingredients doesn't work :(
Windows (x64)
Raspberry Pi OS (Arm64)
User avatar
Shardik
Addict
Addict
Posts: 1989
Joined: Thu Apr 21, 2005 2:38 pm
Location: Germany

Re: PB IDE Tool: Dash Mac OS X API help starter

Post by Shardik »

Thank you Danilo for your nice idea of using a standalone API help browser! :idea:
wilbert wrote:There seems to be one that is a bit similar but free
http://www.fileability.net/ingredients/
I don't know if it is as good as Dash.
Thank you for the link to the free Ingredients, Wilbert. Ingredients 1.0 and 1.1b1 work nicely on OS X 10.6.8 (Snow Leopard) with Xcode 3.2.6:

Image

wilbert wrote:I just tried and you are right Ingredients doesn't work :(
Unfortunately Ingredients doesn't work in OS X 10.7.5 (Lion) or OS X 10.8.4 (Mountain Lion) with the documentation for the current Xcode 4.6.3 because it wasn't updated for Apple's new documentation... :cry:
User avatar
Danilo
Addict
Addict
Posts: 3037
Joined: Sat Apr 26, 2003 8:26 am
Location: Planet Earth

Re: PB IDE Tool: Dash Mac OS X API help starter

Post by Danilo »

Dash is now also available for iPad and iPhone: Dash for iOS.

EDIT:
For Windows users: Velocity - The Documentation and Docset Viewer for Windows - (found at: Meet Velocity for Windows)
Post Reply