Merge branch 'header_mod'

This commit is contained in:
Ward Fisher 2015-08-17 16:00:42 -06:00
commit 32d788fc7d
8 changed files with 193 additions and 21 deletions

View File

@ -873,12 +873,21 @@ IF(ENABLE_DOXYGEN)
SET(BUILD_INTERNAL_DOCS NO CACHE STRING "") SET(BUILD_INTERNAL_DOCS NO CACHE STRING "")
ENDIF() ENDIF()
OPTION(DOXYGEN_ENABLE_SERVER_SIDE_SEARCH "Enable doxygen server-side search. This is of interest to developers only." OFF) ###
IF(DOXYGEN_ENABLE_SERVER_SIDE_SEARCH) #
SET(SERVER_SIDE_SEARCH YES CACHE STRING "") # If we are building release documentation, we need to set some
# variables that will be used in the Doxygen.in template.
###
OPTION(ENABLE_DOXYGEN_BUILD_RELEASE_DOCS "Build release documentation. This is of interest only to the netCDF developers." OFF)
IF(ENABLE_DOXYGEN_BUILD_RELEASE_DOCS)
SET(DOXYGEN_CSS_FILE "${CMAKE_SOURCE_DIR}/docs/release.css" CACHE STRING "")
SET(DOXYGEN_HEADER_FILE "${CMAKE_SOURCE_DIR}/docs/release_header.html" CACHE STRING "")
SET(DOXYGEN_SEARCHENGINE "NO" CACHE STRING "")
ELSE() ELSE()
SET(SERVER_SIDE_SEARCH NO CACHE STRING "") SET(DOXYGEN_CSS_FILE "" CACHE STRING "")
ENDIF() SET(DOXYGEN_HEADER_FILE "" CACHE STRING "")
SET(DOXYGEN_SEARCHENGINE "YES" CACHE STRING "")
ENDIF(ENABLE_DOXYGEN_BUILD_RELEASE_DOCS)
# Option to turn on the TODO list in the doxygen-generated documentation. # Option to turn on the TODO list in the doxygen-generated documentation.
OPTION(DOXYGEN_ENABLE_TASKS "Turn on test, todo, bug lists in documentation. This is of interest to developers only." OFF) OPTION(DOXYGEN_ENABLE_TASKS "Turn on test, todo, bug lists in documentation. This is of interest to developers only." OFF)
IF(DOXYGEN_ENABLE_TASKS) IF(DOXYGEN_ENABLE_TASKS)
@ -920,7 +929,7 @@ ENDIF()
# Set some of the options as advanced. # Set some of the options as advanced.
MARK_AS_ADVANCED(ENABLE_INTERNAL_DOCS VALGRIND_TESTS ENABLE_PNETCDF ENABLE_COVERAGE_TESTS) MARK_AS_ADVANCED(ENABLE_INTERNAL_DOCS VALGRIND_TESTS ENABLE_PNETCDF ENABLE_COVERAGE_TESTS)
MARK_AS_ADVANCED(ENABLE_DAP_REMOTE_TESTS ENABLE_DAP_LONG_TESTS USE_REMOTE_CDASH) MARK_AS_ADVANCED(ENABLE_DAP_REMOTE_TESTS ENABLE_DAP_LONG_TESTS USE_REMOTE_CDASH)
MARK_AS_ADVANCED(DOXYGEN_ENABLE_SERVER_SIDE_SEARCH DOXYGEN_ENABLE_TASKS) MARK_AS_ADVANCED(ENABLE_DOXYGEN_BUILD_RELEASE_DOCS DOXYGEN_ENABLE_TASKS)
################################ ################################
# Option checks # Option checks
################################ ################################

View File

@ -1096,7 +1096,7 @@ HTML_FILE_EXTENSION = .html
# of the possible markers and block names see the documentation. # of the possible markers and block names see the documentation.
# This tag requires that the tag GENERATE_HTML is set to YES. # This tag requires that the tag GENERATE_HTML is set to YES.
HTML_HEADER = HTML_HEADER = docs/extra_header.html
# The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each # The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each
# generated HTML page. If the tag is left blank doxygen will generate a standard # generated HTML page. If the tag is left blank doxygen will generate a standard
@ -1129,7 +1129,7 @@ HTML_STYLESHEET =
# see the documentation. # see the documentation.
# This tag requires that the tag GENERATE_HTML is set to YES. # This tag requires that the tag GENERATE_HTML is set to YES.
HTML_EXTRA_STYLESHEET = HTML_EXTRA_STYLESHEET = docs/extra.css
# The HTML_EXTRA_FILES tag can be used to specify one or more extra images or # The HTML_EXTRA_FILES tag can be used to specify one or more extra images or
# other source files which should be copied to the HTML output directory. Note # other source files which should be copied to the HTML output directory. Note
@ -1527,7 +1527,7 @@ MATHJAX_CODEFILE =
# The default value is: YES. # The default value is: YES.
# This tag requires that the tag GENERATE_HTML is set to YES. # This tag requires that the tag GENERATE_HTML is set to YES.
SEARCHENGINE = YES SEARCHENGINE = NO
# When the SERVER_BASED_SEARCH tag is enabled the search engine will be # When the SERVER_BASED_SEARCH tag is enabled the search engine will be
# implemented using a web server instead of a web client using Javascript. There # implemented using a web server instead of a web client using Javascript. There

View File

@ -95,12 +95,25 @@ test "x$enable_doxygen_tasks" = xyes || enable_doxygen_tasks=no
AM_CONDITIONAL([SHOW_DOXYGEN_TAG_LIST], [test "x$enable_doxygen_tasks" = xyes]) AM_CONDITIONAL([SHOW_DOXYGEN_TAG_LIST], [test "x$enable_doxygen_tasks" = xyes])
AC_SUBST([SHOW_DOXYGEN_TAG_LIST], [$enable_doxygen_tasks]) AC_SUBST([SHOW_DOXYGEN_TAG_LIST], [$enable_doxygen_tasks])
AC_ARG_ENABLE([doxygen-server-side-search], ###
[AS_HELP_STRING([--enable-doxygen-server-side-search], # Determine if we should build documentation
[Enable doxygen server-side search. This is of interest to developers only, or users who will serve the documentation via a web server instead of browsing locally.])]) # configured for releases on the Unidata web server.
test "x$enable_doxygen_server_side_search" = xyes || enable_doxygen_server_side_search=no ###
AM_CONDITIONAL([SERVER_SIDE_SEARCH], [test "x$enable_doxygen_server_side_search" = xyes]) AC_ARG_ENABLE([doxygen-build-release-docs],
AC_SUBST([SERVER_SIDE_SEARCH], [$enable_doxygen_server_side_search]) [AS_HELP_STRING([--enable-doxygen-build-release-docs],
[Build release documentation. This is of interest only to developers.])])
test "x$enable_doxygen_build_release_docs" = xyes || enable_doxygen_build_release_docs=no
AM_CONDITIONAL([DOXYGEN_BUILD_RELEASE_DOCS], [test "x$enable_doxygen_build_release_docs" = xyes])
if test $enable_doxygen_build_release_docs = yes; then
AC_SUBST([DOXYGEN_CSS_FILE], ["release.css"])
AC_SUBST([DOXYGEN_HEADER_FILE], ["release_header.html"])
AC_SUBST([DOXYGEN_SEARCHENGINE], ["NO"])
else
AC_SUBST([DOXYGEN_CSS_FILE], [])
AC_SUBST([DOXYGEN_HEADER_FILE], [])
AC_SUBST([DOXYGEN_SEARCHENGINE], ["YES"])
fi
AC_ARG_ENABLE([doxygen-pdf-output], AC_ARG_ENABLE([doxygen-pdf-output],
[AS_HELP_STRING([--enable-doxygen-pdf-output], [AS_HELP_STRING([--enable-doxygen-pdf-output],
@ -999,7 +1012,6 @@ AM_CONDITIONAL(BUILD_DISKLESS, [test x$enable_diskless = xyes])
AM_CONDITIONAL(BUILD_MMAP, [test x$enable_mmap = xyes]) AM_CONDITIONAL(BUILD_MMAP, [test x$enable_mmap = xyes])
AM_CONDITIONAL(BUILD_DOCS, [test x$enable_doxygen = xyes]) AM_CONDITIONAL(BUILD_DOCS, [test x$enable_doxygen = xyes])
AM_CONDITIONAL(SHOW_DOXYGEN_TAG_LIST, [test x$enable_doxygen_tasks = xyes]) AM_CONDITIONAL(SHOW_DOXYGEN_TAG_LIST, [test x$enable_doxygen_tasks = xyes])
AM_CONDITIONAL(SERVER_SIDE_SEARCH, [test x$enable_doxygen_server_side_search = xyes])
# If the machine doesn't have a long long, and we want netCDF-4, then # If the machine doesn't have a long long, and we want netCDF-4, then
# we've got problems! # we've got problems!

View File

@ -7,6 +7,8 @@ IF(ENABLE_DOXYGEN)
FILE(GLOB COPY_FILES ${CMAKE_CURRENT_SOURCE_DIR}/*.html ${CMAKE_CURRENT_SOURCE_DIR}/images ${CMAKE_CURRENT_SOURCE_DIR}/*.doc ${CMAKE_CURRENT_SOURCE_DIR}/*.xml ${CMAKE_CURRENT_SOURCE_DIR}/*.m4 ${CMAKE_CURRENT_SOURCE_DIR}/*.texi) FILE(GLOB COPY_FILES ${CMAKE_CURRENT_SOURCE_DIR}/*.html ${CMAKE_CURRENT_SOURCE_DIR}/images ${CMAKE_CURRENT_SOURCE_DIR}/*.doc ${CMAKE_CURRENT_SOURCE_DIR}/*.xml ${CMAKE_CURRENT_SOURCE_DIR}/*.m4 ${CMAKE_CURRENT_SOURCE_DIR}/*.texi)
FILE(COPY ${COPY_FILES} DESTINATION ${CMAKE_CURRENT_BINARY_DIR}/) FILE(COPY ${COPY_FILES} DESTINATION ${CMAKE_CURRENT_BINARY_DIR}/)
# Set abs_top_srcdir to work with the autotools # Set abs_top_srcdir to work with the autotools
# doxyfile template. # doxyfile template.
SET(abs_top_srcdir ${CMAKE_SOURCE_DIR}) SET(abs_top_srcdir ${CMAKE_SOURCE_DIR})
@ -16,7 +18,6 @@ IF(ENABLE_DOXYGEN)
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in
${CMAKE_CURRENT_BINARY_DIR}/Doxyfile @ONLY) ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile @ONLY)
# Create auth.md by combining auth.md.in and oc2/ocauth.md # Create auth.md by combining auth.md.in and oc2/ocauth.md
ADD_CUSTOM_TARGET(auth_doc ALL ADD_CUSTOM_TARGET(auth_doc ALL

View File

@ -1120,7 +1120,7 @@ HTML_FILE_EXTENSION = .html
# of the possible markers and block names see the documentation. # of the possible markers and block names see the documentation.
# This tag requires that the tag GENERATE_HTML is set to YES. # This tag requires that the tag GENERATE_HTML is set to YES.
HTML_HEADER = HTML_HEADER = @DOXYGEN_HEADER_FILE@
# The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each # The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each
# generated HTML page. If the tag is left blank doxygen will generate a standard # generated HTML page. If the tag is left blank doxygen will generate a standard
@ -1142,7 +1142,7 @@ HTML_FOOTER = @abs_top_srcdir@/docs/footer.html
# obsolete. # obsolete.
# This tag requires that the tag GENERATE_HTML is set to YES. # This tag requires that the tag GENERATE_HTML is set to YES.
HTML_STYLESHEET = HTML_STYLESHEET = @DOXYGEN_CSS_FILE@
# The HTML_EXTRA_STYLESHEET tag can be used to specify an additional user- # The HTML_EXTRA_STYLESHEET tag can be used to specify an additional user-
# defined cascading style sheet that is included after the standard style sheets # defined cascading style sheet that is included after the standard style sheets
@ -1550,7 +1550,7 @@ MATHJAX_CODEFILE =
# The default value is: YES. # The default value is: YES.
# This tag requires that the tag GENERATE_HTML is set to YES. # This tag requires that the tag GENERATE_HTML is set to YES.
SEARCHENGINE = YES SEARCHENGINE = @DOXYGEN_SEARCHENGINE@
# When the SERVER_BASED_SEARCH tag is enabled the search engine will be # When the SERVER_BASED_SEARCH tag is enabled the search engine will be
# implemented using a web server instead of a web client using Javascript. There # implemented using a web server instead of a web client using Javascript. There
@ -1562,7 +1562,7 @@ SEARCHENGINE = YES
# The default value is: NO. # The default value is: NO.
# This tag requires that the tag SEARCHENGINE is set to YES. # This tag requires that the tag SEARCHENGINE is set to YES.
SERVER_BASED_SEARCH = @SERVER_SIDE_SEARCH@ SERVER_BASED_SEARCH = NO
# When EXTERNAL_SEARCH tag is enabled doxygen will no longer generate the PHP # When EXTERNAL_SEARCH tag is enabled doxygen will no longer generate the PHP
# script for searching. Instead the search results are written to an XML file # script for searching. Instead the search results are written to an XML file

29
docs/release.css Normal file
View File

@ -0,0 +1,29 @@
.tabs {
width: 100% !important;
}
.tabs ul.tablist {
width: 100% !important;
}
.tabs ul.tablist li.linkMenu select#versions {
vertical-align: middle;
height: ;
margin: 8px 0 0 10px !important;
padding: 0;
}
.tabs ul.tablist li.searchForm {
float: right;
padding: 0;
margin: 0;
}
.tabs ul.tablist li.searchForm form#cse-search-box {
float: right;
margin: 8px 10px 0 0;
}
.tabs ul.tablist li.searchForm form#cse-search-box input#search {
border-radius: 5px;
margin: 0 5px 0 0;
}

92
docs/release_header.html Normal file
View File

@ -0,0 +1,92 @@
<!-- HTML header for doxygen 1.8.10-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen $doxygenversion"/>
<!--BEGIN PROJECT_NAME--><title>$projectname: $title</title><!--END PROJECT_NAME-->
<!--BEGIN !PROJECT_NAME--><title>$title</title><!--END !PROJECT_NAME-->
<link href="$relpath^tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="http://www.unidata.ucar.edu/js/jquery/jquery-latest.min.js"></script>
<script type="text/javascript" src="$relpath^jquery.js"></script>
<script type="text/javascript" src="$relpath^dynsections.js"></script>
$treeview
$mathjax
<link href="$relpath^$stylesheet" rel="stylesheet" type="text/css" />
$extrastylesheet
<script type="text/javascript">
$( document ).ready(function() {
var $searchForm = "<form name=\"google\" action=\"http://www.unidata.ucar.edu/search.jsp\" id=\"cse-search-box\">" +
" <input type=\"hidden\" name=\"locationName\" value=\"NetCDF Documentation\"></input>" +
" <input type=\"hidden\" name=\"hq\" value=\"site:www.unidata.ucar.edu/software/netcdf/docs\"></input>" +
" <input type=\"hidden\" name=\"cx\" value=\"008424664622949020059:afj38jxaljc\"></input>" +
" <input type=\"hidden\" name=\"cof\" value=\"FORID:9\"></input>" +
" <input type=\"hidden\" name=\"ie\" value=\"UTF-8\"></input>" +
" <input type=\"text\" autocomplete=\"on\" name=\"q\" maxlength=\"255\" id=\"search\"></input>" +
" <input type=\"submit\" name=\"sa\" value=\"search\" id=\"form_submit\"></input>" +
"</form>";
var $linkMenu = "<select id=\"versions\">" +
" <option value=\"http://www.unidata.ucar.edu\">$projectnumber</option>" +
" <option value=\"http://www.unidata.ucar.edu/software/netcdf\">some other project number</option>" +
"</select>";
$("#navrow1 ul.tablist").append('<li class=\"linkMenu\"><span class="tab">' + $linkMenu + '</span></li>');
$("#navrow1 ul.tablist").append('<li class=\"searchForm\"><span class="tab">' + $searchForm + '</span></li>');
$("#versions").change(function() {
window.location.href = $(this).val();
});
});
</script>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<!--BEGIN TITLEAREA-->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<!--BEGIN PROJECT_LOGO-->
<td id="projectlogo"><img alt="Logo" src="$relpath^$projectlogo"/></td>
<!--END PROJECT_LOGO-->
<!--BEGIN PROJECT_NAME-->
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">$projectname
<!--BEGIN PROJECT_NUMBER-->&#160;<span id="projectnumber">$projectnumber</span><!--END PROJECT_NUMBER-->
</div>
<!--BEGIN PROJECT_BRIEF--><div id="projectbrief">$projectbrief</div><!--END PROJECT_BRIEF-->
</td>
<!--END PROJECT_NAME-->
<!--BEGIN !PROJECT_NAME-->
<!--BEGIN PROJECT_BRIEF-->
<td style="padding-left: 0.5em;">
<div id="projectbrief">$projectbrief</div>
</td>
<!--END PROJECT_BRIEF-->
<!--END !PROJECT_NAME-->
<!--BEGIN DISABLE_INDEX-->
<!--BEGIN SEARCHENGINE-->
<td>
<form name="google" action="http://www.unidata.ucar.edu/search.jsp" id="cse-search-box">
<input type="hidden" name="locationName" value="NetCDF Documentation"></input>
<input type="hidden" name="hq" value="site:www.unidata.ucar.edu/software/netcdf/docs">
<input type="hidden" name="cx" value="008424664622949020059:afj38jxaljc" />
<input type="hidden" name="cof" value="FORID:9" />
<input type="hidden" name="ie" value="UTF-8" />
<input type="text" autocomplete="on" name="q" maxlength="255" id="search"/>
<input type="submit" name="sa" value="search" id="form_submit" />
</form>
<script type="text/javascript" src="http://www.google.com/coop/cse/brand?form=cse-search-box&lang=en"></script>
</td>
<!--END SEARCHENGINE-->
<!--END DISABLE_INDEX-->
</tr>
</tbody>
</table>
</div>
<!--END TITLEAREA-->
<!-- end header part -->

29
extra.css Normal file
View File

@ -0,0 +1,29 @@
.tabs {
width: 100% !important;
}
.tabs ul.tablist {
width: 100% !important;
}
.tabs ul.tablist li.linkMenu select#versions {
vertical-align: middle;
height: ;
margin: 8px 0 0 10px !important;
padding: 0;
}
.tabs ul.tablist li.searchForm {
float: right;
padding: 0;
margin: 0;
}
.tabs ul.tablist li.searchForm form#cse-search-box {
float: right;
margin: 8px 10px 0 0;
}
.tabs ul.tablist li.searchForm form#cse-search-box input#search {
border-radius: 5px;
margin: 0 5px 0 0;
}