summary refs log tree commit diff
path: root/src/librustdoc/html/static/main.css
AgeCommit message (Collapse)AuthorLines
2014-09-17Restore colour to rustdoc, add colour to ffi functions and methodsP1start-5/+9
2014-09-05rustdoc/html: emphasize the crate part of the full path.NODA, Kai-0/+2
2014-08-31Make doc search results use <a> tags instead of js for navigatingCarol Nichols-7/+13
This has the primary advantage of not interfering with browser default behavior for links like being able to cmd/ctrl+click on a result to open the result in a new tab but leave the current page as-is (previous behavior both opened a new tab and changed the current tab's location to the result's)
2014-08-08auto merge of #16277 : Gankro/rust/responsive-docs, r=cmrbors-21/+72
* move some sidebar contents to a title bar when small * inline description toggle when small * make out-of-band and in-band content share space, rather than float and clash * compress wording of out-of-band content to avoid line-wrap as much as possible ## [Live Version Here](http://cg.scs.carleton.ca/~abeinges/doc/index.html) Pages Of Interest: * [Vec](http://cg.scs.carleton.ca/~abeinges/doc/std/vec/struct.Vec.html) (small path) * [TreeSet](http://cg.scs.carleton.ca/~abeinges/doc/collections/treemap/struct.TreeSet.html) (long path) * [std](http://cg.scs.carleton.ca/~abeinges/doc/std/index.html) (for stability dash) TBD in a future PR is to convert links in the sidebar into a series of nest ul/li's, so that they can easily be moved to a drop-down in the new title bar. I think this is out of scope for this PR, but am willing to implement it now if desired.
2014-08-06make rustdoc more responsiveAlexis Beingessner-21/+72
* move some sidebar contents to a title bar when small * inline description toggle when small * make out-of-band and in-band content share space, rather than float and clash * compress wording of out-of-band content to avoid line-wrap as much as possible
2014-08-06Rustdoc: Add padding on <code>Simon Sapin-0/+1
… to separate text from the edge of the newly added background.
2014-08-06Rustdoc: Highlight <code> elements (from Markdown `backticks`)Simon Sapin-0/+4
2014-08-02auto merge of #16169 : Gankro/rust/simple-docs, r=cmrbors-3/+39
<strike>Adds a simple/detailed toggle to api doc pages. Detailed mode is the current behaviour, simple mode hides all doccomment details leaving only signatures for quick browsing. </strike> Adds [expand all] and [collapse all] "links" to all api doc pages. All doccomments are collapsed, leaving only signatures for quick browsing. In addition, clicking on a <strike>function name</strike> function's [toggle details] link now toggles the visibility of the associated doccomment. -------- # [Live Build Here](http://cg.scs.carleton.ca/~abeinges/doc/std/vec/struct.Vec.html) This is something that's been bothering me, and I've seen some people mention in IRC before. The docs are *great* if you want a full in-depth look at an API, but *awful* if you want to scan them. This provides the ability to toggle complexity freely. Interacts perfectly well with noscript, since the static page is effectively unchanged. Collapsing is just hiding divs with css. I'm not much of a designer, so design input welcome on the actual UX for toggling. The actual javascript is *a bit* brittle to layout changes, but it always will be without adding lots of extra junk to the actual markup, which didn't seem worth it.
2014-08-02Add hide/show detail toggles to rustdocAlexis Beingessner-3/+39
All doccomments are now collapsable via a nearby [-] button Adds [collapse all] and [expand all] buttons to the top of all api pages Tweaks some layout to accomadate this
2014-08-01Fix API docs css reversing elements that it shouldn'ttinaun-1/+2
remove unneeded `pre.rust a' selector move transform into `.test-arrow` fixes #16138
2014-07-29making raw source display betterAlexis Beingessner-0/+8
* Make the code fill up the full width of the page (no massive whitespace on the left) * Move the code down to make it not intersect the logo * Set a min-width and remove the max-width so that the code doesn't scroll internally, but instead scrolls the page, meaning horizontal scroll bars are always available * Set overflow to actually overflow, just to be sure Fixes #15891
2014-07-28rustdoc: improvements to stability dashboardAaron Turon-2/+2
* Makes dashboard width dynamic. * Colors unmarked items. * Gives overall crate percentages.
2014-07-10rustdoc: Add stability dashboardAaron Turon-1/+10
This commit adds a crate-level dashboard summarizing the stability levels of all items for all submodules of the crate. The information is also written as a json file, intended for consumption by pages like http://huonw.github.io/isrustfastyet/ Closes #13541
2014-07-08webfonts: serve Source Code Pro locallyAdrien Tétar-0/+12
So that we have freestanding docs.
2014-07-08webfonts: proper fixAdrien Tétar-7/+7
2014-06-30rustdoc: incorporate stability index throughoutAaron Turon-9/+19
This commit hooks rustdoc into the stability index infrastructure in two ways: 1. It looks up stability levels via the index, rather than by manual attributes. 2. It adds stability level information throughout rustdoc output, rather than just at the top header. In particular, a stability color (with mouseover text) appears next to essentially every item that appears in rustdoc's HTML output. Along the way, the stability index code has been lightly refactored.
2014-06-19(doc) Properly doc hotkeys in generated docs.Zach Pomerantz-1/+1
Updated search bar to match help text. Used correct, normalized hotkeys in search. Updated shortcut menu with working shortcuts (tabs). Changed height of search help.
2014-06-13rustdoc: Larger click areas for sidebar itemsValentin Tsatskin-4/+8
* Change links to display:block for click larger targets * Remove linebreaks due to extra space * Adjust margins so that element spacing stays the same * Sidebar item hover background colour chosen from <pre> styling
2014-06-06rustdoc: Submit examples to play.rust-lang.orgAlex Crichton-1/+12
This grows a new option inside of rustdoc to add the ability to submit examples to an external website. If the `--markdown-playground-url` command line option or crate doc attribute `html_playground_url` is present, then examples will have a button on hover to submit the code to the playground specified. This commit enables submission of example code to play.rust-lang.org. The code submitted is that which is tested by rustdoc, not necessarily the exact code shown in the example. Closes #14654
2014-05-24core: rename strbuf::StrBuf to string::StringRicho Healey-1/+1
[breaking-change]
2014-04-30rustdoc: fix overly broad selectorsAdrien Tétar-4/+3
2014-04-29auto merge of #13776 : adrientetar/rust/rustdoc-fix, r=brsonbors-26/+33
- Closes #13591. Relevant example: http://adrientetar.legtux.org/cached/rust-docs/struct.CChars.htm (Had to use `!important` to override CSS selector precedence, namely matching over parent class.) - Implement changes from #13780 feedback, namely: * Changed font-size from 18px to 15px * Reintroduced gray background for code samples * Tightened up the margins - Fix point 1 and point 4 of #13804. Samples: - [enum.FileType](http://adrientetar.legtux.org/cached/rust-docs/enum.FileType.htm) - [struct.CChars](http://adrientetar.legtux.org/cached/rust-docs/struct.CChars.htm) - [std](http://adrientetar.legtux.org/cached/rust-docs/std.htm) - [std::io](http://adrientetar.legtux.org/cached/rust-docs/io.htm). r? @brson
2014-04-28rustdoc: #13771: Make html links inside paragraphs more readableIvan Petkov-0/+4
All links inside docblocks will have their color set to `#4e8bca` (a light blue color to contrast against the black text). This color also offers a visible contrast from the surrounding text if viewed as grayscale, making it suitable for accessability. Docblock links will also be underlined when hovered over.
2014-04-28rustdoc: fix a few inconsistenciesAdrien Tétar-8/+9
2014-04-27rustdoc: style tweaksAdrien Tétar-14/+19
2014-04-26rustdoc: refactor and unstyle inline section headersAdrien Tétar-8/+9
2014-04-25rustdoc: bring it inlineAdrien Tétar-6/+11
2014-04-25doc,rustdoc: store webfonts locallyAdrien Tétar-5/+5
- Avoids cross-domain requests restrictions - Better availability of content - No HTML queries needed for an offline build
2014-04-25rustdoc: fixesAdrien Tétar-5/+4
2014-04-20doc: unifying with rustdocAdrien Tétar-17/+23
Conflicts: src/doc/rust.md
2014-04-15rustdoc: add webfonts and tweak the styles accordinglyAdrien Tétar-22/+59
2014-04-12doc: design changes cleanupsAdrien Tétar-110/+35
Conflicts: src/librustdoc/html/layout.rs
2014-04-12fixed issuesDaniel Fagnan-17/+35
Signed-off-by: Daniel Fagnan <dnfagnan@gmail.com>
2014-04-12Tweaked the design to be a lot cleaner.Daniel Fagnan-28/+125
Signed-off-by: Daniel Fagnan <dnfagnan@gmail.com>
2014-03-12rustdoc: whitelist the headers that get a § on hover.Huon Wilson-11/+6
Previously the :hover rules were making the links to the traits/types in something like impl<K: Hash + Eq, V> ... { ... } be displayed with a trailing `§` when hovered over. This commit restricts that behaviour to specific headers, i.e. those that are known to be section headers (like those rendered in markdown doc-comments, and the "Modules", "Functions" etc. headings).
2014-03-09doc: CSS fixesAdrien Tétar-10/+7
- fixup and refactor highlighting code - have a proper print stylesheet
2014-03-09rustdoc: hardcode each header as a link.Huon Wilson-6/+13
This avoids having to include JS in the guide/tutorial/manual pages just to get the headers being links. The on-hover behaviour showing the little section marker § is preserved, because that gives a useful hint that the heading is a link.
2014-03-05rustdoc: Add anchors to section headersAlex Crichton-0/+7
This commit adds a appear-on-over link to all section headers to generated documentation. Each header also receives an id now, even those generated through markdown. The purpose of this is to provide easy to link to sections. This modifies the default header markdown generation because the default id added looks like "toc_NN" which is difficult to reconcile among all sections (by default each section gets a "toc_0" id), and it's also not very descriptive of where you're going. This chooses to adopt the github-style anchors by taking the contents of the title and hyphen-separating them (after lower casing). Closes #12681
2014-03-04rustdoc: tweak highlightingAdrien Tétar-16/+16
2014-03-02rustdoc: syntax highlight macro definitions, colour $... substitutions.Huon Wilson-0/+1
Macro definitions are just their raw source code, and so should be highlighted where possible. Also, $ident non-terminal substitutions are special, and so are worth of a little special treatment.
2014-02-23rustdoc: Add syntax highlightingAlex Crichton-0/+15
This adds simple syntax highlighting based off libsyntax's lexer to be sure to stay up to date with rust's grammar. Some of the highlighting is a bit ad-hoc, but it definitely seems to get the job done! This currently doesn't highlight rustdoc-rendered function signatures and structs that are emitted to each page because the colors already signify what's clickable and I think we'd have to figure out a different scheme before colorizing them. This does, however, colorize all code examples and source code. Closes #11393
2014-02-19rustdoc: Highlight methods jumped toAlex Crichton-0/+2
This helps figure out where you actually jumped to, especially if the thing you jumped to is at the very bottom of the page. Closes #9905
2013-12-07rustdoc: fix the search-bar layoutAdrien Tétar-1/+5
Now with broader compatibility.
2013-11-13doc: disable parser error highlighting + a few fixesAdrien Tétar-0/+1
CodeMirror parser errors are related to #9873.
2013-11-12doc: CSS: fix code fontsAdrien Tétar-1/+7
Closes #10330.
2013-10-22auto merge of #10003 : alexcrichton/rust/issue-fixes, r=brsonbors-0/+7
Commits have all the fun details.
2013-10-21rustdoc: Don't overflow long type/module namesAlex Crichton-0/+7
Closes #9862
2013-10-21rustdoc: nitpicks & cleanupAdrien Tétar-29/+18
2013-10-02Prevent source view from wrapping linesJordi Boggiano-1/+5
2013-10-02Highlight line numbers of the lines referred to in the url hashJordi Boggiano-0/+3