Uncrustify: where do the Spaces options work

# Uncrustify: Where do the options work?

## Spaces

You want to "add/ force/ ignore/ remove" a

- space for assign
- space for byref
- space for case
- space for cast
- space for class
- space for comma
- space for enum
- space for for loop
- space for new/ delete
- space for operator
- space for parenthesis
- space for template

at some places.

Some more options...

    // Comments
      ^
    int a;            /* emb cmt */ int b;            // trailing cmt
          ^..........^                    ^..........^

        union {
            uint maxChars;
            uint maxBytes;
        } mLength;
        union { int m_size; int m_any; };
               ^                      ^
        return { -1, -1, -1 };
                ^          ^

    class Parser :: ParserPrivate { };
                ^  ^               ^
    template <typename T> class to { };
                                    ^
    my $all = { };
               ^
    enum FocusEffect { };
                      ^
    struct error { };
                  ^
    };

    #define LOG_FMT (sev, args ...) \
                   ^          ^
       do { if (log_sev_on(sev)) { log_fmt(sev, ## args); } } while (0)
                                               ^  ^
    #endif
    #define FS_NOCOW_FL 0x00800000
                       ^
    #define STRHACK(x) HACKSTR(x)
                 ^
    #define wakeUpCaller(cond) \
                              ^
        if (cond) { \
                   ^
            cond->release(); \
                            ^
         }
    typedef struct { int val; int sel; } DiceInfo;
                                        ^
    void * bar()
        ^ ^
    {
        int a = 5;
             ^ ^
             ^ ^
        c = a + b;
             ^ ^
        a = ~ b;
             ^
        x = - 5;
             ^
        y = + 7;
             ^
        (-- a);
           ^
        i ++;
         ^
        b = ( a == d ) ? 55 : 88;
                      ^ ^  ^ ^
                      ^ ^  ^ ^
        b = ( a == d ) ? : 88;
                        ^
        if( ( a || b ) && c ) x = 1;
               ^  ^   ^  ^
             ^      ^      ^
           ^
        c = a > b;
             ^ ^
        int * i;
           ^ ^
           ^
        int * * j;
             ^
        throw (x);
             ^
        try {
           ^
        } catch (const Exception &e) { }
         ^     ^
        } catch (...) { }
         ^     ^
        } catch { }
         ^     ^

    int main(int argc , char *argv [])
                     ^ ^          ^
    {
    	int a [2];
    	     ^
    	a[ n ] = 3;
    	  ^ ^
    	const char *names [] =
    	                 ^
    	{
    		"{ False , True }",
    		        ^ ^
    		"{ Ignore, Add, Remove, Force }",

    	return (-1);
    	      ^

    int a ( );
         ^ ^
    int a (int b) {}
         ^       ^
    void ( int a ) ( int b );
          ^     ^ ^ ^     ^
    static void sockaddr_unmapped(
        struct sockaddr *sa __attribute__ ((unused)),
                                         ^
        socklen_t *len __attribute__ ((unused)))
                                    ^

    template < typename T > inline static bool remove(T column)
            ^ ^          ^
            ^              ^
    int & a(int & b);
       ^ ^     ^ ^
    int c(int &)
       ^     ^
    {
    	d = aa (& y,& d) ;
    	      ^  ^   ^  ^
            e = ee ();
                  ^
    	if ( a == 5 ) ...
    	  ^
                ^      ^
                ^      ^
                ...
            if (b) ;
                  ^
    	if ( a == 6 ) b = 66;
                         ^
    	if ( a == 7 ) { b = 77; }
                         ^
            if (! a) {
                 ^
                b = 4;
            } else {
             ^    ^
                b = 5;
            }
            for(a = 1 ; a < b ; a++) {
                     ^       ^
               ...
    	for( ; ; ) {
                ^ ^ ^
               ...
    	switch (whatIsToDo) ...
    	      ^
    	while (start < end) ...
    	     ^

    namespace Server {
                    ^
    class Cache : public QObject
               ^ ^
    Cache::StorageDebugger ()
                          ^
        : mFile(0)
       ^ ^
    {
            new service;
               ^
            delete service;
                  ^
            delete[] buffer;
                    ^
            if (this == & other) return * this;
                         ^               ^
            switch (a) {
            case 1 :
                  ^
                    b= 1;
                    break;
            case 2 : {
                    b = 2;
                    break;
            }
            default :
                    break;
            }
            bool operator () (Entity::Id lhs, Entity::Id rhs) const
            ...          ^  ^

            a = ( int ) 5.6;
                 ^   ^ ^
            cpp = int (7);
                     ^
            len = sizeof (int);
                        ^
            SomeStruct a = SomeStruct {1, 2, 3};
                                     ^
    	someFuncCall(SomeStruct {4, 5, 6});
    	                       ^
            log . foo . bar = 5;
               ^ ^   ^ ^
    	other -> foo -> bar = 123;
    	     ^  ^   ^  ^
    }
    /// doxygen sequence
       ^
    ///< doxygen sequence
        ^
    //! doxygen sequence
       ^
    //!< doxygen sequence
        ^
    #if A
    #else /* Comment A */
         ^
    #endif /* Comment B */
          ^

    void Initialize( BYTE nDelay = 100 );
                                ^ ^
    void f1()
    {
          auto a = [ = ] (int *a, Something & b)
                    ^ ^ ^

          list[idx] (param);
                   ^

    double foo()
    {
    	return( foo(n) );
    	       ^      ^

    Vector2<double> ()
                   ^

    {
            List<byte> bob = new List<byte> ();
                      ^
            QVector<QPair<Condition, QString> > mWhenThen;
                                             ^

    template<int i, int ... Indexes, typename IdxHolder, typename ... Elements>
                       ^                                         ^
    struct index_holder_impl<i, index_holder<Indexes ...>, IdxHolder, Elements ...>
                                                    ^                         ^
    {
    	typedef typename index_holder_impl<i + 1, index_holder<Indexes ... i>,	Elements ...>::type type;
    	                                                              ^                 ^

# Register

sp_addr | sp_after_angle
sp_after_assign | sp_after_byref_func
sp_after_byrefsp_inside_angle | sp_after_cast
sp_after_class_colon | sp_after_comma
sp_after_constr_colon | sp_after_dc
sp_after_new | sp_after_operator
sp_after_operator_sym | sp_after_ptr_star_func
sp_after_ptr_star | sp_after_semi_for_empty
sp_after_semi_for | sp_after_sparen
sp_angle_paren | sp_angle_word
sp_arith | sp_assign_default
sp_assign | sp_attribute_paren
sp_balance_nested_parens | sp_before_angle
sp_before_assign | sp_before_byref_func
sp_before_byref | sp_before_case_colon
sp_before_class_colon | sp_before_comma
sp_before_constr_colon | sp_before_dc
sp_before_ellipsis(1) | sp_before_ellipsis(2)
sp_before_nl_cont | sp_before_ptr_star_func
sp_before_ptr_star | sp_before_semi_for_empty
sp_before_semi_for | sp_before_semi
sp_before_sparen | sp_before_square
sp_before_squares | sp_before_tr_emb_cmt
sp_before_unnamed_byref | sp_before_ptr_star
sp_between_ptr_star | sp_bool
sp_brace_catch | sp_brace_else
sp_brace_typedef | sp_catch_brace
sp_catch_paren | sp_cmt_cpp_doxygen
sp_cmt_cpp_start | sp_compare
sp_cond_colon_after | sp_cond_colon_before
sp_cond_colon | sp_cond_question_after
sp_cond_question_before | sp_cond_question
sp_cond_ternary_short | sp_cpp_cast_paren
sp_cpp_lambda_assign | sp_defined_paren
sp_deref | sp_else_brace
sp_endif_cmt | sp_enum_after_assign
sp_enum_assign | sp_enum_before_assign
sp_fparen_brace | sp_func_call_paren_empty
sp_func_call_paren | sp_func_class_paren
sp_func_def_paren | sp_func_proto_paren
sp_incdec | sp_inside_angle
sp_inside_braces_empty | sp_inside_braces_enum
sp_inside_braces | sp_inside_braces_struct
sp_inside_fparen | sp_inside_fparens
sp_inside_paren_cast | sp_inside_paren
sp_inside_sparen_close | sp_inside_sparen_open
sp_inside_sparen | sp_inside_square
sp_inside_tparen | sp_inv
sp_macro_func | sp_macro
sp_member | sp_not
sp_num_before_tr_emb_cmt | sp_paren_paren
sp_permit_cpp11_shift | sp_pp_concat
sp_return_paren | sp_sign
sp_sizeof_paren | sp_sparen_brace
sp_special_semi | sp_square_fparen
sp_template_angle | sp_throw_paren
sp_try_brace | sp_type_func
sp_word_brace_ns | sp_word_brace

## not yet shown

sp_after_for_colon
sp_after_ptr_star_qualifier
sp_after_semi
sp_after_throw
sp_after_type
sp_angle_shift
sp_before_for_colon
sp_before_pp_stringify
sp_case_label
sp_cparen_oparen
sp_cpp_lambda_paren
sp_func_call_user_paren
sp_paren_comma

## only for C#

sp_after_mdatype_commas
sp_before_mdatype_commas
sp_between_mdatype_commas
sp_between_new_paren
sp_getset_brace

## only for D

sp_before_template_paren
sp_d_array_colon
sp_extern_paren
sp_invariant_paren
sp_range
sp_scope_paren
sp_version_paren

## only for Java

sp_annotation_paren
sp_fparen_dbrace

## only for Pawn

sp_after_tag

## only for oc

sp_after_oc_at_sel
sp_after_oc_at_sel_parens
sp_after_oc_block_caret
sp_after_oc_colon
sp_after_oc_dict_colon
sp_after_oc_msg_receiver
sp_after_oc_property
sp_after_oc_return_type
sp_after_oc_scope
sp_after_oc_type
sp_after_send_oc_colon
sp_before_oc_block_caret
sp_before_oc_colon
sp_before_oc_dict_colon
sp_before_send_oc_colon
sp_enum_paren
sp_inside_oc_at_sel_parens
sp_paren_brace
sp_ptr_star_paren

## not C

sp_brace_finally
sp_finally_brace