From 60d56501a02ba40d754f02ea78299be865c9a57e Mon Sep 17 00:00:00 2001 From: Donna Malayeri Date: Tue, 20 Jul 2010 16:13:28 +0000 Subject: [scaladoc] Modify build script to copy html res... [scaladoc] Modify build script to copy html resources to output directory; display template in a frame rather than an iframe; change title of main page when new frame is loaded. Review by dubochet. --- build.xml | 2 + .../scala/tools/nsc/doc/html/HtmlFactory.scala | 1 + .../scala/tools/nsc/doc/html/page/Index.scala | 5 +- .../scala/tools/nsc/doc/html/page/Template.scala | 4 +- .../scala/tools/nsc/doc/html/resource/index.html | 98 +++------------------- .../tools/nsc/doc/html/resource/lib/index.css | 6 +- .../tools/nsc/doc/html/resource/lib/template.css | 3 +- .../tools/nsc/doc/html/resource/lib/template.js | 5 ++ 8 files changed, 27 insertions(+), 97 deletions(-) diff --git a/build.xml b/build.xml index 656c45a8c5..30f8def1dc 100644 --- a/build.xml +++ b/build.xml @@ -367,6 +367,7 @@ LOCAL REFERENCE BUILD (LOCKER) + @@ -601,6 +602,7 @@ QUICK BUILD (QUICK) + diff --git a/src/compiler/scala/tools/nsc/doc/html/HtmlFactory.scala b/src/compiler/scala/tools/nsc/doc/html/HtmlFactory.scala index 94b1f38b65..0aff736f47 100644 --- a/src/compiler/scala/tools/nsc/doc/html/HtmlFactory.scala +++ b/src/compiler/scala/tools/nsc/doc/html/HtmlFactory.scala @@ -40,6 +40,7 @@ class HtmlFactory(val universe: Universe) { finally out.close() } + copyResource("index.html") copyResource("lib/jquery.js") copyResource("lib/tools.tooltip.js") copyResource("lib/scheduler.js") diff --git a/src/compiler/scala/tools/nsc/doc/html/page/Index.scala b/src/compiler/scala/tools/nsc/doc/html/page/Index.scala index 8675058c24..bf531402ce 100644 --- a/src/compiler/scala/tools/nsc/doc/html/page/Index.scala +++ b/src/compiler/scala/tools/nsc/doc/html/page/Index.scala @@ -15,7 +15,7 @@ import scala.xml._ class Index(universe: Universe) extends HtmlPage { - def path = List("index.html") + def path = List("allclasses.html") def title = { val s = universe.settings @@ -111,9 +111,6 @@ class Index(universe: Universe) extends HtmlPage { packageElem(universe.rootPackage) } -
- -
- - + + + + + + +Test + + + + diff --git a/src/compiler/scala/tools/nsc/doc/html/resource/lib/index.css b/src/compiler/scala/tools/nsc/doc/html/resource/lib/index.css index 0d30662da6..77d9cdf8e6 100644 --- a/src/compiler/scala/tools/nsc/doc/html/resource/lib/index.css +++ b/src/compiler/scala/tools/nsc/doc/html/resource/lib/index.css @@ -28,7 +28,7 @@ h1 { top: 0px; left: 0px; bottom: 0px; - width: 300px; + width: 100%; display: block; position: fixed; } @@ -37,7 +37,7 @@ h1 { position: fixed; display: block; padding: 5px; - width: 290px; + width: 95%; right: 0; left: 0; top: 0; @@ -78,7 +78,7 @@ h1 { right: 20px; left: 20px; height: 16px; - width: 246px; + width: 90%; padding: 2px; font-weight: bold; color: #993300; diff --git a/src/compiler/scala/tools/nsc/doc/html/resource/lib/template.css b/src/compiler/scala/tools/nsc/doc/html/resource/lib/template.css index 8cfd9e9ce1..48276d40b8 100644 --- a/src/compiler/scala/tools/nsc/doc/html/resource/lib/template.css +++ b/src/compiler/scala/tools/nsc/doc/html/resource/lib/template.css @@ -111,7 +111,8 @@ a:hover { #template > div.parent > h3 { color: white; padding: 4px; - background-color: #385E1A; + margin-top: 10px; + background-color: #47166D; font-size: 12pt; font-weight: bold; } diff --git a/src/compiler/scala/tools/nsc/doc/html/resource/lib/template.js b/src/compiler/scala/tools/nsc/doc/html/resource/lib/template.js index 506edd7746..6aacfb1390 100644 --- a/src/compiler/scala/tools/nsc/doc/html/resource/lib/template.js +++ b/src/compiler/scala/tools/nsc/doc/html/resource/lib/template.js @@ -256,3 +256,8 @@ function filter() { }); return false }; + +function windowTitle() +{ + parent.document.title=document.title; +}; -- cgit v1.2.3