~ubuntu-branches/ubuntu/wily/tdiary/wily

« back to all changes in this revision

Viewing changes to misc/plugin/sn.rb

  • Committer: Bazaar Package Importer
  • Author(s): Daigo Moriwaki
  • Date: 2011-04-11 21:53:16 UTC
  • mfrom: (1.2.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20110411215316-ih4gt4q8p29d2wf8
Tags: 3.0.1-1
* New upstream release (Closes: #542801, #594947)
* debian/control:
 - Bumped up Standards-Version to 3.9.1.
 - Updated version dependency.
* debian/tdiary-setup.rb: Followed the upstream changes, incorporating js and
  index.fcgi

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# -*- coding: utf-8 -*-
1
2
=begin
2
 
= Ϣ�������ץ饰���� sn.rb $Revision: 1.3 $
3
 
 
4
 
== ����
5
 
        �����դ���������̤��ֹ��ɽ�����ޤ���
6
 
 
7
 
== �Ȥ���
 
3
= 連番生成プラグイン sn.rb
 
4
 
 
5
== 概要
 
6
        各日付の日記内で通し番号を表示します。
 
7
 
 
8
== 使い方
8
9
        sn( number )
9
 
                number - ���������󥿤���ꤷ���ͤ˥��åȤ��ޤ���
 
10
                number - 内部カウンタを指定した値にセットします。
10
11
        sn_anchorid
11
12
 
12
 
        sn()�᥽�åɤ������γ����դ��Ȥˡ�1����Ϥޤ��̤��ֹ��ɽ�����ޤ���
13
 
 
14
 
        sn_anchorid()�᥽�åɤϸ��ߤΥ��󥫡�id���ֹ��ɽ�����ޤ���
15
 
        sn_anchorid()�����ꥪ�ץ������Υ��������/�ĥå��ߥ��󥫡�
16
 
        �Ȥ��ƻ��ꤹ�뤳�Ȥˤ�äơ����Υ��������/�ĥå��ߥ��󥫡���
17
 
        URL�ȷ���դ������ͤ�ɽ�����뤳�Ȥ��Ǥ��ޤ���
18
 
 
19
 
== ����
20
 
        anchor()��zoe����number_anchor.rb�򻲹ͤ˺������ޤ�����
 
13
        sn()メソッドは日記の各日付ごとに、1から始まる通し番号を表示します。
 
14
 
 
15
        sn_anchorid()メソッドは現在のアンカーidの番号を表示します。
 
16
        sn_anchorid()を設定オプション内のセクション/ツッコミアンカー
 
17
        として指定することによって,そのセクション/ツッコミアンカーの
 
18
        URLと結び付いた数値を表示することができます。
 
19
 
 
20
== 参考
 
21
        anchor()はzoe氏作のnumber_anchor.rbを参考に作成しました。
21
22
 
22
23
= Sequential number generator plugin
23
24
== Abstract
39
40
== reference
40
41
        Original anchor() appeared in the number_anchor.rb by zoe-san.
41
42
 
42
 
== ����ˤĤ��� (Copyright notice)
 
43
== 著作権について (Copyright notice)
43
44
        Copyright (c) 2003 SAKAMOTO Hideki <hs@on-sky.net>
44
45
        Distributed under the GPL
45
46
=end
97
98
def sn_anchorid
98
99
        %Q[#{'%d' % @sn_idx}]
99
100
end
 
101
 
 
102
# Local Variables:
 
103
# mode: ruby
 
104
# indent-tabs-mode: t
 
105
# tab-width: 3
 
106
# ruby-indent-level: 3
 
107
# End: