2016-01-02 17:30:12 -05:00
|
|
|
set (LANGUAGES
|
|
|
|
en
|
|
|
|
)
|
|
|
|
|
2015-04-28 18:33:32 -04:00
|
|
|
set (common_SRCS
|
|
|
|
common/communication.adoc
|
|
|
|
common/license.adoc
|
|
|
|
common/links.adoc
|
|
|
|
)
|
|
|
|
|
2015-04-28 14:37:50 -04:00
|
|
|
set (UG_SRCS
|
2016-01-02 17:30:12 -05:00
|
|
|
docinfo.html
|
|
|
|
docinfo.xml
|
|
|
|
acknowledgements.adoc
|
2016-10-14 16:36:34 -04:00
|
|
|
astro_data.adoc
|
2016-01-02 17:30:12 -05:00
|
|
|
config-details.adoc
|
|
|
|
controls-functions-center.adoc
|
|
|
|
controls-functions-left.adoc
|
|
|
|
controls-functions-main-window.adoc
|
|
|
|
controls-functions-menus.adoc
|
|
|
|
controls-functions-messages.adoc
|
|
|
|
controls-functions-status-bar.adoc
|
|
|
|
controls-functions-wide-graph.adoc
|
|
|
|
cooperating-programs.adoc
|
2017-08-03 14:18:34 -04:00
|
|
|
decoder_notes.adoc
|
2016-01-02 17:30:12 -05:00
|
|
|
faq.adoc
|
|
|
|
font-sizes.adoc
|
|
|
|
install-from-source.adoc
|
|
|
|
install-linux.adoc
|
|
|
|
install-mac.adoc
|
|
|
|
install-windows.adoc
|
|
|
|
introduction.adoc
|
2020-09-23 15:03:33 -04:00
|
|
|
intro_subsections.adoc
|
2016-01-02 17:30:12 -05:00
|
|
|
logging.adoc
|
|
|
|
make-qso.adoc
|
2017-09-28 15:51:04 -04:00
|
|
|
measurement_tools.adoc
|
2016-01-02 17:30:12 -05:00
|
|
|
new_features.adoc
|
|
|
|
platform-dependencies.adoc
|
2016-10-25 14:04:33 -04:00
|
|
|
protocols.adoc
|
2016-09-08 15:15:17 -04:00
|
|
|
settings-advanced.adoc
|
2016-01-02 17:30:12 -05:00
|
|
|
settings-audio.adoc
|
|
|
|
settings-colors.adoc
|
|
|
|
settings-frequencies.adoc
|
|
|
|
settings-general.adoc
|
|
|
|
settings-radio.adoc
|
|
|
|
settings-reporting.adoc
|
|
|
|
settings-txmacros.adoc
|
|
|
|
support.adoc
|
|
|
|
system-requirements.adoc
|
|
|
|
transceiver-setup.adoc
|
|
|
|
tutorial-example1.adoc
|
|
|
|
tutorial-example2.adoc
|
2017-07-12 15:32:17 -04:00
|
|
|
tutorial-example3.adoc
|
2019-06-06 14:15:12 -04:00
|
|
|
tutorial-example4.adoc
|
2020-09-23 15:03:33 -04:00
|
|
|
tutorial-example5.adoc
|
|
|
|
tutorial-example6.adoc
|
2016-01-02 17:30:12 -05:00
|
|
|
tutorial-main-window.adoc
|
|
|
|
tutorial-wide-graph-settings.adoc
|
|
|
|
utilities.adoc
|
|
|
|
vhf-features.adoc
|
|
|
|
wsjtx-main.adoc
|
|
|
|
wspr.adoc
|
2015-04-28 14:37:50 -04:00
|
|
|
)
|
|
|
|
|
|
|
|
set (UG_IMGS
|
2016-01-02 17:30:12 -05:00
|
|
|
images/130610_2343-wav-80.png
|
2016-10-14 16:36:34 -04:00
|
|
|
images/AstroData_2.png
|
|
|
|
images/Astronomical_data.png
|
2017-08-02 15:23:42 -04:00
|
|
|
images/auto-seq.png
|
2016-01-02 17:30:12 -05:00
|
|
|
images/band-settings.png
|
2019-07-18 13:45:14 -04:00
|
|
|
images/Best_S+P.png
|
2016-01-02 17:30:12 -05:00
|
|
|
images/colors.png
|
2016-10-14 16:36:34 -04:00
|
|
|
images/config-menu.png
|
2016-01-02 17:30:12 -05:00
|
|
|
images/decode-menu.png
|
|
|
|
images/decodes.png
|
2016-10-26 11:36:22 -04:00
|
|
|
images/download_samples.png
|
2018-02-22 08:55:42 -05:00
|
|
|
images/echo_144.png
|
2020-05-08 10:02:05 -04:00
|
|
|
images/EME_Deep_0.png
|
|
|
|
images/EME_Deep_1.png
|
|
|
|
images/EME_Deep_2.png
|
2016-01-02 17:30:12 -05:00
|
|
|
images/file-menu.png
|
2017-09-28 15:51:04 -04:00
|
|
|
images/FreqCal.png
|
|
|
|
images/FreqCal_Graph.png
|
|
|
|
images/FreqCal_Results.png
|
2016-01-02 17:30:12 -05:00
|
|
|
images/freemsg.png
|
2020-09-23 15:03:33 -04:00
|
|
|
images/FST4_center.png
|
|
|
|
images/FST4_Decoding_Limits.png
|
|
|
|
images/FST4W_RoundRobin.png
|
2019-06-06 14:15:12 -04:00
|
|
|
images/ft4_decodes.png
|
|
|
|
images/ft4_waterfall.png
|
2017-07-12 15:32:17 -04:00
|
|
|
images/ft8_decodes.png
|
2018-12-11 11:24:04 -05:00
|
|
|
images/FT8_waterfall.png
|
2016-01-02 17:30:12 -05:00
|
|
|
images/help-menu.png
|
2016-10-24 13:01:47 -04:00
|
|
|
images/JT4F.png
|
2016-10-24 16:48:24 -04:00
|
|
|
images/JT65B.png
|
2017-10-02 14:33:17 -04:00
|
|
|
images/keyboard-shortcuts.png
|
2016-10-25 14:04:33 -04:00
|
|
|
images/MSK144.png
|
2021-03-05 09:29:21 -05:00
|
|
|
images/Q65_6m_ionoscatter.png
|
2016-10-25 14:04:33 -04:00
|
|
|
images/WSPR_WideGraphControls.png
|
|
|
|
images/WSPR_1a.png
|
|
|
|
images/WSPR_2.png
|
2016-01-02 17:30:12 -05:00
|
|
|
images/jtalert.png
|
|
|
|
images/keyboard-shortcuts.png
|
|
|
|
images/log-qso.png
|
|
|
|
images/MacAppMenu.png
|
2016-10-14 16:36:34 -04:00
|
|
|
images/main-ui.png
|
2016-01-02 17:30:12 -05:00
|
|
|
images/main-ui-controls.png
|
|
|
|
images/misc-controls-center.png
|
|
|
|
images/misc-main-ui.png
|
|
|
|
images/mode-menu.png
|
|
|
|
images/new-msg-box.png
|
|
|
|
images/psk-reporter.png
|
|
|
|
images/r3666-config-screen-80.png
|
|
|
|
images/r3666-main-ui-80.png
|
|
|
|
images/r4148-txmac-ui.png
|
|
|
|
images/RadioTab.png
|
|
|
|
images/reporting.png
|
|
|
|
images/save-menu.png
|
2016-09-08 15:15:17 -04:00
|
|
|
images/settings-advanced.png
|
2016-01-02 17:30:12 -05:00
|
|
|
images/settings-audio.png
|
|
|
|
images/settings-frequencies.png
|
|
|
|
images/settings-general.png
|
|
|
|
images/setup-menu.png
|
|
|
|
images/special-mouse-commands.png
|
|
|
|
images/status-bar-a.png
|
2017-08-02 15:23:42 -04:00
|
|
|
images/tools-menu.png
|
2016-01-02 17:30:12 -05:00
|
|
|
images/traditional-msg-box.png
|
|
|
|
images/tx-macros.png
|
2017-10-02 09:49:37 -04:00
|
|
|
images/VHF_controls.png
|
2016-01-02 17:30:12 -05:00
|
|
|
images/view-menu.png
|
|
|
|
images/wide-graph-controls.png
|
2020-05-19 15:18:13 -04:00
|
|
|
images/Windows_Dark.png
|
2015-04-28 14:37:50 -04:00
|
|
|
)
|
|
|
|
|
2015-11-18 19:08:30 -05:00
|
|
|
find_program (ASCIIDOCTOR_EXECUTABLE NAMES asciidoctor)
|
|
|
|
if (NOT ASCIIDOCTOR_EXECUTABLE)
|
|
|
|
message (FATAL_ERROR "asciidoctor is required to build the documentation
|
2015-04-28 20:51:52 -04:00
|
|
|
|
2015-11-18 19:08:30 -05:00
|
|
|
Building the documenation may optionally be turned off by setting the CMake
|
2015-05-27 18:06:59 -04:00
|
|
|
option WSJT_GENERATE_DOCS to OFF.")
|
2015-11-18 19:08:30 -05:00
|
|
|
endif (NOT ASCIIDOCTOR_EXECUTABLE)
|
2015-04-28 14:37:50 -04:00
|
|
|
|
2015-11-20 21:34:20 -05:00
|
|
|
find_program (FOPUB_EXECUTABLE NAMES fopub)
|
|
|
|
|
2015-04-28 14:37:50 -04:00
|
|
|
include (CMakeParseArguments)
|
|
|
|
|
2015-11-20 21:34:20 -05:00
|
|
|
# generate a document from asciidoc text files(s)
|
2015-04-28 14:37:50 -04:00
|
|
|
#
|
2015-11-20 21:34:20 -05:00
|
|
|
# HTML - generate an HTML document
|
|
|
|
# PDF - generate a PDF document
|
2015-04-28 14:37:50 -04:00
|
|
|
# SOURCE - top level asciidoc file
|
2015-11-18 19:08:30 -05:00
|
|
|
# ASCIIDOCTOR_OPTIONS - asciidoctor command options
|
2015-04-28 14:37:50 -04:00
|
|
|
# DEPENDS - dependent files
|
2015-11-20 21:34:20 -05:00
|
|
|
function (document)
|
2016-01-02 17:30:12 -05:00
|
|
|
cmake_parse_arguments (_args "HTML" "SOURCE;LANG;OUTPUT" "ASCIIDOCTOR_OPTIONS;PDF;DEPENDS" ${ARGN})
|
2015-11-20 21:34:20 -05:00
|
|
|
get_filename_component (_source_path ${_args_SOURCE} PATH)
|
|
|
|
get_filename_component (_source_name ${_args_SOURCE} NAME)
|
|
|
|
get_filename_component (_output_name_we ${_args_SOURCE} NAME_WE)
|
|
|
|
|
|
|
|
# HTML
|
|
|
|
if (${_args_HTML})
|
2016-01-02 17:30:12 -05:00
|
|
|
set (_html_file ${CMAKE_CURRENT_BINARY_DIR}/${_output_name_we}_${lang}.html)
|
2015-11-20 21:34:20 -05:00
|
|
|
add_custom_command (
|
|
|
|
OUTPUT ${_html_file}
|
2016-01-02 17:30:12 -05:00
|
|
|
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/${_source_path}/${lang}
|
2015-11-20 21:34:20 -05:00
|
|
|
COMMAND ${ASCIIDOCTOR_EXECUTABLE} ${_args_ASCIIDOCTOR_OPTIONS}
|
|
|
|
-b html5
|
2019-11-27 14:18:45 -05:00
|
|
|
-a nofooter
|
2021-02-26 11:22:16 -05:00
|
|
|
-a VERSION_MAJOR=${PROJECT_VERSION_MAJOR}
|
|
|
|
-a VERSION_MINOR=${PROJECT_VERSION_MINOR}
|
|
|
|
-a VERSION_PATCH=${PROJECT_VERSION_PATCH}
|
2015-11-20 21:34:20 -05:00
|
|
|
-a VERSION=${wsjtx_VERSION}
|
|
|
|
--out-file=${_html_file} ${_source_name}
|
|
|
|
DEPENDS ${_args_DEPENDS}
|
|
|
|
COMMENT "Generating ${_html_file}"
|
|
|
|
)
|
|
|
|
list (APPEND _output_files ${_html_file})
|
|
|
|
endif (${_args_HTML})
|
|
|
|
|
|
|
|
# PDF
|
|
|
|
if (_args_PDF AND EXISTS ${FOPUB_EXECUTABLE})
|
2016-01-02 17:30:12 -05:00
|
|
|
set (_docbook_file ${CMAKE_CURRENT_BINARY_DIR}/${_output_name_we}_${lang}.xml)
|
|
|
|
set (_pdf_file_we ${CMAKE_CURRENT_BINARY_DIR}/${_output_name_we}_${lang})
|
2016-04-24 15:05:03 -04:00
|
|
|
if (${lang} MATCHES "^(en|es|fr)$") # en-us, fr-ca and es-{mx,co} use US-Letter or equivalent
|
|
|
|
set (_usl_commands
|
|
|
|
COMMAND ${FOPUB_EXECUTABLE} ARGS ${_docbook_file} ${_args_PDF} -param paper.type USLetter
|
|
|
|
COMMAND ${CMAKE_COMMAND} ARGS -E rename ${_pdf_file_we}.pdf '${_pdf_file_we} \(USLetter\).pdf'
|
|
|
|
)
|
|
|
|
list (APPEND _output_files "${_pdf_file_we} (USLetter).pdf")
|
|
|
|
endif ()
|
|
|
|
list (APPEND _output_files "${_pdf_file_we}.pdf")
|
2015-11-20 21:34:20 -05:00
|
|
|
add_custom_command (
|
2016-04-24 15:05:03 -04:00
|
|
|
OUTPUT ${_docbook_file} ${_output_files}
|
2016-01-02 17:30:12 -05:00
|
|
|
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/${_source_path}/${lang}
|
2015-11-20 21:34:20 -05:00
|
|
|
COMMAND ${ASCIIDOCTOR_EXECUTABLE} ARGS ${_args_ASCIIDOCTOR_OPTIONS}
|
|
|
|
-b docbook
|
|
|
|
-a data-uri!
|
2021-02-26 11:22:16 -05:00
|
|
|
-a VERSION_MAJOR=${wsjtx_VERSION_MAJOR}
|
|
|
|
-a VERSION_MINOR=${wsjtx_VERSION_MINOR}
|
|
|
|
-a VERSION_PATCH=${wsjtx_VERSION_PATCH}${BUILD_TYPE_REVISION}
|
2015-11-20 21:34:20 -05:00
|
|
|
-a VERSION=${wsjtx_VERSION}
|
|
|
|
-D ${CMAKE_CURRENT_BINARY_DIR}
|
|
|
|
-o ${_docbook_file} ${_source_name}
|
2016-04-24 15:05:03 -04:00
|
|
|
${_usl_commands}
|
2015-11-20 21:34:20 -05:00
|
|
|
COMMAND ${FOPUB_EXECUTABLE} ARGS ${_docbook_file} ${_args_PDF} -param paper.type A4
|
2016-04-24 15:05:03 -04:00
|
|
|
COMMAND ${CMAKE_COMMAND} ARGS -E rename ${_pdf_file_we}.pdf '${_pdf_file_we}.pdf'
|
2015-11-20 21:34:20 -05:00
|
|
|
DEPENDS ${_args_DEPENDS}
|
2016-04-24 15:05:03 -04:00
|
|
|
COMMENT "Generating ${_output_files}"
|
2015-11-20 21:34:20 -05:00
|
|
|
)
|
|
|
|
endif (_args_PDF AND EXISTS ${FOPUB_EXECUTABLE})
|
|
|
|
|
|
|
|
set (${_args_OUTPUT} ${_output_files} PARENT_SCOPE)
|
|
|
|
endfunction (document)
|
2015-04-28 14:37:50 -04:00
|
|
|
|
2016-01-02 17:30:12 -05:00
|
|
|
set (htmls)
|
|
|
|
set (pdfs)
|
|
|
|
foreach (lang ${LANGUAGES})
|
|
|
|
set (_sources)
|
|
|
|
foreach (_src ${UG_SRCS} ${UG_IMGS})
|
|
|
|
list (APPEND _sources "user_guide/${lang}/${_src}")
|
|
|
|
endforeach ()
|
|
|
|
document(
|
|
|
|
HTML
|
|
|
|
SOURCE user_guide/wsjtx-main.adoc
|
|
|
|
LANG "${lang}"
|
|
|
|
OUTPUT html
|
|
|
|
ASCIIDOCTOR_OPTIONS -d book -a data-uri -a toc=left -a max-width=1024px
|
|
|
|
DEPENDS ${common_SRCS} ${_sources}
|
|
|
|
)
|
|
|
|
document(
|
|
|
|
PDF -param body.font.master 11 -param body.font.family "'Noto Sans, Helvetica, sans-serif'" -param title.font.family "'Noto Serif, Times New Roman, serif'" -param page.margin.inner 1cm -param page.margin.outer 1cm -param page.margin.top 0.75cm -param page.margin.bottom 0.5cm -param generate.toc 0
|
|
|
|
SOURCE user_guide/wsjtx-main.adoc
|
|
|
|
LANG "${lang}"
|
|
|
|
OUTPUT pdf
|
|
|
|
ASCIIDOCTOR_OPTIONS -d book
|
|
|
|
DEPENDS ${common_SRCS} ${_sources}
|
|
|
|
)
|
|
|
|
list (APPEND htmls "${html}")
|
|
|
|
list (APPEND pdfs "${pdf}")
|
|
|
|
endforeach ()
|
2015-04-28 14:37:50 -04:00
|
|
|
|
2016-01-02 17:30:12 -05:00
|
|
|
add_custom_target (docs ALL DEPENDS ${htmls} ${pdfs})
|
|
|
|
|
|
|
|
foreach (_html ${htmls})
|
|
|
|
get_filename_component (_path ${_html} PATH)
|
|
|
|
get_filename_component (_nwe ${_html} NAME_WE)
|
|
|
|
get_filename_component (_ext ${_html} EXT)
|
|
|
|
string (REGEX REPLACE "_en$" "" _nwe ${_nwe})
|
|
|
|
install (FILES
|
|
|
|
${_html}
|
2017-03-28 09:03:48 -04:00
|
|
|
DESTINATION ${CMAKE_INSTALL_DOCDIR}
|
2016-01-02 17:30:12 -05:00
|
|
|
RENAME ${_nwe}-${wsjtx_VERSION}${_ext}
|
|
|
|
#COMPONENT runtime
|
|
|
|
)
|
2016-09-08 15:15:17 -04:00
|
|
|
endforeach ()
|