Feature #11578

Option to pass whole arguments to a macro without splitting them

Added by Miko Kinski over 5 years ago. Updated over 5 years ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:Jean-Philippe Lang% Done:

0%

Category:Plugin API
Target version:2.1.0
Resolution:Fixed

Description

Why not passing the whole content of the macro to the exec_macro and let the macro developer decide whether or not he has any arguments or not which are separated by comma or something else. This Issue is also related to ongoing discussion #3061 of parsing complete macro text without exclusion.

Associated revisions

Revision 10174
Added by Jean-Philippe Lang over 5 years ago

Adds an option to macro definition to disable arguments parsing (#11578).

History

#1 Updated by Jean-Philippe Lang over 5 years ago

  • Subject changed from passing whole args in parse_macros without splitting them to Option to pass whole arguments to a macro without splitting them
  • Category set to Plugin API
  • Status changed from New to Closed
  • Assignee set to Jean-Philippe Lang
  • Target version set to 2.1.0
  • Resolution set to Fixed

Obviously, I can't change the current behaviour for compatibility reasons but an option :parse_args => false is added in r10174 to disable arguments parsing when registering a macro. Example:

macro :my_macro, :parse_args => false do |obj, args|
  # args is the whole string of arguments used to invoke the macro
end

Also available in: Atom PDF