This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=320,user-scalable=no"> | |
| <style> | |
| body { | |
| margin: 0; | |
| padding: 0; | |
| height: 3000px; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Parser for KNB corpus (http://nlp.ist.i.kyoto-u.ac.jp/kuntt/#ga739fe2) | |
| # | |
| # Copyright 2012- Takeshi Arabiki | |
| # License: MIT License (http://opensource.org/licenses/MIT) | |
| # | |
| # Example: | |
| # | |
| # # KNB コーパスを data ディレクトリ下にダウンロードして解凍 | |
| # # 返り値は解凍後のファイル名 | |
| # dir <- KNB$downloadCorpus("data") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import "js/web.jsx"; | |
| class History { | |
| function a() : void { | |
| History.b(); | |
| } | |
| static function b() : void { | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| # -* - coding: utf-8 -*- | |
| import argparse | |
| import inspect | |
| import eyed3 | |
| import eyed3.id3 | |
| def convertID3Encoding(audiofile, backup = False): | |
| tag = audiofile.tag | |
| if not tag: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #--------------------------------------------------------------------- | |
| # MessagePack for R (support only unpack) | |
| # | |
| # Copyright 2013- Takeshi Arabiki | |
| # License: MIT License (http://opensource.org/licenses/MIT) | |
| # | |
| # > source("msgpack.R") | |
| # > msgpack$unpack("\x93\x01\x02\x03") | |
| # [1] 1 2 3 | |
| # > msgpack$unpack(c(charToRaw("\xCD\x01"), as.raw(0x00))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (setq x-select-enable-clipboard t) | |
| (defun copy-from-clipboard (text &optional rest) | |
| (let ((process-connection-type nil) proc) | |
| (if (eq system-type 'darwin) | |
| (setq proc (start-process "pbcopy" "*Messages*" "pbcopy")) | |
| (setq proc (start-process "xsel" "*Messages*" "xsel" "-b" "-i"))) | |
| (process-send-string proc text) | |
| (process-send-eof proc))) | |
| (defun paste-from-clipboard () |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Copyright 2012- Takeshi Arabiki | |
| * License: MIT License (http://opensource.org/licenses/MIT) | |
| */ | |
| (function() { | |
| CanvasRenderingContext2D.prototype._transform = [1, 0, 0, 1, 0, 0]; | |
| CanvasRenderingContext2D.prototype._transforms = []; | |
| CanvasRenderingContext2D.prototype.getTransform = function() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import "js/web.jsx"; | |
| class Util { | |
| static function image2Canvas(image : HTMLImageElement) : HTMLCanvasElement { | |
| var document = dom.window.document; | |
| var canvas = document.createElement("canvas") as HTMLCanvasElement; | |
| canvas.width = image.width; | |
| canvas.height = image.height; | |
| var ctx = canvas.getContext("2d") as CanvasRenderingContext2D; | |
| ctx.drawImage(image, 0, 0); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff --git auto-complete.el auto-complete.el | |
| index 286c2d4..7a7b418 100644 | |
| --- auto-complete.el | |
| +++ auto-complete.el | |
| @@ -841,7 +841,8 @@ You can not use it in source definition like (prefix . `NAME')." | |
| (eval prefix)))) | |
| (if (and point | |
| (integerp req) | |
| - (< (- current point) req)) | |
| + (< (- current point) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ;;; ~/.emacs.d/init.el | |
| ;;;--------------------------------- | |
| ;;; 基本設定 | |
| ;;;--------------------------------- | |
| ;; 自分でダウンロードした *.el, *.elc のディレクトリ | |
| (setq my-site-lisp (expand-file-name "~/.emacs.d/site-lisp")) | |
| ;; my-site-lisp を load-path に追加 | |
| (add-to-list 'load-path my-site-lisp) | |
| ;; 起動メッセージを表示しない | |
| (setq inhibit-startup-message t) |