Hi, interesting:) Progress bar can be centered by this way: - set pbor position to relative - set pbor left and right margin to auto
this should work;-) But it centers it only horizontally, vertical centering is a bit harder:( 2009/3/9 Jean-Baptiste BRIAUD -- Novlog <[email protected]>: > Hi, > Here is the startup page I manage to get with qxbuild. > I still wonder how it could be possible to center the progress bar ... > The simple idea for that page is that one can place all the stuff inside the > <div id="bar">HERE THE STUFF</div> > That stuff will be removed when the application is ready. > I put in bold changed section compared to Petr version. > Note that the script in outside the body to ensure the DOM from the body is > loaded, so id="bar" component is found. > I'm not sure if it is the correct way of ensuring this as I'm very bas in > HTML thing, that's why I like qooxdoo :-) > > <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" > "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> > <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> > <head> > <meta name="robots" CONTENT="noarchive, nofollow, noarchive, > nosnippet"/> > <meta name="robots" content="none"/> > <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> > <link rel="shortcut icon" href="favicon.ico"/> > <title>TITLE</title> > <!-- ScriptLoader --> > <script type="text/javascript" > src="/qooxdoo-0.8.2/script/ScriptLoader.js"></script> > </head> > <body scroll="no" style="background-color:#YOUR COLOR"> > <div id="bar"> > <span id="waiter" style="font-family: arial; font-size: large; color: > #YOUR COLOR; "> > <div style="text-align: center;"> > <br/> > <br/> > <img src="YOUR LOGO"/><br/>YOUR WELCOME TEXT > </div> > </span> > </div> > </body> > <script type="text/javascript"> > // [Qooxdoo Settings] > qxsettings = > { > // Application > "qx.application" : "YOUR QX STARTUP CLASS", > // Mode ("build" or "debug") > "qx.mode": "build", > // Theme class to use > "qx.theme" : "qx.theme.Modern", > // Path to qooxdoo script files > "qx.path": "/qooxdoo-0.8.2", > // DEPRECATED > // Resources and script uri. If you are planning to have qooxdoo in > // special uri (browser path), you can specify it here. There is > // no rebuild process needed while changing qxsettings here! > "qx.resourcesUri": "./resource", > // Script uri > "qx.scriptUri": "./script" > }; > // [Javascript Files] > // > // Here are javascripts files that will be loaded by ScriptLoader. First > file > // must be qooxdoo main module. All next files are your javascript > files. > qxscripts = > [ > // Qooxdoo > qxsettings["qx.path"] + "/script/qx-" + qxsettings["qx.mode"] + > ".js", > // Add here your scripts to load, you can use qxsettings[] for base > paths, etc... > YOUR QX CLASSES > ]; > // [Script Loader] > // > // There is simple progress bar that can be customized. It's important > to > // remove it from DOM when loading is finished. > (function() { > var w = 800; > var h = 14; > var body = document.getElementsByTagName("body")[0]; > var bar = document.getElementById("bar"); > var pbor = document.createElement("div"); > var pbar = document.createElement("div"); > pbor.style.position = "absolute"; > pbor.style.border = "solid 1px #000000"; > pbor.style.background = "#FFFFFF"; > pbor.style.width = w + "auto"; > pbor.style.height = h + "px"; > pbar.style.position = "absolute"; > pbar.style.border = "0px"; > pbar.style.background = "#YOUR COLOR"; > pbar.style.width = "0px"; > pbar.style.height = h + "px"; > ScriptLoader.load({ > scripts: qxscripts, > start: function() > { > bar.appendChild(pbor); > pbor.appendChild(pbar); > }, > finish: function() > { > pbor.removeChild(pbar); > bar.removeChild(pbor); > body.removeChild(bar); > }, > progress: function(percent, file) > { > pbar.style.width = "" + Math.floor(percent * w) + "px"; > } > }); > }()); > </script> > </html> > ------------------------------------------------------------------------------ > Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA > -OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise > -Strategies to boost innovation and cut costs with open source participation > -Receive a $600 discount off the registration fee with the source code: SFAD > http://p.sf.net/sfu/XcvMzF8H > _______________________________________________ > qooxdoo-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel > > ------------------------------------------------------------------------------ Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA -OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise -Strategies to boost innovation and cut costs with open source participation -Receive a $600 discount off the registration fee with the source code: SFAD http://p.sf.net/sfu/XcvMzF8H _______________________________________________ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
