html5 - double buffering SVG in HTML -
i wonder better way simulate double buffering possibly complex svg. i'm reloading modified svg, , i'd rid of load delay. thinking of using 2 overlapped divs , toggle visibility after onload. there better alternative?
edit
now have implemented 2 svg instances in divs overlapped, style display toggling (block/none). worked in ff (nice, smooth morphing, initial display resulted in reduced area), chrome refuses me screenctm transform need syncing shapes position. guess problems (partial area render in ff, no render in chrome) related. i'm experimenting visibility:hidden instead.
edit
toggling visibility give acceptable results. far.
edit
i've found problem, make me here again helping hand: i'm using boostrap non svg related ui, , toolbar behaves strange: when switched visibility on 2^ div (initially hidden), no event arrives toolbar. switching again 1^, events ok.
i found using position:absolute or position:fixed same (for events problem, of course), , top:0 it's 'culprit'. using value > 0 let event flow, div goes invisible. intial question make sense: better method switch visibility? or hint on html structure? html looks like
<div class="row-fluid" style="height:800px;background-color:cyan"> <div id="flowchart" style="visibility:visible;width:100%;height:100%"></div> <div id="flowchart_x" style="visibility:hidden;width:100%;height:100%;position:absolute;top:0"></div> </div>
Comments
Post a Comment