<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Serendip &#187; firefox</title>
	<atom:link href="http://www.serendip.ws/archives/tag/firefox/feed" rel="self" type="application/rss+xml" />
	<link>http://www.serendip.ws</link>
	<description>Webデザイン・プログラミング</description>
	<lastBuildDate>Fri, 10 Feb 2012 05:33:58 +0000</lastBuildDate>
	<language>ja</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2</generator>
		<item>
		<title>Ubuntu 8.04 と Firefox 3.5</title>
		<link>http://www.serendip.ws/archives/3274</link>
		<comments>http://www.serendip.ws/archives/3274#comments</comments>
		<pubDate>Mon, 12 Oct 2009 11:55:06 +0000</pubDate>
		<dc:creator>iNo</dc:creator>
				<category><![CDATA[blog]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://www.serendip.ws/?p=3274</guid>
		<description><![CDATA[Ubuntu 8.04 (Hardy Heron) に Firefox3.5 をインストールして起動しようとすると、uim のバージョンが 1.4.1 のために起動できないらしい。 今月中には Ubuntu 9.10 ( [...]]]></description>
			<content:encoded><![CDATA[<p>Ubuntu 8.04 (Hardy Heron) に Firefox3.5 をインストールして起動しようとすると、uim のバージョンが 1.4.1 のために起動できないらしい。<br />
今月中には Ubuntu 9.10 (Karmic Koala) がリリースされるので（現在 <a href="http://www.ubuntu.com/testing/karmic/beta" class="out">Beta版</a>がリリース中）、そちらを待とうかな。</p>
<p><abbr title="Long Term Support">LTS</abbr> は安定して使い続けることができるけど、新しいソフトを使おうとするとハマるね。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.serendip.ws/archives/3274/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Firefox3.5 でネイティブ JSON を利用する</title>
		<link>http://www.serendip.ws/archives/2367</link>
		<comments>http://www.serendip.ws/archives/2367#comments</comments>
		<pubDate>Wed, 24 Jun 2009 05:01:11 +0000</pubDate>
		<dc:creator>iNo</dc:creator>
				<category><![CDATA[blog]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://www.serendip.ws/?p=2367</guid>
		<description><![CDATA[Firefox3.5 から実装された native JSON を使ってみる。 以下のスクリプトの実行には Firefox3.5 以上が必要。 スクリプトコード &#60;script type=&#34;text/jav [...]]]></description>
			<content:encoded><![CDATA[<p>Firefox3.5 から実装された native JSON を使ってみる。<br />
以下のスクリプトの実行には Firefox3.5 以上が必要。</p>
<p>スクリプトコード</p>
<pre><span class="Identifier">&lt;</span><span class="Statement">script</span><span class="Identifier"> </span><span class="Type">type</span><span class="Identifier">=</span><span class="Constant">&quot;text/javascript&quot;</span><span class="Identifier">&gt;</span>
<span class="Identifier">var</span><span class="Special"> jsonTestRun = </span><span class="Identifier">function</span>()<span class="Special"> </span><span class="Identifier">{</span>
<span class="Special">    </span><span class="Identifier">var</span><span class="Special"> jsonSource = </span><span class="Constant">'{ &quot;name&quot; : &quot;tom&quot;, &quot;age&quot; : &quot;24&quot; }'</span><span class="Special">;</span>
<span class="Special">    </span><span class="Identifier">var</span><span class="Special"> jsonParsed = JSON.parse</span>(<span class="Special">jsonSource</span>)<span class="Special">;</span>
<span class="Special">    </span><span class="Statement">alert</span>(
<span class="Special">        jsonParsed.toSource</span>()<span class="Special"> + </span><span class="Constant">&quot;</span><span class="Special">\n</span><span class="Constant">&quot;</span><span class="Special"> +</span>
<span class="Special">        JSON.stringify</span>(<span class="Special">jsonParsed</span>)<span class="Special"> + </span><span class="Constant">&quot;</span><span class="Special">\n</span><span class="Constant">&quot;</span><span class="Special"> +</span>
<span class="Special">        </span><span class="Constant">&quot;name is &quot;</span><span class="Special"> + jsonParsed.name + </span><span class="Constant">&quot;, age is &quot;</span><span class="Special"> + jsonParsed.age</span>
<span class="Special">    </span>)<span class="Special">;</span>
<span class="Identifier">}</span>
<span class="Identifier">&lt;/</span><span class="Statement">script</span><span class="Identifier">&gt;</span>
<span class="Identifier">&lt;</span><span class="Statement">input</span><span class="Identifier"> </span><span class="Type">type</span><span class="Identifier">=</span><span class="Constant">&quot;button&quot;</span><span class="Identifier"> </span><span class="Type">value</span><span class="Identifier">=</span><span class="Constant">&quot;Run...&quot;</span><span class="Identifier"> </span><span class="Special">onclick=&quot;</span><span class="Special">jsonTestRun</span>()<span class="Special">;</span><span class="Special">&quot;</span><span class="Identifier"> /&gt;</span>
</pre>
<div>
<script type="text/javascript">
var jsonTestRun = function() {
    var jsonSource = '{ "name" : "tom", "age" : "24" }';
    var jsonParsed = JSON.parse(jsonSource);
    alert(
        jsonParsed.toSource() + "\n" +
        JSON.stringify(jsonParsed) + "\n" +
        "name is " + jsonParsed.name + ", age is " + jsonParsed.age
    );
}
</script><br />
<input type="button" value="Run..." onclick="jsonTestRun();" />
</div>
<p>参考：<a href="https://developer.mozilla.org/En/Using_JSON_in_Firefox" class="out">Using native JSON &#8211; MDC</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.serendip.ws/archives/2367/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Firefox で現在のページのタブの色を変更する</title>
		<link>http://www.serendip.ws/archives/2300</link>
		<comments>http://www.serendip.ws/archives/2300#comments</comments>
		<pubDate>Thu, 18 Jun 2009 07:14:21 +0000</pubDate>
		<dc:creator>iNo</dc:creator>
				<category><![CDATA[blog]]></category>
		<category><![CDATA[firefox]]></category>

		<guid isPermaLink="false">http://www.serendip.ws/?p=2300</guid>
		<description><![CDATA[Mac OSX 版の Firefox 3.5 のタブの色が変化に乏しく、現在のページのタブが分かりにくいので userChrome.css に以下のコードを記述して見やすくした。 tab { color: #333333 [...]]]></description>
			<content:encoded><![CDATA[<p>Mac OSX 版の Firefox 3.5 のタブの色が変化に乏しく、現在のページのタブが分かりにくいので userChrome.css に以下のコードを記述して見やすくした。</p>
<p><img src="http://www.serendip.ws/wordpress/wp-content/uploads/fx35_tab_color_config.png" alt="Firefox3.5のタブ色スクリーンショット" title="Firefox3.5のタブ色スクリーンショット" width="522" height="219" class="size-full wp-image-2302" /></p>
<pre>tab <span class="Identifier">{</span>
    <span class="Type">color</span>: <span class="color333333">#333333</span> <span class="Special">!important</span>;
<span class="Identifier">}</span>
tab<span class="Special">[</span>selected<span class="Special">=</span><span class="Constant">&quot;true&quot;</span><span class="Special">]</span> <span class="Identifier">{</span>
    <span class="Type">color</span>: <span class="color000000">#000000</span> <span class="Special">!important</span>;
    <span class="Type">background-color</span>: <span class="colordddddd">#dddddd</span> <span class="Special">!important</span>;
<span class="Identifier">}</span>
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.serendip.ws/archives/2300/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>よく使う Firefox 拡張機能のバージョン 3.5 対応状況</title>
		<link>http://www.serendip.ws/archives/2294</link>
		<comments>http://www.serendip.ws/archives/2294#comments</comments>
		<pubDate>Thu, 18 Jun 2009 05:59:52 +0000</pubDate>
		<dc:creator>iNo</dc:creator>
				<category><![CDATA[blog]]></category>
		<category><![CDATA[firefox]]></category>

		<guid isPermaLink="false">http://www.serendip.ws/?p=2294</guid>
		<description><![CDATA[Firefox 3.5 RC1 が公開されたので、そろそろ新バージョンへの移行の準備を始める。 個人的に利用頻度の高い拡張機能の対応バージョンを調べた。 拡張のバージョンと、その対応 Firefox バージョンは2009 [...]]]></description>
			<content:encoded><![CDATA[<p>Firefox 3.5 RC1 が公開されたので、そろそろ新バージョンへの移行の準備を始める。<br />
個人的に利用頻度の高い拡張機能の対応バージョンを調べた。</p>
<p>拡張のバージョンと、その対応 Firefox バージョンは2009年6月18日現在のもの。<ins datetime="2009-06-28T16:45:55+0900">（2009年6月28日更新、Live HTTP Headers）</ins><ins datetime="2009-07-12T12:29:27+0900">（2009年7月12日更新、YSlow）</ins><br />
ほとんどの拡張機能が 3.5 にまで対応していた。</p>
<dl>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/271" class="out">ColorZilla</a></dt>
<dd>拡張ver: 2.0.2<br />
    Firefox: 1.5 &#8211; 3.5.*</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/1815" class="out">Console<sup>2</sup></a></dt>
<dd>拡張ver: 0.3.10<br />
    Firefox: 1.5 &#8211; 3.6a1pre</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/6622" class="out">DOM Inspector</a></dt>
<dd>拡張ver: 2.0.3<br />
    Firefox: 3.0a1 &#8211; 3.6a1pre</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/1843" class="out">Firebug</a></dt>
<dd>拡張ver: 1.4.0b2<br />
    Firefox: 3.5b4 &#8211; 3.5.* （※Firefox3.5用）</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/11905" class="out">Firefinder for Firebug</a></dt>
<dd>拡張ver: 0.91<br />
    Firefox: 3.0 &#8211; 3.5.*</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/7518" class="out">Firefox PDF Plugin for Mac OS X</a></dt>
<dd>拡張ver: 1.0.4<br />
    Firefox: 3.0 &#8211; 3.5.*</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/748" class="out">Greasemonkey</a></dt>
<dd>拡張ver: 0.8.20090123.1<br />
    Firefox: 1.5 &#8211; 3.5.*</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/3829" class="out">Live HTTP Headers</a></dt>
<dd><del datetime="2009-06-28T16:47:22+0900">拡張ver: 0.14</del><br />
    <del datetime="2009-06-28T16:43:01+0900">Firefox: <strong style="color:red;">0.8 &#8211; 3.0.*</strong></del><br />
    <ins datetime="2009-06-28T16:47:42+0900">拡張ver: 0.15</ins><br />
    <ins datetime="2009-06-28T16:43:31+0900" title="追記：2009-06-28T16:45:11+0900">Firefox: 0.8 &#8211; 3.5.*</ins></dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/722" class="out">NoScript</a></dt>
<dd>拡張ver: 1.9.3.3<br />
    Firefox: 1.5 &#8211; 3.6a1pre</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/9527" class="out">Ubiquity</a></dt>
<dd>拡張ver: 0.1.8<br />
    Firefox: 3.0 &#8211; 3.6a1pre</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/59" class="out">User Agent Switcher</a></dt>
<dd>拡張ver: 0.6.11<br />
    Firefox: 1.0 &#8211; 3.5.*</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/4891" class="out">Vimperator</a></dt>
<dd>拡張ver: 2.0<br />
    Firefox: 3.0 &#8211; 3.6a1pre</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/60" class="out">Web Developer</a></dt>
<dd>拡張ver: 1.1.6<br />
    Firefox: 1.0 &#8211; 3.5.*</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/5239" class="out">XUL/Migemo</a></dt>
<dd>拡張ver: 0.11.14<br />
    Firefox: 2.0 &#8211; 3.6a1pre</dd>
<dt><a href="https://addons.mozilla.org/ja/firefox/addon/5369" class="out">YSlow</a></dt>
<dd><del datetime="2009-07-12T12:27:20+0900">拡張ver: 2.0.0b3</del><br />
    <del datetime="2009-07-12T12:27:20+0900">Firefox: <strong style="color:red;">2.0 &#8211; 3.0.*</strong></del><br />
    <ins datetime="2009-07-12T12:27:20+0900">拡張ver: 2.0.0b4</ins><br />
    <ins datetime="2009-07-12T12:27:20+0900" title="追記：2009-07-12T12:27:20+0900">Firefox: 2.0 &#8211; 3.5.*</ins></dd>
<dt><a href="http://wiki.github.com/bard/mozrepl" class="out">MozRepl</a></dt>
<dd>拡張ver: 1.0.0.2009041717<br />
    Firefox: 不明（Firefox3.5RC1で動作した）</dd>
<dt><a href="/software/moderror">moderror</a></dt>
<dd>拡張ver: 3.0.1<br />
    Firefox: 3.0 &#8211; 3.5.*</dd>
<dt><a href="/software/statusbarcharset">Statusbar Charset</a></dt>
<dd>拡張ver: 1.0.4<br />
    Firefox: 1.5 &#8211; 3.5.*</dd>
</dl>
]]></content:encoded>
			<wfw:commentRss>http://www.serendip.ws/archives/2294/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Firefox3 の起動時間を改善する</title>
		<link>http://www.serendip.ws/archives/2000</link>
		<comments>http://www.serendip.ws/archives/2000#comments</comments>
		<pubDate>Wed, 13 May 2009 03:17:10 +0000</pubDate>
		<dc:creator>iNo</dc:creator>
				<category><![CDATA[blog]]></category>
		<category><![CDATA[firefox]]></category>

		<guid isPermaLink="false">http://www.serendip.ws/?p=2000</guid>
		<description><![CDATA[はてなブックマーク界隈で話題になっている Firefox の起動時間短縮について試してみた。 Firefox3 の起動時間を短くするために、特にサイズの肥大化していたデータベースファイル places.sqlite と  [...]]]></description>
			<content:encoded><![CDATA[<p>はてなブックマーク界隈で話題になっている Firefox の起動時間短縮について試してみた。</p>
<p>Firefox3 の起動時間を短くするために、特にサイズの肥大化していたデータベースファイル places.sqlite と urlclassifier3.sqlite の2つの SQLite ファイルに対して <code>reindex</code> と <code>vacuum</code> を実行した。<br />
places.sqlite はプロファイルフォルダにある。urlclassifier3.sqlite は OS によりそれぞれ保存場所が異なる。</p>
<dl>
<dt>Windows</dt>
<dd><code><var>ユーザー名</var>\Local Setteings\Application Data\Mozilla\Firefox\Profies\<var>ランダム文字列.プロファイル名</var>/urlclassifier3.sqlite</code></dd>
<dt>Mac OSX</dt>
<dd><code>~/Library/Caches/Firefox/Profiles/<var>ランダム文字列.プロファイル名</var>/urlclassifier3.sqlite</code></dd>
<dt>Linux (Ubuntu)</dt>
<dd><code>~/.mozilla/firefox/<var>ランダム文字列.プロファイル名</var>/urlclassifier3.sqlite</code></dd>
</dl>
<p>以下は Mac OSX での作業例。</p>
<p><code>sqlite3</code> は MacPorts からインストールしておく。</p>
<pre>$ sudo port install sqlite3
</pre>
<p>プロファイルフォルダに移動してコマンドを実行する。</p>
<pre>$ cd ~/Library/Application Support/Firefox/Profiles/<var>ランダム文字列.プロファイル名</var>
$ sqlite3 places.sqlite reindex
$ sqlite3 places.sqlite vacuum
$ cd ~/Library/Caches/Firefox/Profiles/<var>ランダム文字列.プロファイル名</var>
$ sqlite3 urlclassifier3.sqlite reindex
$ sqlite3 urlclassifier3.sqlite vacuum
</pre>
<p>実行してみた結果、体感できるぐらい起動は速くなったけれど、それでも初回起動には38秒もかかった・・・<br />
重量級の拡張機能をいくつも入れているからしかたないか。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.serendip.ws/archives/2000/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Firefox でステータスバーに HTML ドキュメントのモード（互換/標準）を表示する userChrome.js スクリプト</title>
		<link>http://www.serendip.ws/archives/1080</link>
		<comments>http://www.serendip.ws/archives/1080#comments</comments>
		<pubDate>Wed, 28 Jan 2009 12:34:47 +0000</pubDate>
		<dc:creator>iNo</dc:creator>
				<category><![CDATA[blog]]></category>
		<category><![CDATA[firefox]]></category>

		<guid isPermaLink="false">http://www.serendip.ws/?p=1080</guid>
		<description><![CDATA[現在表示中のタブの HTML ドキュメントでの互換・標準モード（document.compatMode）の状態を Firefox のステータスバー上に表示する userChrome.js スクリプトを作りました。 CSS [...]]]></description>
			<content:encoded><![CDATA[<p>現在表示中のタブの HTML ドキュメントでの互換・標準モード（<code>document.compatMode</code>）の状態を Firefox のステータスバー上に表示する userChrome.js スクリプトを作りました。<br />
<code>CSS1Compat</code> の場合 &quot;標準&quot; と、 <code>BackCompat</code> の場合 &quot;互換&quot; と表示します。<br />
スクリプトファイルは <a href="/resource/statusbarCompatMode.uc.js">statusbarCompatMode.uc.js</a> です。</p>
<p>Firefox拡張機能 <a href="http://mozilla.zeniko.ch/userchrome.js.html" class="out">userChrome.js</a> をインストールして使って下さい。</p>
<pre>(<span class="Identifier">function</span>() <span class="Identifier">{</span>
    <span class="Identifier">var</span> statusbarCompatMode = <span class="Identifier">{</span>
        panel: <span class="Statement">undefined</span>,
        modes: <span class="Identifier">{</span><span class="Constant">&quot;CSS1Compat&quot;</span>:<span class="Constant">&quot;</span><span class="Special">\u</span><span class="Constant">6A19</span><span class="Special">\u</span><span class="Constant">6E96&quot;</span>, <span class="Constant">&quot;BackCompat&quot;</span>:<span class="Constant">&quot;</span><span class="Special">\u</span><span class="Constant">4E92</span><span class="Special">\u</span><span class="Constant">63DB&quot;</span><span class="Identifier">}</span>,
        init: <span class="Identifier">function</span>() <span class="Identifier">{</span>
            <span class="Identifier">var</span> statusbar = <span class="Statement">document</span>.getElementById(<span class="Constant">'status-bar'</span>);
            <span class="Identifier">this</span>.panel = <span class="Statement">document</span>.createElement(<span class="Constant">'statusbarpanel'</span>);
            <span class="Identifier">this</span>.panel.setAttribute(<span class="Constant">'id'</span>, <span class="Constant">'statusbar-compatmode-display'</span>);
            <span class="Identifier">this</span>.setLabel();
            <span class="Statement">if</span> (statusbar) <span class="Identifier">{</span>
                statusbar.appendChild(<span class="Identifier">this</span>.panel);
            <span class="Identifier">}</span>
        <span class="Identifier">}</span>,
        setLabel: <span class="Identifier">function</span>() <span class="Identifier">{</span>
            <span class="Identifier">var</span> mode = Application.activeWindow.activeTab.<span class="Statement">document</span>.compatMode;
            <span class="Identifier">this</span>.panel.setAttribute(<span class="Constant">'label'</span>, <span class="Identifier">this</span>.modes<span class="Identifier">[</span>mode<span class="Identifier">]</span>);
            <span class="Identifier">this</span>.panel.setAttribute(<span class="Constant">'tooltiptext'</span>, mode);
        <span class="Identifier">}</span>
    <span class="Identifier">}</span>

    statusbarCompatMode.init();
    <span class="Statement">window</span>.addEventListener(<span class="Constant">'focus'</span>, <span class="Identifier">function</span>() <span class="Identifier">{</span>
        statusbarCompatMode.setLabel();
    <span class="Identifier">}</span>, <span class="Constant">true</span>);
    <span class="Statement">window</span>.addEventListener(<span class="Constant">'load'</span>, <span class="Identifier">function</span>() <span class="Identifier">{</span>
        statusbarCompatMode.setLabel();
    <span class="Identifier">}</span>, <span class="Constant">true</span>);
<span class="Identifier">}</span>)();
</pre>
<p><code>statusbar is null</code> というエラーメッセージが表示されるようだったので修正しました。（2009/01/29）</p>
]]></content:encoded>
			<wfw:commentRss>http://www.serendip.ws/archives/1080/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ubiquity（Firefox拡張機能）で郵便番号検索・住所検索をする</title>
		<link>http://www.serendip.ws/archives/171</link>
		<comments>http://www.serendip.ws/archives/171#comments</comments>
		<pubDate>Thu, 04 Sep 2008 08:20:56 +0000</pubDate>
		<dc:creator>iNo</dc:creator>
				<category><![CDATA[blog]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://www.serendip.ws/?p=171</guid>
		<description><![CDATA[Firefox拡張機能の Ubiquity で&#34;郵便番号から住所&#34;、または&#34;住所から郵便番号&#34;を検索するスクリプトを書いた。 API はグループテクノロジー株式会社の &#34; [...]]]></description>
			<content:encoded><![CDATA[<p>Firefox拡張機能の <a href="http://labs.mozilla.com/2008/08/introducing-ubiquity/" class="out">Ubiquity</a> で&quot;<strong>郵便番号から住所</strong>&quot;、または&quot;<strong>住所から郵便番号</strong>&quot;を検索するスクリプトを書いた。<br />
API は<a href="http://groovetechnology.co.jp/" class="out">グループテクノロジー株式会社</a>の &quot;<a href="http://groovetechnology.co.jp/webservice/zipsearch/" class="out"><strong>郵便番号検索API</strong></a>&quot;を利用した。<br />コールバック関数の部分がよく分からなかったので置換してJSONの形に直した・・・(-_-;)。</p>
<h3>使い方</h3>
<dl>
<dt>郵便番号から住所を検索</dt>
<dd><kbd>zip <var>[郵便番号]</var></kbd></dd>
<dt>例:</dt>
<dd><kbd>zip 1000001</kbd><br /><kbd>zip 100-0001</kbd><br />
<img src="http://www.serendip.ws/wordpress/wp-content/uploads/fx_ubiquity_zipcode_search_20080904-170101.png" alt="Ubiquity Zip-Code Search ScreenShot1" title="郵便番号から住所を検索" width="500" height="228" class="size-full wp-image-172" /></dd>
<dt>住所から郵便番号を検索</dt>
<dd><kbd>zip <var>[住所]</var></kbd></dd>
<dt>例:</dt>
<dd><kbd>zip 千代田区千代田</kbd><br /><kbd>zip 東京都千代田区千代田</kbd><br />
<img src="http://www.serendip.ws/wordpress/wp-content/uploads/fx_ubiquity_zipcode_search_20080904-170100.png" alt="Ubiquity Zip-Code Search ScreenShot2" title="住所から郵便番号を検索" width="500" height="228" class="size-full wp-image-173" /></dd>
</dl>
<h3>インストール・アンインストール</h3>
<p><a href="http://sandbox.serendip.ws/fx_ubiquity_zipcode_search.html">インストール</a></p>
<p>アンインストールは Ubiquity の Preferences ページ（about:ubiquity）の <span style="font-variant:small-caps;">Subscribed Feeds</span> から該当フィードの [unsubscribe] をクリックする。</p>
<h3>スクリプトコード</h3>
<pre><code>CmdUtils.CreateCommand({
    name: &quot;zip&quot;,
    takes: {&quot;Searching&quot; : noun_arb_text },
    url: &quot;&quot;,
    icon: &quot;http://groovetechnology.co.jp/favicon.ico&quot;,
    description: &quot;Searches Zip-Code.&quot;,
    homepage: &quot;http://www.serendip.ws/&quot;,
    author: { name: &quot;iNo&quot;, homepage: &quot;http://www.serendip.ws/&quot; },
    license: &quot;MPL&quot;,
    preview: function(pBlock, directObject) {
        var query = directObject.text;
        pBlock.innerHTML = &quot;Searching for...&quot;;
        if (query.match(/^\d+\-?\d+$/)) {
            var type = 'zipcode=';
        } else {
            var type = 'word=';
        }
        var url = &quot;http://groovetechnology.co.jp/ZipSearchService/v1/zipsearch?&quot; + type + query + &quot;&amp;callback=callback&quot;;
        jQuery.get(url, null, function(response) {
            var json = Utils.decodeJson(response.replace(/(^callback\( | \)\;$)/g, &quot;&quot;));
            var pTemplate = &quot;&lt;div style=\&quot;max-height:500px;overflow:auto;\&quot;&gt;{for result in zipcode}&lt;div&gt;&lt;tt&gt;${result.zipcode}\t${result.prefecture}${result.city}${result.town}&lt;/tt&gt;&lt;/div&gt;{/for}&lt;/div&gt;&quot; +
                            &quot;&lt;div style=\&quot;text-align:right;font-style:italic;\&quot;&gt;Author iNo (&lt;a href=\&quot;http://www.serendip.ws/\&quot; style=\&quot;color:skyblue;text-decoration:underline;\&quot;&gt;Serendip&lt;/a&gt;)&lt;/div&gt;&quot; +
                            &quot;&lt;div style=\&quot;text-align:right;font-style:italic;\&quot;&gt;Powered by &lt;a href=\&quot;http://groovetechnology.co.jp/webservice/\&quot; style=\&quot;color:pink;text-decoration:underline;\&quot;&gt;\u30B0\u30EB\u30FC\u30D6\u30C6\u30AF\u30CE\u30ED\u30B8\u30FC\x20Web\x20\u30B5\u30FC\u30D3\u30B9&lt;/a&gt;&lt;/div&gt;&quot;;
            pBlock.innerHTML = CmdUtils.renderTemplate(pTemplate, json);
        });
    }
});
</code></pre>
]]></content:encoded>
			<wfw:commentRss>http://www.serendip.ws/archives/171/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ubiquity（Firefox拡張機能）で翻訳する</title>
		<link>http://www.serendip.ws/archives/154</link>
		<comments>http://www.serendip.ws/archives/154#comments</comments>
		<pubDate>Wed, 03 Sep 2008 10:06:30 +0000</pubDate>
		<dc:creator>iNo</dc:creator>
				<category><![CDATA[blog]]></category>
		<category><![CDATA[firefox]]></category>

		<guid isPermaLink="false">http://www.serendip.ws/?p=154</guid>
		<description><![CDATA[コマンドを使ってWebサービスとのマッシュアップができる Firefox拡張機能 Ubiquity をインストールして使ってみた。 その中で翻訳機能が便利だったので紹介してみる。 ページ内の翻訳したい部分を選択する。 O [...]]]></description>
			<content:encoded><![CDATA[<p>コマンドを使ってWebサービスとのマッシュアップができる Firefox拡張機能 <a href="http://labs.mozilla.com/2008/08/introducing-ubiquity/" class="out">Ubiquity</a> をインストールして使ってみた。<br />
その中で翻訳機能が便利だったので紹介してみる。</p>
<ol>
<li>ページ内の翻訳したい部分を選択する。<br />
<img src="http://www.serendip.ws/wordpress/wp-content/uploads/fx_ubiquity_20080903-184900.png" alt="Firefox Ubiquity ScreenShot1" title="翻訳したい部分を選択" width="350" height="250" class="size-full wp-image-156" /></li>
<li><kbd>Option + Space</kbd>（Mac）、<kbd>Ctrl + Space</kbd>（Win）、<kbd>Alt + Space</kbd>（Linux）<ins datetime="2008-09-04T090800+09:00" title="2008-09-04T090800+09:00")>（Ubuntu ではウィンドウメニューが表示されてしまうので Ubuntu か Ubiquity どちらかのショートカットキーを設定変更しておくとよい）</ins>で Ubiquity のプロンプトを表示させ、コマンド <code>translate it to japanese</code> と入力するとプロンプト下部に翻訳結果が表示される。<br />
<img src="http://www.serendip.ws/wordpress/wp-content/uploads/fx_ubiquity_20080903-184901.png" alt="Firefox Ubiquity ScreenShot2" title="Ubiquity プロンプトで翻訳" width="500" height="350" class="size-full wp-image-158" /></li>
<li>さらに <kbd>Enter</kbd> を押すと、ページ内の選択部分が翻訳したい言語（日本語）に置き換わる。<br />
<img src="http://www.serendip.ws/wordpress/wp-content/uploads/fx_ubiquity_20080903-184902.png" alt="Firefox Ubiquity ScreenShot3" title="選択部分が日本語に変換される" width="350" height="250" class="size-full wp-image-160" /></li>
</ol>
<p>翻訳には Google翻訳 が使われている。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.serendip.ws/archives/154/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Vimでファイル保存時にFirefoxをリロードする(with MozLab)</title>
		<link>http://www.serendip.ws/archives/87</link>
		<comments>http://www.serendip.ws/archives/87#comments</comments>
		<pubDate>Sun, 13 Jul 2008 09:06:31 +0000</pubDate>
		<dc:creator>iNo</dc:creator>
				<category><![CDATA[blog]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[vim]]></category>

		<guid isPermaLink="false">http://www.serendip.ws/?p=87</guid>
		<description><![CDATA[以前作った vim script この記事(http://la.ma.la/blog/diary_200609280045.htm)を参考に、MozLab(http://dev.hyperstruct.net/trac/ [...]]]></description>
			<content:encoded><![CDATA[<p>以前作った <a href="http://d.hatena.ne.jp/iNo/20061005" class="out">vim script</a></p>
<blockquote><p>
この記事(http://la.ma.la/blog/diary_200609280045.htm)を参考に、MozLab(http://dev.hyperstruct.net/trac/mozlab)のMozReplを使って、Vimでファイル(*.html,*.htm,*.js,*.css)保存時にFirefoxをリロードするVimスクリプトを作ってみた。
</p></blockquote>
<p>を修正して、 vim が ruby, python, perl のいずれかが使えるようにコンパイルされていれば動作するようにしました。</p>
<p>どれも使えない場合は個別のスクリプトファイル(*.rb, *.py, *.pl)を使って動作させます。どれを使うかは reloadfirefox.vim を修正して選べます。（デフォルトは *.rb ）</p>
<p>reloadfirefox.vim</p>
<pre>if exists('g:reload_firefox')
    finish
endif

command -nargs=0 Setreloadfirefox :call SetMozreplReloadFirefox()

function! ReloadFirefox()
    if has('ruby')
        :ruby &lt;&lt;EOF
            require &quot;net/telnet&quot;

            telnet = Net::Telnet.new({
                &quot;Host&quot; =&gt; &quot;localhost&quot;,
                &quot;Port&quot; =&gt; 4242
            })

            telnet.puts(&quot;content.location.reload(true)\n&quot;)
            telnet.puts(&quot;repl.quit()\n&quot;)
            telnet.close
EOF
    elseif has('python')
        :python &lt;&lt;EOF
import telnetlib
HOST = &quot;localhost&quot;
PORT = 4242
telnet = telnetlib.Telnet(HOST, PORT)
telnet.read_until(&quot;repl&gt;&quot;)
telnet.write(&quot;content.location.reload(true)\n&quot;)
telnet.write(&quot;repl.quit()\n&quot;)
telnet.close()
EOF
    elseif has('perl')
        :perl &lt;&lt;EOF
            use strict;
            use warnings;
            use Net::Telnet;

            my $host = 'localhost';
            my $port = 4242;
            my $prompt = '/[repl&gt;]/';

            my $telnet = new Net::Telnet(
                Host =&gt; $host,
                Port =&gt; $port,
                Timeout =&gt; 10,
                Prompt =&gt; $prompt,
            );

            $telnet-&gt;open($host);
            $telnet-&gt;cmd(&quot;content.location.reload(true)\n&quot;);
            $telnet-&gt;cmd(&quot;repl.quit()\n&quot;);
            $telnet-&gt;close;
EOF
    else
        if has('gui_win32')
            &quot; for Windows
            let ruby_script_file = 'd:/cygwin/home/tom/bin/mozrepl_reload_firefox.rb'
        else
            &quot; for Mac, Linux, Cygwin
            let ruby_script_file = $HOME . '/bin/mozrepl_reload_firefox.rb'
        endif

        if filereadable(ruby_script_file)
            call system(ruby_script_file)
        else
            echo &quot;ERROR : File \&quot;&quot; . ruby_script_file . &quot;\&quot; is NOT found.&quot;
        endif
    endif
endfunction

function! SetMozreplReloadFirefox()
    if exists('g:reload_firefox')
        autocmd! mozreplreloadfirefox
        unlet g:reload_firefox
        echo &quot;\&quot;mozreplreloadfirefox\&quot; of augroup has been deleted.&quot;
    else
        augroup mozreplreloadfirefox
           autocmd BufWritePost *.html,*.htm,*.php,*.js,*.css call ReloadFirefox()
        augroup END
        let g:reload_firefox=1
        echo &quot;Firefox browser content is reloaded when file(*.html,*htm,*.php,*.js,*.css) is saved.&quot;
    endif
endfunction
</pre>
<p>mozrepl_reload_firefox.rb</p>
<pre>require &quot;net/telnet&quot;

telnet = Net::Telnet.new({
    &quot;Host&quot; =&gt; &quot;localhost&quot;,
    &quot;Port&quot; =&gt; 4242
})

telnet.puts(&quot;content.location.reload(true)\n&quot;)
telnet.puts(&quot;repl.quit()\n&quot;)
telnet.close
</pre>
<p>mozrepl_reload_firefox.py</p>
<pre>import telnetlib

HOST = &quot;localhost&quot;
PORT = 4242
telnet = telnetlib.Telnet(HOST, PORT)
telnet.read_until(&quot;repl&gt;&quot;)
telnet.write(&quot;content.location.reload(true)\n&quot;)
telnet.write(&quot;repl.quit()\n&quot;)
print telnet.read_all()
telnet.close()
</pre>
<p>mozrepl_reload_firefox.pl</p>
<pre>use strict;
use warnings;
use Net::Telnet;

my $host = 'localhost';
my $port = 4242;
my $prompt = '/[repl&gt;]/';

my $telnet = new Net::Telnet(
    Host =&gt; $host,
    Port =&gt; $port,
    Timeout =&gt; 10,
    Prompt =&gt; $prompt,
);

$telnet-&gt;open($host);
$telnet-&gt;cmd(&quot;content.location.reload(true)\n&quot;);
$telnet-&gt;cmd(&quot;repl.quit()\n&quot;);
$telnet-&gt;close;
</pre>
<p>ファイルにまとめたものがこちら <a href="/software/reload_fx_with_vim">&quot;Vimでファイル保存時にFirefoxをリロードする(with MozLab) &quot;</a> からダウンロードできます。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.serendip.ws/archives/87/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Greasemonkey で jQuery を利用する</title>
		<link>http://www.serendip.ws/archives/82</link>
		<comments>http://www.serendip.ws/archives/82#comments</comments>
		<pubDate>Sun, 06 Jul 2008 04:06:54 +0000</pubDate>
		<dc:creator>iNo</dc:creator>
				<category><![CDATA[blog]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://www.serendip.ws/?p=82</guid>
		<description><![CDATA[Greasemonkey Script で jQuery を利用するコードを使って Google イメージ検索画像をレイヤー上に表示 (Greasemonkey) を作った。]]></description>
			<content:encoded><![CDATA[<p><a class="out" href="http://wiki.greasespot.net/Code_snippets#Use_jQuery_in_a_GreaseMonkey_script">Greasemonkey Script で jQuery を利用するコード</a>を使って <a href="/software/gm_googleimagesearch">Google イメージ検索画像をレイヤー上に表示 (Greasemonkey)</a> を作った。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.serendip.ws/archives/82/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

