KMeleonWiki > Resources > MacroLibrary > KmmGNote

Submitted by: rstlne


Google Notebook is Google's notetaking service. It comes with a bookmarklet that helps you bookmark and clip from pages into Google Notebook note entries.

One problem with the bookmarklet is it doesn't work if you have your bookmark options set to open bookmarks in a new layer. This macro solves that problem and works even with that bookmark option set. Invoke the macro from the Document or Selected Text popup menus.

Open your User Macro Folder (Edit > Configuration > User-Defined Macros) or your Macro Folder (Edit > Configuration > Macros) and create the following text file(s):


# gnote.kmm
# Macro equivalent for the "Note This" bookmarklet from Google Notebook. It is
# the same as the bookmarklet provided by Google, except that the macro works
# even if you have set your bookmark options to open bookmarks in a new layer.

gnote_go {

# Temporarily turn off popup blocking.

$__s="(function(){var w=window;var d=document;";
$__s=$__s."var g=w.open('about:blank','gnotesWin','location=0,menubar=0,scrollbars=0,status=0,toolbar=0,width=300,height=300,resizable');";
$__s=$__s."var s=d.createElement('script');";
$__s=$__s."s.setAttribute('src','http://www.google.com/notebook/bookmarkletPoster?zx='+(new Date()).valueOf());";
$__s=$__s."w.setTimeout(function(){w.blur();g.focus();}, 100)}).call({});";

# Restore popup blocking if it was turned on previously.

setmenu(Document,macro,"Note This (Google Notebook)",gnote_go,-1);
setmenu(SelectedText,macro,"Note This (Google Notebook)",gnote_go,-1);


# vim:set tw=0:
# -- The End --

Comments & Questions


(c) 2000-2010 kmeleonbrowser.org. All rights reserved.
design by splif.