Skip to content

Instantly share code, notes, and snippets.

@uupaa
uupaa / irc.mac.remove.quit.md
Last active June 27, 2024 15:17
Remove message(joined, left, quit) for Limechat Mac

IRC クライアント Limechat for Mac で joined, left, quit メッセージを消す方法

/Applications/LimeChat.app/Contents/Themes/Limelight.css に以下のCSSを追加。
他のテーマを使っている場合は、そのテーマのcssを編集。

.line[type=join] { display:none; }
.line[type=quit] { display:none; }
.line[type=mode] { display:none; }
.line[type=part] { display:none; }
@uupaa
uupaa / walk.out.md
Last active December 21, 2015 17:49
The old browser walk out of the stage.

Android 2.3.x の退場

2013-08-25 時点のAndroid 2.3.x(Gingerbread)のシェアは33%です。 Android 2.3.x が退場すると、JavaScriptの世界ではこのような変化が訪れます。

以下の機能が利用可能になります。

  • XHR Lv2
  • Web Font
  • WebP
@uupaa
uupaa / jj.md
Last active December 21, 2015 19:19
put styled json with key sort

// jj

#!/usr/local/bin/node

var argv = process.argv.slice(2);

if (argv.length) {
    var json = JSON.parse(require("fs").readFileSync(argv.shift(), "utf8"));
    var result = {};
@uupaa
uupaa / ted1.md
Last active December 21, 2015 20:38
TED: ダン・アリエリー:「我々は本当に自分で決めているのか?」 意思決定の錯覚

TED: ダン・アリエリー:我々は本当に自分で決めているのか?

http://www.ted.com/talks/dan_ariely_asks_are_we_in_control_of_our_own_decisions.html

「予想通りに不合理」の著者である、行動経済学者ダン・アリエリーは昔ながらの視覚的錯覚や彼独自の思いもよらぬ(時にショッキングな)研究結果を用い、人が何かを決断する際、自分で思っているほど合理的ではないことを証明します。

意思決定の錯覚 について

スピーカーは、視覚のトリック(錯覚)について例を示し、次に臓器提供の意思表示について国ごとに大きな差があることを紹介します。
ではその差はどこからくるか? 何が起きているのか?

@uupaa
uupaa / iOS7.changeset.md
Last active December 21, 2015 22:19
iOS7 changeset

iOS 7 に該当する WebKit Changeset(151723 - 152697) を調査しました

Summary

  • 151951 Add support for document.currentScript
  • 151914 WaveTable name has changed to PeriodicWave
  • 149173 mouseenter, mouseleave イベントのサポート
  • 149159 Math.imul のサポート
  • 151298 canvas#supportsContext のサポート
  • 151558 WebAudio にユーザイベントを経由せず noteOn した場合に音が鳴らないように制限を追加(in iOS)
  • 151101 AudioBufferSourceNode の "onended" イベントのサポート
@uupaa
uupaa / canvas.toDataURL.image.webp.md
Last active April 11, 2021 13:37
canvas.toDataURL("image/webp");
<canvas id="canvas"></canvas>
<script>
var ctx = canvas.getContext("2d");
ctx.fillStyle = "red";
ctx.fillRect(0, 0, 8, 8);

var webp = canvas.toDataURL("image/webp"); // Chrome only?
var png  = canvas.toDataURL("image/png");
var jpg = canvas.toDataURL("image/jpeg");
@uupaa
uupaa / _mix.md
Last active December 22, 2015 15:19
_mix
function _mix(base,     // @arg Object/Function: source object
              extend) { // @arg Object/Function: target object
                        // @ret Object/Function: source object
    for (var key in extend) {
        if (extend[key].constructor === Object) {
            base[key] || (base[key] = extend);
            _mix(base[key], extend[key]);
        } else {
 base[key] = extend[key];
@uupaa
uupaa / ios.xcode.md
Last active January 28, 2020 09:36
iOS device spec, versions and Xcode deployment target information

iOS Devices

Device CPU GPU Display OpenGL
iPod touch 4 A4 PowerVR SGX535 960 x 640 2.1
iPod touch 5 A5 PowerVR SGX543MP2 1136 x 640 2.1
iPad 1 A4 PowerVR SGX535 1024 x 768 2.1
iPad 2 A5 PowerVR SGX543MP2 1024 x 768 2.1
iPad 3 A5X PowerVR SGX543MP4 2048 x 1536 2.1
iPad 4 A6X PowerVR SGX554MP4 2048 x 1536 2.1
@uupaa
uupaa / js.interface.implements.md
Created September 17, 2013 17:25
js.interface.implements
Class Xxx implements XxxInterface {
}
function implements(Class, Interface, properties) {
    for (var key in properties) {
        Class.prototype[key] = properties[key];
    }
@uupaa
uupaa / PPAPI.md
Last active December 23, 2015 19:09
PPAPI detection
function enumPPAPIBrowserPlugins() {
    return Array.apply(null, navigator.plugins).filter(function(plugin) {
        return /Pepper/i.test(plugin.filename);
    }).map(function(plugin) {
        return plugin.description;
    });
}

enumPPAPIBrowserPlugins().join(","); // "Shockwave Flash 11.8 r800"