Created
September 14, 2013 09:34
-
-
Save Atry/6560527 to your computer and use it in GitHub Desktop.
生成textLayout的Haxe定义,并替换成2.10兼容的语法
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--gen-hx-classes | |
-swf-lib haxelib-release/textLayout.swf | |
-swf no-output.swf | |
--no-output | |
--macro removeField("flashx.textLayout.conversion.BaseTextLayoutExporter","exportFlowElement",true) | |
--macro removeField("flashx.textLayout.conversion.BaseTextLayoutExporter","exportContainerFormattedElement",true) | |
--macro removeField("flashx.textLayout.conversion.BaseTextLayoutExporter","exportListItem",true) | |
--macro removeField("flashx.textLayout.conversion.BaseTextLayoutExporter","exportParagraphFormattedElement",true) | |
--macro removeField("flashx.textLayout.conversion.BaseTextLayoutExporter","exportList",true) | |
--macro removeField("flashx.textLayout.elements.FlowElement","abstract") | |
--macro removeField("flashx.textLayout.elements.FlowLeafElement","text") | |
--macro removeField("flashx.textLayout.compose.BaseCompose","computeNumberLineAlignment") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
find haxelib-release/flashx -name '*.hx' | xargs sed -e 's/\<extends \(I[A-Z]\)/#if haxe3 extends #else implements #end \1/g' -e 's/\<\(implements\|extends\) \([^ #]*\) implements\>/\1 \2 #if haxe #else , #end implements/g' -e 's/\<\(implements\|extends\) \([^ #]*\) implements\>/\1 \2 #if haxe #else , #end implements/g' -e 's/\<\(implements\|extends\) \([^ #]*\) implements\>/\1 \2 #if haxe #else , #end implements/g' -e 's/\<\(implements\|extends\) \([^ #]*\) implements\>/\1 \2 #if haxe #else , #end implements/g' -i |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment