Class: Deplate::Symbols
Class Method Summary
collapse
Instance Method Summary
collapse
class_attribute, class_attributes, class_attributes=, class_attributes_ensure, class_meta_attributes, inherited, method_missing, respond_to?
Constructor Details
#initialize(deplate) ⇒ Symbols
Returns a new instance of Symbols.
211
212
213
214
|
# File 'lib/deplate/etc.rb', line 211
def initialize(deplate)
@deplate = deplate
@formatter = @deplate.formatter
end
|
Class Method Details
.hook_post_myname=(name) ⇒ Object
199
200
201
202
|
# File 'lib/deplate/etc.rb', line 199
def hook_post_myname=(name)
klass = self
Deplate::Core.declare_symbols(name, klass)
end
|
.register_as(*names) ⇒ Object
204
205
206
207
208
|
# File 'lib/deplate/etc.rb', line 204
def register_as(*names)
for n in names
hook_post_myname=(n)
end
end
|
Instance Method Details
#doublequote_close(invoker) ⇒ Object
236
237
238
|
# File 'lib/deplate/etc.rb', line 236
def doublequote_close(invoker)
%{"}
end
|
#doublequote_open(invoker) ⇒ Object
232
233
234
|
# File 'lib/deplate/etc.rb', line 232
def doublequote_open(invoker)
%{"}
end
|
256
257
258
|
# File 'lib/deplate/etc.rb', line 256
def format_symbol(invoker, sym)
return @formatter.plain_text(sym)
end
|
#nonbreakingspace(invoker) ⇒ Object
248
249
250
|
# File 'lib/deplate/etc.rb', line 248
def nonbreakingspace(invoker)
%{ }
end
|
#singlequote_close(invoker) ⇒ Object
244
245
246
|
# File 'lib/deplate/etc.rb', line 244
def singlequote_close(invoker)
%{'}
end
|
#singlequote_open(invoker) ⇒ Object
240
241
242
|
# File 'lib/deplate/etc.rb', line 240
def singlequote_open(invoker)
%{'}
end
|
#symbol_amp(invoker) ⇒ Object
228
229
230
|
# File 'lib/deplate/etc.rb', line 228
def symbol_amp(invoker)
"&"
end
|
#symbol_gt(invoker) ⇒ Object
220
221
222
|
# File 'lib/deplate/etc.rb', line 220
def symbol_gt(invoker)
">"
end
|
#symbol_lt(invoker) ⇒ Object
224
225
226
|
# File 'lib/deplate/etc.rb', line 224
def symbol_lt(invoker)
"<"
end
|
#symbol_paragraph(invoker) ⇒ Object
252
253
254
|
# File 'lib/deplate/etc.rb', line 252
def symbol_paragraph(invoker)
%{§}
end
|
#symbol_quote(invoker) ⇒ Object
216
217
218
|
# File 'lib/deplate/etc.rb', line 216
def symbol_quote(invoker)
'"'
end
|