From d216c0740666c761f23e0e4d846d6f7b3a45abe4 Mon Sep 17 00:00:00 2001 From: matusita Date: Sat, 10 May 2008 05:27:54 +0000 Subject: [PATCH] Add new option: fontsize and mobile_fontsize. Closes #12489. I don't know that the default value of fontsize to '+0' is safe or not. It seems that I can use '3' for that, but not sure. --- ChangeLog | 16 +++++++++++++++- etc/dot.keitairc | 6 +++++- lib/Keitairc/Config.pm | 5 ++++- lib/Keitairc/View.pm | 7 ++++++- lib/templates/404.html | 4 ++-- lib/templates/address.html | 4 ++-- lib/templates/all.html | 4 ++-- lib/templates/index.html | 4 ++-- lib/templates/location.html | 4 ++-- lib/templates/location_receiver.html | 4 ++-- lib/templates/login_icc.html | 6 ++++++ lib/templates/login_imodeid.html | 6 ++++++ lib/templates/mail.html | 4 ++-- lib/templates/nick.html | 4 ++-- lib/templates/phone.html | 4 ++-- lib/templates/postme.html | 4 ++-- lib/templates/recent.html | 4 ++-- lib/templates/root.html | 4 ++-- lib/templates/topic.html | 4 ++-- lib/templates/unread.html | 4 ++-- lib/templates/url.html | 4 ++-- lib/templates/url_session.html | 4 ++-- 22 files changed, 74 insertions(+), 36 deletions(-) diff --git a/ChangeLog b/ChangeLog index 2165d05..3833b5f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,18 @@ +2008-05-10 Makoto Matsushita + + * etc/dot.keitairc, lib/Keitairc/Config.pm, lib/Keitairc/View.pm, + lib/templates/404.html, lib/templates/address.html, + lib/templates/all.html, lib/templates/index.html, + lib/templates/location.html, lib/templates/location_receiver.html, + lib/templates/login_icc.html, lib/templates/login_imodeid.html, + lib/templates/mail.html, lib/templates/nick.html, + lib/templates/phone.html, lib/templates/postme.html, + lib/templates/recent.html, lib/templates/root.html, + lib/templates/topic.html, lib/templates/unread.html, + lib/templates/url.html, lib/templates/url_session.html: HTML$BI=<($N(B + $B:]!$%U%)%s%H%5%$%:$r@_Dj%U%!%$%kFb$G;XDj$G$-$k$h$&$K$9$k!%(B + Closes #12489. + 2008-05-09 Makoto Matsushita * keitairc, lib/Keitairc/IrcCallback.pm, lib/plugins/00all, @@ -18,7 +33,6 @@ * lib/plugins/00location_receiver: GPS$BEy$K$h$C$FF@$i$l$?0^EY7PEY$+(B $B$i!$8=:_CO$N=;=j$rD4$Y$?7k2L$NJ8;zNs$,J8;z2=$1$7$F$$$?!%(B Closes #12486. - 2008-05-08 Makoto Matsushita diff --git a/etc/dot.keitairc b/etc/dot.keitairc index 84b395a..f9d8918 100644 --- a/etc/dot.keitairc +++ b/etc/dot.keitairc @@ -1,7 +1,7 @@ # # sample ~/.keitairc for keitairc 2.x # -# $Id: dot.keitairc,v 1.12 2008-05-08 14:46:14 matusita Exp $ +# $Id: dot.keitairc,v 1.13 2008-05-10 05:27:54 matusita Exp $ # $Source: /home/ishikawa/work/keitairc/tmp/keitairc/etc/dot.keitairc,v $ ################################################################ @@ -79,6 +79,10 @@ web_password = 1234 # Keyword # irc_keyword = "mynick,myfavoriteword" +# Font size +# fontsize = 0 +# mobile_fontsize = -1 + # By default, channel messages are shown in reverse order. # Set to these value to '0' to disable. # reverse_message = 0 diff --git a/lib/Keitairc/Config.pm b/lib/Keitairc/Config.pm index 8b4455e..066b93d 100644 --- a/lib/Keitairc/Config.pm +++ b/lib/Keitairc/Config.pm @@ -1,6 +1,6 @@ # -*-perl-*- # Keitairc::Config -# $Id: Config.pm,v 1.12 2008-05-08 14:46:14 matusita Exp $ +# $Id: Config.pm,v 1.13 2008-05-10 05:27:54 matusita Exp $ # $Source: /home/ishikawa/work/keitairc/tmp/keitairc/lib/Keitairc/Config.pm,v $ # # Copyright (c) 2008 Jun Morimoto @@ -32,6 +32,7 @@ sub new{ use_cookie cookie_ttl session_ttl web_port web_title web_lines web_root web_username web_password web_host + fontsize mobile_fontsize show_newmsgonly show_joinleave show_console ping_delay reconnect_delay smtp_server smtp_from smtp_to debug @@ -59,6 +60,8 @@ sub new{ $me->reverse_recent(1); $me->reverse_unread(1); $me->show_joinleave(1); + $me->fontsize('+0'); + $me->mobile_fontsize(-1); if(defined $argv[0]){ unless(-e $argv[0]){ diff --git a/lib/Keitairc/View.pm b/lib/Keitairc/View.pm index 8903034..cc51b6e 100644 --- a/lib/Keitairc/View.pm +++ b/lib/Keitairc/View.pm @@ -1,6 +1,6 @@ # -*-perl-*- # Keitairc::View -# $Id: View.pm,v 1.10 2008-05-08 14:32:58 matusita Exp $ +# $Id: View.pm,v 1.11 2008-05-10 05:27:54 matusita Exp $ # $Source: /home/ishikawa/work/keitairc/tmp/keitairc/lib/Keitairc/View.pm,v $ # # Copyright (c) 2008 Jun Morimoto @@ -67,6 +67,11 @@ sub template{ $p->{root} = $me->{Config}->web_root(); $p->{title} = $me->{Config}->web_title(); $p->{version} = $me->{Config}->version(); + if($me->{ClientInfo}->is_mobile){ + $p->{fontsize} = $me->{Config}->mobile_fontsize(); + }else{ + $p->{fontsize} = $me->{Config}->fontsize(); + } $p->{timestamp} = timestamp(); $p->{viewport} = $me->{ClientInfo}->is_ipod(); diff --git a/lib/templates/404.html b/lib/templates/404.html index ecea371..399bc4e 100644 --- a/lib/templates/404.html +++ b/lib/templates/404.html @@ -10,7 +10,7 @@ - + 404: No such action ()

@@ -19,7 +19,7 @@
keitairc -
+
diff --git a/lib/templates/address.html b/lib/templates/address.html index 84c411a..5519b91 100644 --- a/lib/templates/address.html +++ b/lib/templates/address.html @@ -10,7 +10,7 @@ - + ZŠ‚ðGoogle Maps‚Å•\Ž¦
@@ -35,7 +35,7 @@
keitairc -
+
diff --git a/lib/templates/all.html b/lib/templates/all.html index 8649701..bca0dc0 100644 --- a/lib/templates/all.html +++ b/lib/templates/all.html @@ -10,7 +10,7 @@ - + ‚Ì”­Œ¾
@@ -43,7 +43,7 @@
keitairc -
+
diff --git a/lib/templates/index.html b/lib/templates/index.html index 38f274b..affffa1 100644 --- a/lib/templates/index.html +++ b/lib/templates/index.html @@ -12,7 +12,7 @@ - + Á¬ÈÙؽÄ
@@ -49,7 +49,7 @@
keitairc -
+
diff --git a/lib/templates/location.html b/lib/templates/location.html index ec220e0..5ddd3e3 100644 --- a/lib/templates/location.html +++ b/lib/templates/location.html @@ -10,7 +10,7 @@ - + ‚ֈʒuî•ñ‚ð”­Œ¾
@@ -35,7 +35,7 @@
keitairc -
+
diff --git a/lib/templates/location_receiver.html b/lib/templates/location_receiver.html index ad8ac9e..4ee25dc 100644 --- a/lib/templates/location_receiver.html +++ b/lib/templates/location_receiver.html @@ -10,7 +10,7 @@ - + ‚ֈʒuî•ñ‚ð”­Œ¾
@@ -47,7 +47,7 @@
keitairc -
+
diff --git a/lib/templates/login_icc.html b/lib/templates/login_icc.html index fa71029..f023a0c 100644 --- a/lib/templates/login_icc.html +++ b/lib/templates/login_icc.html @@ -9,6 +9,9 @@ <!-- tmpl_var title -->: icc•\Ž¦ + + + ‚ ‚È‚½‚ÌFOMA¶-ÄނÌicc‚Í“o˜^‚³‚ê‚Ä‚¢‚Ü‚¹‚ñB icc”ԍ†‚ðºËß-
@@ -17,5 +20,8 @@

keitairc + +
+ diff --git a/lib/templates/login_imodeid.html b/lib/templates/login_imodeid.html index a48e19f..1849563 100644 --- a/lib/templates/login_imodeid.html +++ b/lib/templates/login_imodeid.html @@ -9,6 +9,9 @@ <!-- tmpl_var title -->: icc•\Ž¦ + + + ‚ ‚È‚½‚ÌiÓ-ÄÞID‚Í“o˜^‚³‚ê‚Ä‚¢‚Ü‚¹‚ñB iÓ-ÄÞID‚ðºËß-
@@ -17,5 +20,8 @@

keitairc + +
+ diff --git a/lib/templates/mail.html b/lib/templates/mail.html index 48bc294..a0e3ba4 100644 --- a/lib/templates/mail.html +++ b/lib/templates/mail.html @@ -10,7 +10,7 @@ - + Ò-Ù±ÄÞÚ½
@@ -28,7 +28,7 @@
keitairc -
+
diff --git a/lib/templates/nick.html b/lib/templates/nick.html index 3ea99cd..511a732 100644 --- a/lib/templates/nick.html +++ b/lib/templates/nick.html @@ -12,7 +12,7 @@ - + ‚ÉŽQ‰Á’†‚Ìnick
@@ -27,7 +27,7 @@
keitairc -
+
diff --git a/lib/templates/phone.html b/lib/templates/phone.html index c6f1769..21b1467 100644 --- a/lib/templates/phone.html +++ b/lib/templates/phone.html @@ -10,7 +10,7 @@ - + “d˜b”ԍ†
@@ -31,7 +31,7 @@
keitairc -
+
diff --git a/lib/templates/postme.html b/lib/templates/postme.html index d228dee..bbba727 100644 --- a/lib/templates/postme.html +++ b/lib/templates/postme.html @@ -10,7 +10,7 @@ - + @@ -32,7 +32,7 @@
keitairc -
+
diff --git a/lib/templates/recent.html b/lib/templates/recent.html index 7db559b..014eb74 100644 --- a/lib/templates/recent.html +++ b/lib/templates/recent.html @@ -10,7 +10,7 @@ - + –¢“Ç”­Œ¾ˆê——
@@ -20,7 +20,7 @@
keitairc -
+
diff --git a/lib/templates/root.html b/lib/templates/root.html index c38f2ac..9af2f2b 100644 --- a/lib/templates/root.html +++ b/lib/templates/root.html @@ -10,7 +10,7 @@ - + @@ -38,7 +38,7 @@
keitairc -
+
diff --git a/lib/templates/topic.html b/lib/templates/topic.html index e18dce2..5934606 100644 --- a/lib/templates/topic.html +++ b/lib/templates/topic.html @@ -10,7 +10,7 @@ - + ÄË߯¸ˆê——
@@ -20,7 +20,7 @@
keitairc -
+
diff --git a/lib/templates/unread.html b/lib/templates/unread.html index 3ba7b70..5e2e8d9 100644 --- a/lib/templates/unread.html +++ b/lib/templates/unread.html @@ -10,7 +10,7 @@ - + ‚Ì–¢“Ç”­Œ¾
@@ -44,7 +44,7 @@
keitairc -
+
diff --git a/lib/templates/url.html b/lib/templates/url.html index cf900cd..aaf2ebf 100644 --- a/lib/templates/url.html +++ b/lib/templates/url.html @@ -10,7 +10,7 @@ - +
@@ -42,7 +42,7 @@
keitairc -
+
diff --git a/lib/templates/url_session.html b/lib/templates/url_session.html index 6214f89..253ce6b 100644 --- a/lib/templates/url_session.html +++ b/lib/templates/url_session.html @@ -10,7 +10,7 @@ - +
@@ -26,7 +26,7 @@
keitairc -
+
-- 2.11.0