Class: SistemKebut::Paragraph::Formulir
- Inherits:
-
DefPengelolaXML
- Object
- KebutSemalam::PengelolaXML
- DefPengelolaXML
- SistemKebut::Paragraph::Formulir
- Includes:
- InnerParagraph
- Defined in:
- lib/sks/paragraph/formulir.rb
Direct Known Subclasses
Defined Under Namespace
Classes: UnitFormulir
Instance Attribute Summary collapse
-
#align ⇒ Object
Returns the value of attribute align.
-
#bold ⇒ Object
Returns the value of attribute bold.
-
#fsize ⇒ Object
Returns the value of attribute fsize.
-
#fstyle ⇒ Object
Returns the value of attribute fstyle.
-
#italic ⇒ Object
Returns the value of attribute italic.
-
#konten ⇒ Object
Returns the value of attribute konten.
-
#masuk ⇒ Object
Returns the value of attribute masuk.
-
#mode ⇒ Object
Returns the value of attribute mode.
-
#spacing ⇒ Object
Returns the value of attribute spacing.
-
#tabsize ⇒ Object
Returns the value of attribute tabsize.
-
#underline ⇒ Object
Returns the value of attribute underline.
Instance Method Summary collapse
- #[](id) ⇒ Object
-
#initialize(ts, ukuran) ⇒ Formulir
constructor
A new instance of Formulir.
- #tambah(l, v) ⇒ Object
- #tiap(&block) ⇒ Object
Methods included from InnerParagraph
#gandakan_spacing, #kecilkan_spacing, #struktur, #ubah_ukuran
Methods inherited from DefPengelolaXML
Methods inherited from KebutSemalam::PengelolaXML
Constructor Details
#initialize(ts, ukuran) ⇒ Formulir
Returns a new instance of Formulir.
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'lib/sks/paragraph/formulir.rb', line 17 def initialize(ts, ukuran) @mode = :normal @fstyle = TNR @fsize = 22 @masuk = false @bold = false @italic = false @underline = false @spacing = :normal @align = :both @konten = [] @tabsize = ts ubah_ukuran(ukuran) kecilkan_spacing end |
Instance Attribute Details
#align ⇒ Object
Returns the value of attribute align.
14 15 16 |
# File 'lib/sks/paragraph/formulir.rb', line 14 def align @align end |
#bold ⇒ Object
Returns the value of attribute bold.
15 16 17 |
# File 'lib/sks/paragraph/formulir.rb', line 15 def bold @bold end |
#fsize ⇒ Object
Returns the value of attribute fsize.
14 15 16 |
# File 'lib/sks/paragraph/formulir.rb', line 14 def fsize @fsize end |
#fstyle ⇒ Object
Returns the value of attribute fstyle.
14 15 16 |
# File 'lib/sks/paragraph/formulir.rb', line 14 def fstyle @fstyle end |
#italic ⇒ Object
Returns the value of attribute italic.
15 16 17 |
# File 'lib/sks/paragraph/formulir.rb', line 15 def italic @italic end |
#konten ⇒ Object
Returns the value of attribute konten.
14 15 16 |
# File 'lib/sks/paragraph/formulir.rb', line 14 def konten @konten end |
#masuk ⇒ Object
Returns the value of attribute masuk.
14 15 16 |
# File 'lib/sks/paragraph/formulir.rb', line 14 def masuk @masuk end |
#mode ⇒ Object
Returns the value of attribute mode.
16 17 18 |
# File 'lib/sks/paragraph/formulir.rb', line 16 def mode @mode end |
#spacing ⇒ Object
Returns the value of attribute spacing.
15 16 17 |
# File 'lib/sks/paragraph/formulir.rb', line 15 def spacing @spacing end |
#tabsize ⇒ Object
Returns the value of attribute tabsize.
16 17 18 |
# File 'lib/sks/paragraph/formulir.rb', line 16 def tabsize @tabsize end |
#underline ⇒ Object
Returns the value of attribute underline.
15 16 17 |
# File 'lib/sks/paragraph/formulir.rb', line 15 def underline @underline end |
Instance Method Details
#[](id) ⇒ Object
33 34 35 |
# File 'lib/sks/paragraph/formulir.rb', line 33 def [](id) @konten[id] end |
#tambah(l, v) ⇒ Object
41 42 43 44 |
# File 'lib/sks/paragraph/formulir.rb', line 41 def tambah(l, v) @konten.push(UnitFormulir.new(l, v)) return nil end |
#tiap(&block) ⇒ Object
37 38 39 |
# File 'lib/sks/paragraph/formulir.rb', line 37 def tiap(&block) @konten.each(&block) end |