From e3ca418909cde338f926b33e372b0f7247eed744 Mon Sep 17 00:00:00 2001 From: Felix Mulder Date: Mon, 7 Mar 2016 11:28:38 +0100 Subject: Add fallback typefaces for monospaced sections in scaladoc This commit will also fix the `Filter All Members` input appearing if there are no members - please see root for an example. There's also a small CSS fix that addresses a vertical scrollbar on smaller viewports (footer was not responsively resized). review: @VladUreche lol --- .../scala/tools/nsc/doc/html/page/Entity.scala | 43 +++++++++++----------- 1 file changed, 22 insertions(+), 21 deletions(-) (limited to 'src/scaladoc/scala/tools/nsc/doc/html/page') diff --git a/src/scaladoc/scala/tools/nsc/doc/html/page/Entity.scala b/src/scaladoc/scala/tools/nsc/doc/html/page/Entity.scala index c8a7d6d245..55a85474f6 100644 --- a/src/scaladoc/scala/tools/nsc/doc/html/page/Entity.scala +++ b/src/scaladoc/scala/tools/nsc/doc/html/page/Entity.scala @@ -173,7 +173,7 @@ trait EntityPage extends HtmlPage { val valueMembers = - tpl.methods ++ tpl.values ++ tpl.templates.filter(x => x.isObject || x.isPackage) sorted + tpl.methods ++ tpl.values ++ tpl.templates.filter(x => x.isObject) sorted val (absValueMembers, nonAbsValueMembers) = valueMembers partition (_.isAbstract) @@ -232,6 +232,7 @@ trait EntityPage extends HtmlPage { { memberToCommentHtml(tpl, tpl.inTemplate, isSelf = true) } + { if (valueMembers.filterNot(_.kind == "package").isEmpty) NodeSeq.Empty else
@@ -241,25 +242,25 @@ trait EntityPage extends HtmlPage {
-
-
- Ordering -
    - { - if (!universe.settings.docGroups.value || (tpl.members.map(_.group).distinct.length == 1)) - NodeSeq.Empty - else -
  1. Grouped
  2. - } -
  3. Alphabetic
  4. - { - if (tpl.linearizationTemplates.isEmpty && tpl.conversions.isEmpty) - NodeSeq.Empty - else -
  5. By Inheritance
  6. - } -
-
+
+
+ Ordering +
    + { + if (!universe.settings.docGroups.value || (tpl.members.map(_.group).distinct.length == 1)) + NodeSeq.Empty + else +
  1. Grouped
  2. + } +
  3. Alphabetic
  4. + { + if (tpl.linearizationTemplates.isEmpty && tpl.conversions.isEmpty) + NodeSeq.Empty + else +
  5. By Inheritance
  6. + } +
+
{ if (tpl.linearizationTemplates.isEmpty && tpl.conversions.isEmpty) NodeSeq.Empty else { if (!tpl.linearizationTemplates.isEmpty) @@ -303,6 +304,7 @@ trait EntityPage extends HtmlPage { }
+ }
@@ -333,7 +335,6 @@ trait EntityPage extends HtmlPage {
    { concValueMembers - .filter(_.kind != "package") .map(memberToHtml(_, tpl)) }
-- cgit v1.2.3