Commit Graph

11 Commits

Author SHA1 Message Date
Maxime Coste
fac222a427 Strongly typed options support
* non builtins options require declaration using the decl command

* At the moment, only int and string options are supported, however
the goal of this change is to provide a consistent way to support
more complex options, namely lists and booleans
2013-03-05 18:49:26 +01:00
Maxime Coste
7acd4e3e6a minor code cleanup 2013-01-06 21:58:02 +01:00
Maxime Coste
3b5530ac09 rename (hook|option)_manager to (hook|option)s.
And Global(Hook|Option)Manager to Global(Hook|Option)s
2012-11-22 13:50:29 +01:00
Maxime Coste
0ce6bd9bf5 use ByteCount instead of CharCount when we are really counting bytes
(that is most of the time when we are not concerned with displaying)
2012-10-11 00:41:48 +02:00
Maxime Coste
e4fd839dda use a strongly typed int CharCount for character counts 2012-08-23 23:56:35 +02:00
Maxime Coste
ecb3a737a9 Tweak String class, and cleanup usages
remove String::clear, add operator=(String&&) add str_to_int(const String&)
to replace atoi.
2012-06-27 14:26:29 +02:00
Maxime Coste
a943e08dc7 Refactor OptionManager, add OptionManagerWatcher
- use set_option to set an option, instead of operator[] (no-const)
- keeps a list of OptionManagerWatcher to notify when an option change
  it also notifies when an option changes in his parent and the option
  is not overridden.
2012-06-14 13:16:44 +00:00
Maxime Coste
20315eac85 replace Option::operator {String,int} with Option::as_{string,int} 2012-06-12 18:26:20 +00:00
Maxime Coste
9337938403 replace std::string references with String 2012-04-14 01:17:09 +00:00
Maxime Coste
46c65fea10 Option name completion support 2012-04-03 18:25:27 +00:00
Maxime Coste
f3dd65fbf1 add an OptionManager class and use it to manage tabstops
OptionManager map names to options, and may delegate option resolution
to it's parent if it does not contains the asked for option. That way
Buffers can override global options, and Windows can override Buffer
options.
2012-04-03 13:39:20 +00:00