summary refs log tree commit diff
path: root/src/librustdoc/html
AgeCommit message (Collapse)AuthorLines
2018-12-16backport #56844QuietMisdreavus-1/+1
2018-12-14Fix line numbers displayGuillaume Gomez-2/+2
2018-12-04Auto merge of #55707 - GuillaumeGomez:file-sidebar, r=QuietMisdreavusbors-63/+410
Add source file sidebar This is just a start currently but that gives a good overview of what it'll look like: <img width="1440" alt="screenshot 2018-11-06 at 01 39 15" src="https://user-images.githubusercontent.com/3050060/48035592-05336180-e165-11e8-82e1-5ead0c345eb9.png"> r? @QuietMisdreavus
2018-12-04Auto merge of #55682 - GuillaumeGomez:primitive-sidebar-link-gen, ↵bors-30/+57
r=QuietMisdreavus Fixes primitive sidebar link generation Fixes #50746. Fixes #55656. r? @QuietMisdreavus
2018-12-03Don't generate suffix for source-file.jsGuillaume Gomez-4/+4
2018-12-03Rollup merge of #56438 - yui-knk:remove_not_used_DotEq_token, r=petrochenkovkennytm-1/+1
Remove not used `DotEq` token Currently libproc_macro does not use `DotEq` token. https://github.com/rust-lang/rust/pull/49545 changed libproc_macro to not generate `DotEq` token.
2018-12-03Rollup merge of #56416 - GuillaumeGomez:css-body, r=QuietMisdreavuskennytm-2/+2
Remove unneeded body class selector r? @QuietMisdreavus
2018-12-02Remove not used `DotEq` tokenyui-knk-1/+1
Currently libproc_macro does not use `DotEq` token. https://github.com/rust-lang/rust/pull/49545 changed libproc_macro to not generate `DotEq` token.
2018-12-01Remove unneeded body class selectorGuillaume Gomez-2/+2
2018-11-28rustdoc: add margin-bottom spacing to nested listsLyndon Brown-1/+1
set to zero meant that the nested list was squished up against subsequent list items/paragraphs this changes the bottom margin to .6em, same as for paragraphs an example demonstrating the difference with screenshots is given in the pull request
2018-11-24Don't show file sidebar by defaultGuillaume Gomez-6/+6
2018-11-24Source sidebar improvementsGuillaume Gomez-60/+86
2018-11-24Add source file sidebarGuillaume Gomez-63/+384
2018-11-21Fixes primitive sidebar link generationGuillaume Gomez-30/+57
2018-11-15Rollup merge of #55926 - cynecx:fix-rustdoc-mobile-css, r=GuillaumeGomezPietro Albini-1/+1
Change sidebar selector to fix compatibility with docs.rs Fix for #55883.
2018-11-13Change sidebar selector to fix compatibility with docs.rscynecx-1/+1
2018-11-13Rollup merge of #55136 - GuillaumeGomez:short-doc, r=QuietMisdreavuskennytm-32/+53
Remove short doc where it starts with a codeblock Fixes #54975.
2018-11-13Rollup merge of #55858 - GuillaumeGomez:fixes-rustdoc-codeblocks, ↵kennytm-4/+9
r=QuietMisdreavus Small fixes on code blocks in rustdoc It currently has a little margin issue with the `i` and there were js errors. r? @QuietMisdreavus
2018-11-11Rollup merge of #55856 - QuietMisdreavus:static-discharge, r=GuillaumeGomezkennytm-25/+136
rustdoc: refactor: move all static-file include!s into a single module This is a smaller refactor that creates a new module `rustdoc::html::static_files`, which contains a bunch of `static` variables with all the files in `html/static` that we use. The idea behind moving them all here was to remove the duplicate `include_bytes!()` that are used by the theme-checker code. It also continues to centralize more operations in rustdoc.
2018-11-10move all static-file include!s into a single moduleQuietMisdreavus-25/+136
2018-11-10Small fixes on code blocks in rustdocGuillaume Gomez-4/+9
2018-11-10Remove short doc where it starts with a codeblockGuillaume Gomez-32/+53
2018-11-07Remove intermediate font specsJon Gjengset-5/+5
This is a (much) more constrained version of #54772 that also aims at improving the situation in #34681. It removes any font specifications that are not the "official" rustdoc font, and instead relies on the browser to provide the fallback font if the official on is not available. On Linux systems, this is particularly important, as fonts like Helvetica, Arial, and Times often look pretty bad since they're pulled from extracted MS fonts. A specification like `serif` or `sans-serif` lets the browser instead choose a good font.
2018-11-05Auto merge of #55515 - QuietMisdreavus:rustdoc-config, r=GuillaumeGomezbors-48/+43
rustdoc: refactor: centralize all command-line argument parsing This is something i've wanted to do for a while, since we keep having to add new arguments to places like `rust_input` or `core::run_core` whenever we add a new CLI flag or the like. Those functions have inflated up to 11-19, and in some cases hiding away the locations where some CLI flags were being parsed, obscuring their use. Now, we have a central place where all command-line configuration occurs, including argument validation. One note about the design: i grouped together all the arguments that `html::render::run` needed, so that i could pass them on from compilation in one lump instead of trying to thread through individual items or clone the entire blob ahead of time. One other thing this adds is that rustdoc also now recognizes all the `-Z` options that rustc does, since we were manually grabbing a few previously. Now we parse a full `DebuggingOptions` struct and hand it directly to rustc when scraping docs.
2018-11-04add Debug impls for the Options structsQuietMisdreavus-1/+1
2018-11-03Rollup merge of #54162 - GuillaumeGomez:hide-default-impls-items, ↵Guillaume Gomez-41/+116
r=QuietMisdreavus Hide default impls items Follow up of #51885. Fixes #54025. cc @Mark-Simulacrum r? @QuietMisdreavus And screenshots of course: <img width="1440" alt="screen shot 2018-09-12 at 23 30 35" src="https://user-images.githubusercontent.com/3050060/45454424-1ff8d500-b6e4-11e8-9257-030322495d58.png"> <img width="1440" alt="screen shot 2018-09-12 at 23 30 42" src="https://user-images.githubusercontent.com/3050060/45454431-2424f280-b6e4-11e8-8d65-db0d85ac18f0.png">
2018-11-02pass the Options struct instead of individual argsQuietMisdreavus-49/+42
2018-11-02split off a separate RenderOptions structQuietMisdreavus-2/+2
2018-11-02swap uses of Matches with pre-parsed argsQuietMisdreavus-8/+10
2018-11-02Auto merge of #54543 - GuillaumeGomez:top-level-index, r=QuietMisdreavusbors-12/+74
Add index page argument @Mark-Simulacrum: I might need some help from you: in bootstrap, I want to add an argument (a new flag added into `rustdoc`) in order to generate the current index directly when `rustdoc` is documenting the `std` lib. However, my change in `bootstrap` didn't do it and I assume it must be moved inside the `Std` struct. But there, I don't see how to pass it to `rustdoc` through `cargo`. Did I miss anything? r? @QuietMisdreavus
2018-10-30Fix invalid "expand description" displayGuillaume Gomez-8/+9
2018-10-29Fix source code pages in rustdocGuillaume Gomez-2/+5
2018-10-29Rollup merge of #55440 - xfix:patch-11, r=GuillaumeGomezPietro Albini-5/+0
Remove unreachable code in hasClass function in Rustdoc
2018-10-28Remove unreachable code in hasClass function in RustdocKonrad Borowski-5/+0
2018-10-27Fix sub-variant doc displayGuillaume Gomez-17/+39
2018-10-26Rollup merge of #55358 - sinkuu:redundant_clone2, r=estebankkennytm-4/+4
Remove redundant clone (2)
2018-10-26Rollup merge of #54921 - GuillaumeGomez:line-numbers, r=QuietMisdreavuskennytm-14/+68
Add line numbers option to rustdoc Fixes #22878. r? @QuietMisdreavus
2018-10-26Remove redundant cloneShotaro Yamada-4/+4
2018-10-22Fix multiple errorsGuillaume Gomez-8/+19
2018-10-21improve search tabs lookGuillaume Gomez-23/+14
2018-10-21Fix script to avoid displaying unnecessary itemsGuillaume Gomez-4/+8
2018-10-21Hide items if they use default docsGuillaume Gomez-27/+85
2018-10-21Improve stability messages display a bitGuillaume Gomez-12/+14
2018-10-21Use markdown::render instead of using pulldown_cmark directlyGuillaume Gomez-29/+21
2018-10-21Add index pageGuillaume Gomez-6/+76
2018-10-19Prefer `Default::default` over `FxHash*::default` in struct constructorsOliver Scherer-10/+10
2018-10-19Deprecate the `FxHashMap()` and `FxHashSet()` constructor function hackOliver Scherer-15/+15
2018-10-18Auto merge of #54349 - GuillaumeGomez:no-example-lint, r=QuietMisdreavusbors-2/+4
[rustdoc] Add lint for doc without codeblocks Fixes #53805. r? @QuietMisdreavus
2018-10-18Rollup merge of #55161 - akxcv:rustdoc/disable-spellcheck, ↵kennytm-0/+1
r=QuietMisdreavus,GuillaumeGomez [librustdoc] Disable spellcheck for search field This disables spellchecking for the search field in the rustdoc web interface. As someone who uses Safari to browse through Rust docs, spellchecking gets really annoying.
2018-10-18Rollup merge of #55080 - thanatos:fix-localstorage-crash, r=GuillaumeGomezkennytm-2/+20
Detect if access to localStorage is forbidden by the user's browser If the user's cookie/persistent storage setting forbid access to `localStorage`, catch the exception and abort the access. Currently, attempting to use the expand/contract links at the top of the page for structs/consts/etc. fails due to an unhandled error while accessing `localStorage`, if such access is forbidden, as the exception from the failed access propagates all the way out, interrupting the expand/contract. Instead, I would like to degrade gracefully; the access won't happen (the collapse/expand state won't get persisted) but the actual expanding/contracting of the item will go on to succeed. Fixes #55079