view tools/foreach.m4 @ 480:e813ac222f48 Android_Skia

Merge add colors into constructor of gradient pattern. Since we also define color stops for gradient pattern and rear change it, mbe_pattern_add_color_stop_rgba() is merged into mb_pattern_create_radial() and mb_pattern_create_linear(). It also makes porting to graphic engines easier.
author Thinker K.F. Li <thinker@branda.to>
date Sun, 15 Nov 2009 16:21:09 +0800
parents f4b792afa74e
children
line wrap: on
line source

divert([-1])

define([_arg1], [$1])

define([_foreach], [ifelse([$2], [()], [],
[define([$1], _arg1$2)$3[]_foreach([$1], (shift$2), [$3])])])

define([foreach], [pushdef([$1])_foreach($@)popdef([$1])])

divert[]dnl