Skip to content

Instantly share code, notes, and snippets.

diff --git a/data/charwidths.jl b/data/charwidths.jl
index bdcbc6c..25d8d9f 100644
--- a/data/charwidths.jl
+++ b/data/charwidths.jl
@@ -111,7 +111,7 @@ for line in readlines(open("EastAsianWidth.txt"))
#Assign widths
for c in charstart:charend
- if width=="W" || width=="F" # wide or full
+ if width=="W" || width=="F" || width=="A" # wide or full
diff --git a/data/charwidths.jl b/data/charwidths.jl
index bdcbc6c..25d8d9f 100644
--- a/data/charwidths.jl
+++ b/data/charwidths.jl
@@ -111,7 +111,7 @@ for line in readlines(open("EastAsianWidth.txt"))
#Assign widths
for c in charstart:charend
- if width=="W" || width=="F" # wide or full
+ if width=="W" || width=="F" || width=="A" # wide or full
@atton
atton / tmux-2.2-setlocale-ja_JP.UTF-8.txt
Last active August 23, 2016 02:51
Set locale for tmux 2.2
diff --git tmux.c tmux.c
index cf82110..d2c57b8 100644
--- tmux.c
+++ tmux.c
@@ -193,12 +193,7 @@ main(int argc, char **argv)
int opt, flags, keys;
if (setlocale(LC_CTYPE, "en_US.UTF-8") == NULL) {
- if (setlocale(LC_CTYPE, "") == NULL)
- errx(1, "invalid LC_ALL, LC_CTYPE or LANG");
@atton
atton / 20160815_GuP.md
Last active August 14, 2016 10:45
ガルパン上映会日程

ガルパン上映会 in 611

時間 予定
13:00 - 15:15 TV版 1-6話
15:15 - 15:30 休憩
15:30 - 17:45 TV版 7-12話
17:45 - 18:30 OVA
18:30 - 19:30 晩御飯
19:30 - 21:30 劇場版
package main
import "fmt"
import "time"
func yo(c chan int) {
fmt.Printf("%d\n", <-c)
}
func main() {
c := make(chan int, 0) // dead lock
@atton
atton / dhcp.global
Created December 23, 2015 09:48
FreeRADIUS dhcp configuration example which supports multiple interfaces
server dhcp.ens6 {
listen {
type = dhcp
ipaddr = *
port = 67
interface = ens6
broadcast = yes
performance {
skip_duplicate_checks = yes
}
@atton
atton / tmux-ambiguous-width-cjk.patch
Last active August 29, 2015 14:21 — forked from waltarix/tmux-do-not-combine-utf8.patch
Fix tmux character width of east asian ambiguous optimized for Ricty 3.2.4
diff --git a/utf8.c b/utf8.c
index 63723d7..05ae973 100644
--- a/utf8.c
+++ b/utf8.c
@@ -194,7 +194,193 @@ struct utf8_width_entry utf8_width_table[] = {
{ 0x10a05, 0x10a06, 0, NULL, NULL },
};
+/* Random order */
+struct utf8_width_entry utf8_cjkwidth_table[] = {
@atton
atton / .pryrc
Last active January 4, 2016 19:53
crash logs pry-rails saved multibyte characters into history with rb-readline
Pry.history.instance_eval do
@saver = ->(line) { save_to_file (line.force_encoding(STDIN.external_encoding))}
end
@atton
atton / hash_keys.rb
Created March 18, 2015 12:53
hash keys
#!/usr/bin/env ruby
=begin
[30] pry(main)> a.class.ancestors
=> [Twitter::NullObject,
Twitter::NullObject::Customizations,
Comparable,
Twitter::NullObject::GeneratedMethods,
Naught::NullObjectTag,
Naught::Conversions,
@atton
atton / Makefile
Created March 1, 2015 02:38
Escape Agda for LaTeX
# Settings
TARGET=escape_agda
SOURCES=$(wildcard *.agda)
SOURCES_FOR_TEX=$(subst .agda,.eagda,$(SOURCES))
# dependencies
$(TARGET).pdf : $(TARGET).dvi
dvipdfmx $<