add rotating logo
@ -174,8 +174,8 @@ configure_file (${CMAKE_SOURCE_DIR}/share/pdf2htmlEX.js.in ${CMAKE_SOURCE_DIR}/s
|
||||
|
||||
set(PDF2HTMLEX_SRC ${PDF2HTMLEX_SRC}
|
||||
src/Param.h
|
||||
src/pdf2htmlEX-config.h
|
||||
src/pdf2htmlEX.cc
|
||||
src/pdf2htmlEX-config.h
|
||||
src/HTMLRenderer/HTMLRenderer.h
|
||||
src/HTMLRenderer/draw.cc
|
||||
src/HTMLRenderer/general.cc
|
||||
@ -234,8 +234,10 @@ file (GLOB datafiles
|
||||
share/base.css
|
||||
share/fancy.css
|
||||
share/jquery.js
|
||||
share/pdf2htmlEX.js
|
||||
share/manifest
|
||||
share/pdf2htmlEX.js
|
||||
share/pdf2htmlEX-plain-62x62.png
|
||||
share/pdf2htmlEX-shadow-64x64.png
|
||||
)
|
||||
install (FILES ${datafiles} DESTINATION share/pdf2htmlEX)
|
||||
install (FILES pdf2htmlEX.1 DESTINATION share/man/man1)
|
||||
|
Before Width: | Height: | Size: 44 KiB After Width: | Height: | Size: 152 KiB |
Before Width: | Height: | Size: 7.2 KiB After Width: | Height: | Size: 18 KiB |
BIN
logo/pdf2htmlEX-plain-62x62.png
Normal file
After Width: | Height: | Size: 14 KiB |
38
logo/pdf2htmlEX-plain.svg
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
logo/pdf2htmlEX-shadow-64x64.png
Normal file
After Width: | Height: | Size: 3.1 KiB |
37
logo/pdf2htmlEX-shadow.svg
Normal file
After Width: | Height: | Size: 10 KiB |
42
logo/test.html
Normal file
@ -0,0 +1,42 @@
|
||||
<!doctype html>
|
||||
<html><body>
|
||||
<style type="text/css">
|
||||
@-moz-keyframes rotate {
|
||||
from { -moz-transform: rotate(0deg); }
|
||||
to { -moz-transform: rotate(360deg); }
|
||||
}
|
||||
@-webkit-keyframes rotate {
|
||||
from { -webkit-transform: rotate(0deg); }
|
||||
to { -webkit-transform: rotate(360deg); }
|
||||
}
|
||||
#shadow, #emblem{
|
||||
position:relative;
|
||||
-moz-animation: rotate 18s linear 0s infinite;
|
||||
-webkit-animation: rotate 18s linear 0 infinite;
|
||||
display:inline-block;
|
||||
position:absolute;
|
||||
}
|
||||
#shadow {
|
||||
height: 64px;
|
||||
width: 64px;
|
||||
}
|
||||
#emblem {
|
||||
height: 62px;
|
||||
width: 62px;
|
||||
}
|
||||
#rotating-emblem{
|
||||
margin:auto;
|
||||
position:relative;
|
||||
height:64px;
|
||||
width:64px;
|
||||
top:50%;
|
||||
margin-top:-32px;
|
||||
left:50%;
|
||||
margin-left:-32px;
|
||||
}
|
||||
</style>
|
||||
<div id="rotating-emblem">
|
||||
<img id="shadow" src="pdf2htmlEX-shadow.svg">
|
||||
<img id="emblem" src="pdf2htmlEX-plain.svg">
|
||||
</div>
|
||||
</body></html>
|
@ -180,4 +180,7 @@ span { /* text blocks within a line */
|
||||
-webkit-transform-origin:0% 100%;
|
||||
-o-transform-origin:0% 100%;
|
||||
}
|
||||
#pdf2htmlEX-logo {
|
||||
display:none;
|
||||
}
|
||||
/* Base CSS END */
|
||||
|
@ -61,5 +61,30 @@
|
||||
-o-animation: fadein 100ms;
|
||||
animation: fadein 100ms;
|
||||
}
|
||||
@-moz-keyframes rotate {
|
||||
from { -moz-transform: rotate(0deg); }
|
||||
to { -moz-transform: rotate(360deg); }
|
||||
}
|
||||
@-webkit-keyframes rotate {
|
||||
from { -webkit-transform: rotate(0deg); }
|
||||
to { -webkit-transform: rotate(360deg); }
|
||||
}
|
||||
#pdf2htmlEX-logo {
|
||||
position:absolute;
|
||||
display:block;
|
||||
height:64px;
|
||||
width:64px;
|
||||
top:50%;
|
||||
left:50%;
|
||||
margin-top:-32px;
|
||||
margin-left:-32px;
|
||||
}
|
||||
#pdf2htmlEX-logo img{
|
||||
position:absolute;
|
||||
top:0;
|
||||
left:0;
|
||||
-moz-animation: rotate 18s linear 0s infinite;
|
||||
-webkit-animation: rotate 18s linear 0 infinite;
|
||||
}
|
||||
}
|
||||
/* Fancy CSS END */
|
||||
|
@ -6,7 +6,7 @@
|
||||
# Empty lines are ignored
|
||||
#
|
||||
# # - comment
|
||||
# @ - embed or link to a file from data dir, depending on the value of --single-html
|
||||
# @ - embed or link to a file from data dir, depending on the values of --embed-*** options
|
||||
# $ - special use for pdf2htmlEX
|
||||
#
|
||||
# Special
|
||||
@ -77,6 +77,16 @@ $pages
|
||||
</div>
|
||||
"""
|
||||
|
||||
# pdf2htmlEX logo for loading
|
||||
"""
|
||||
<div id="pdf2htmlEX-logo">
|
||||
"""
|
||||
@pdf2htmlEX-shadow-64x64.png
|
||||
@pdf2htmlEX-plain-62x62.png
|
||||
"""
|
||||
</div>
|
||||
"""
|
||||
|
||||
|
||||
"""
|
||||
</body>
|
||||
|
BIN
share/pdf2htmlEX-plain-62x62.png
Normal file
After Width: | Height: | Size: 14 KiB |
BIN
share/pdf2htmlEX-shadow-64x64.png
Normal file
After Width: | Height: | Size: 3.1 KiB |
@ -537,8 +537,16 @@ void HTMLRenderer::embed_file(ostream & out, const string & path, const string &
|
||||
ifstream fin(path, ifstream::binary);
|
||||
if(!fin)
|
||||
throw string("Cannot open file ") + path + " for embedding";
|
||||
out << entry.prefix_embed << endl
|
||||
<< fin.rdbuf();
|
||||
out << entry.prefix_embed;
|
||||
|
||||
if(entry.base64_encode)
|
||||
{
|
||||
out << Base64Stream(fin);
|
||||
}
|
||||
else
|
||||
{
|
||||
out << endl << fin.rdbuf();
|
||||
}
|
||||
out.clear(); // out will set fail big if fin is empty
|
||||
out << entry.suffix_embed << endl;
|
||||
}
|
||||
|
@ -25,14 +25,19 @@ const map<string, string> GB_ENCODED_FONT_NAME_MAP({
|
||||
const std::map<std::string, EmbedStringEntry> EMBED_STRING_MAP({
|
||||
{".css", {&Param::embed_css,
|
||||
"<style type=\"text/css\">",
|
||||
"</style>",
|
||||
"</style>", false,
|
||||
"<link rel=\"stylesheet\" type=\"text/css\" href=\"",
|
||||
"\"/>" }},
|
||||
{".js", {&Param::embed_javascript,
|
||||
"<script type=\"text/javascript\">",
|
||||
"</script>",
|
||||
"</script>", false,
|
||||
"<script type=\"text/javascript\" src=\"",
|
||||
"\"></script>" }}
|
||||
"\"></script>" }},
|
||||
{".png", {&Param::embed_image,
|
||||
"<img alt=\"\" src=\"data:image/png;base64,",
|
||||
"\">", true,
|
||||
"<img alt=\"\" src=\"",
|
||||
"\">" }}
|
||||
});
|
||||
|
||||
const std::map<std::string, std::string> FORMAT_MIME_TYPE_MAP({
|
||||
|
@ -32,6 +32,7 @@ struct EmbedStringEntry
|
||||
// used when *embed_flag == true
|
||||
std::string prefix_embed;
|
||||
std::string suffix_embed;
|
||||
bool base64_encode;
|
||||
// used when *embed_flag == false
|
||||
std::string prefix_external;
|
||||
std::string suffix_external;
|
||||
|