diff --git a/modules/database/src/ioc/db/dbCommonInput.pod b/modules/database/src/ioc/db/dbCommonInput.dbd.pod similarity index 99% rename from modules/database/src/ioc/db/dbCommonInput.pod rename to modules/database/src/ioc/db/dbCommonInput.dbd.pod index 079277002..5ce9136b1 100644 --- a/modules/database/src/ioc/db/dbCommonInput.pod +++ b/modules/database/src/ioc/db/dbCommonInput.dbd.pod @@ -3,7 +3,7 @@ # in file LICENSE that is included with this distribution. #************************************************************************* -=head1 Fields Common to Input Record Types +=title Fields Common to Input Record Types This section describes fields that are found in many input record types. These fields usually have the same meaning whenever they are used. @@ -206,3 +206,5 @@ If SIMM is not YES, NO or RAW, a SOFT alarm with a severity of INVALID is raised, and return status is set to -1. =back + +=cut diff --git a/modules/database/src/ioc/db/dbCommonOutput.pod b/modules/database/src/ioc/db/dbCommonOutput.dbd.pod similarity index 99% rename from modules/database/src/ioc/db/dbCommonOutput.pod rename to modules/database/src/ioc/db/dbCommonOutput.dbd.pod index b60468269..cfea659c0 100644 --- a/modules/database/src/ioc/db/dbCommonOutput.pod +++ b/modules/database/src/ioc/db/dbCommonOutput.dbd.pod @@ -3,7 +3,7 @@ # in file LICENSE that is included with this distribution. #************************************************************************* -=head1 Fields Common to Output Record Types +=title Fields Common to Output Record Types This section describes fields that are found in many output record types. These fields usually have the same meaning whenever they are used. @@ -237,3 +237,5 @@ If SIMM is not YES or NO, a SOFT alarm with a severity of INVALID is raised, and return status is set to -1. =back + +=cut diff --git a/modules/database/src/ioc/db/dbCommonRecord.dbd.pod b/modules/database/src/ioc/db/dbCommonRecord.dbd.pod index e331b8e00..fcbea4200 100644 --- a/modules/database/src/ioc/db/dbCommonRecord.dbd.pod +++ b/modules/database/src/ioc/db/dbCommonRecord.dbd.pod @@ -3,7 +3,7 @@ # in file LICENSE that is included with this distribution. #************************************************************************* -=head1 Fields Common to All Record Types +=title Fields Common to All Record Types This section contains a description of the fields that are common to all record types. These fields are defined in dbCommon.dbd. diff --git a/modules/database/src/tools/dbdToHtml.pl b/modules/database/src/tools/dbdToHtml.pl index 8725abd96..20ec72202 100644 --- a/modules/database/src/tools/dbdToHtml.pl +++ b/modules/database/src/tools/dbdToHtml.pl @@ -141,7 +141,8 @@ __END_DOCTYPE my $title = shift; return $podHtml->idify($title, 1); } -} else { # Fall back to HTML +} +else { # Regular HTML $Pod::Simple::HTML::Content_decl = $contentType; $podHtml = EPICS::PodHtml->new(); $podHtml->html_css('style.css'); @@ -153,7 +154,13 @@ __END_DOCTYPE } # Parse the Pod text from the root DBD object -my $pod = join "\n", '=for html
', '', +my $pod = join "\n", + '=for html
', + '', + 'L', + '', + '=for html
', + '', map { # Handle a 'recordtype' Pod directive if (m/^ =recordtype \s+ (\w+) /x) { @@ -173,13 +180,16 @@ my $pod = join "\n", '=for html
', '', } elsif (m/^ =title \s+ (.*)/x) { $title = $1; - "=head1 $title"; + "=head1 EPICS Reference: $title"; } else { $_; } } $dbd->pod, - '=for html
', ''; + '=for html

', + '', + 'L', + ''; $podHtml->force_title($podHtml->encode_entities($title)); $podHtml->perldoc_url_prefix(''); @@ -307,7 +317,7 @@ sub DBD::Recfield::writable { =pod -=head1 Converting Wiki Record Reference to POD +=head1 Writing Record Reference as POD If you open the src/std/rec/aiRecord.dbd.pod file in your favourite plain text editor you'll see what input was required to generate the aiRecord.html file. @@ -320,13 +330,14 @@ When we add POD markup to a record type, we rename its *Record.dbd file to system to find it by its new name. The POD content is effectively just a new kind of comment that appears in .dbd.pod files, which the formatter knows how to convert into HTML. The build also generates a plain *Record.dbd file from this -same input file by stripping out all of the POD markup. +same input file by stripping out all of the POD markup, so make sure to remove +the old *Record.dbd file from your source directory. Documentation for Perl's POD markup standard can be found online at -L or you may be able to type 'perldoc -perlpod' into a Linux command-line to see the same text. We added a few POD -keywords of our own to handle the table generation, and I'll cover those briefly -below. +L or you may be able to type +C at a Linux command-line to see the same text. +We added a few POD keywords of our own to handle the table generation, and we'll +cover those briefly below. POD text can appear almost anywhere in a dbd.pod file. It always starts with a line "=[keyword] [additional text...]" where [keyword] is "title", "head1" @@ -390,4 +401,8 @@ table that lists all the choices found in the named menu. Any MENU fields in the field tables that refer to a locally-defined menu will generate a link to a document section which must be titled "Menu [menuName]". +The "title" keyword should only appear once in each file, it sets the document +title as well as generating a "head1" heading with "EPICS Reference:" pre-pended +to the text. + =cut