Skip to content

Commit

Permalink
asciidoc docs rendering
Browse files Browse the repository at this point in the history
  • Loading branch information
grisumbras committed Apr 1, 2019
1 parent 25f474d commit 2d63d55
Show file tree
Hide file tree
Showing 16 changed files with 1,862 additions and 1 deletion.
16 changes: 16 additions & 0 deletions conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,17 +29,33 @@ class EnumFlagsConan(b2.B2.Mixin, ConanFile):
url = "https://github.com/grisumbras/enum-flags"
homepage = url

options = {"with_docs": [False, True]}
default_options = {"with_docs": False}

exports_sources = (
"jamroot.jam",
"*build.jam",
"exports/*.jam",
"*.hpp",
"*.cpp",
"LICENSE*",
"*.adoc",
"*.scss",
"*.erb",
"*.png",
"*.gif",
)
no_copy_source = True
build_requires = "boost_build/[>=1.68]@bincrafters/stable"

def b2_setup_builder(self, builder):
if self.options.with_docs:
builder.options.with_docs = True
builder.using("asciidoctor")
builder.using("sass")
del builder.options.hash
return builder

def package_info(self):
self.info.header_only()

Expand Down
27 changes: 27 additions & 0 deletions doc/assets/css/mixins.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
// Mixins
// --------------------------

@mixin fa-icon() {
display: inline-block;
font: normal normal normal #{$fa-font-size-base}/1 FontAwesome; // shortening font declaration
font-size: inherit; // can't have font-size inherit on line above, so need to override
text-rendering: auto; // optimizelegibility throws things off #1094
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
transform: translate(0, 0); // ensures no half-pixel rendering in firefox

}

@mixin fa-icon-rotate($degrees, $rotation) {
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=#{$rotation});
-webkit-transform: rotate($degrees);
-ms-transform: rotate($degrees);
transform: rotate($degrees);
}

@mixin fa-icon-flip($horiz, $vert, $rotation) {
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=#{$rotation});
-webkit-transform: scale($horiz, $vert);
-ms-transform: scale($horiz, $vert);
transform: scale($horiz, $vert);
}
15 changes: 15 additions & 0 deletions doc/assets/css/path.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
/* FONT PATH
* -------------------------- */

@font-face {
font-family: 'FontAwesome';
src: url('#{$fa-font-path}/fontawesome-webfont.eot?v=#{$fa-version}');
src: url('#{$fa-font-path}/fontawesome-webfont.eot?#iefix&v=#{$fa-version}') format('embedded-opentype'),
url('#{$fa-font-path}/fontawesome-webfont.woff2?v=#{$fa-version}') format('woff2'),
url('#{$fa-font-path}/fontawesome-webfont.woff?v=#{$fa-version}') format('woff'),
url('#{$fa-font-path}/fontawesome-webfont.ttf?v=#{$fa-version}') format('truetype'),
url('#{$fa-font-path}/fontawesome-webfont.svg?v=#{$fa-version}#fontawesomeregular') format('svg');
// src: url('#{$fa-font-path}/FontAwesome.otf') format('opentype'); // used when developing fonts
font-weight: normal;
font-style: normal;
}
Loading

0 comments on commit 2d63d55

Please sign in to comment.