試しにhspでjsonの整形を行う(といっても簡単なjsonだけ)プログラム、
作ってみました。
あくまでもお試しで作ったので、動作保障はしません。
(まあパソコンが壊れたりはしないだろうし)
入れ子オブジェクトに対応してません。
配列は仮対応です。
json=""
mesbox json,640,400
objskip 0,2
button "convert",*c
stop
*c
strrep json,"\n",""
strrep json," ",""
strrep json," ",""
strrep json,"\t",""
strrep json,"[{","[\n\t{\n\t"
strrep json,"}]","\n}\n\n]\n"
strrep json,"},","@@@###@@@"
strrep json,"{","{\n\t"
strrep json,"}","\n\t}\n"
strrep json,"@@@###@@@","\n},\n"
strrep json,"\t\n\t","\t"
strrep json,"\n\t}","\t}"
strrep json,"\",\"","\",\n\t\t\""
strrep json,"\t{\n\t","\t{\n\t\t"
objprm 0,json