Skip to content

Commit

Permalink
Include a TODO comment before any table that we know won't look right…
Browse files Browse the repository at this point in the history
… in PDF

because it has cells containing block elements or multi paragraphs

#13
  • Loading branch information
hossman authored and ctargett committed Sep 21, 2016
1 parent 9e11261 commit c6f6d57
Show file tree
Hide file tree
Showing 23 changed files with 91 additions and 27 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -461,33 +461,23 @@ static void cleanupContent(Document docOut) {
fakeComment.text("// TODO: This '"+list.tagName()+"' has problematic nested lists inside of it, needs manual editing");
list.before(fakeComment);
}

// // pandoc gets really confused when <ol>s get nested, add a comment pointing out
// // manual cleanup is needed
// elements = docOut.select("ol, ul");
// LIST: for (Element list : elements) {
// // if we are wrapped in an outer list, nothing to do - already done at top level
// for (Element parent : list.parents()) {
// if ("ol".equals(parent.tagName()) || "ul".equals(parent.tagName())) {
// break LIST;
// }
// }
// if (0 < list.select("* ol").size()) {
// // would love to use jsoup's Comment class, but it doesn't survive pandoc
// // ironically, this does...
// Element fakeComment = new Element(Tag.valueOf("div"), "");
// fakeComment.text("// TODO: This '"+list.tagName()+"' has nested 'ol' inside of it, needs manual editing");
// list.before(fakeComment);
// } else if ("ol".equals(list.tagName()) && 0 < list.select("* ul").size()) {
// // would love to use jsoup's Comment class, but it doesn't survive pandoc
// // ironically, this does...
// Element fakeComment = new Element(Tag.valueOf("div"), "");
// fakeComment.text("// TODO: This 'ol' has nested 'ul' inside of it, needs manual editing");
// list.before(fakeComment);
// }
// }



// table cells containing structural elements are problematic in PDFs...
elements = docOut.select("table:has(ol, ul, p ~ p, div, pre, table)");
TABLE: for (Element table : elements) {
// if we are wrapped in another table, nothing to do - already done at top level
for (Element parent : table.parents()) {
if ("table".equals(parent.tagName())) {
continue TABLE;
}
}
// would love to use jsoup's Comment class, but it doesn't survive pandoc
// ironically, this does...
Element fakeComment = new Element(Tag.valueOf("div"), "");
fakeComment.text("// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13");
table.before(fakeComment);
}

docOut.normalise();
}

Expand Down
2 changes: 2 additions & 0 deletions confluence-export/converted-asciidoc/about-this-guide.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ The material as presented assumes that you are familiar with some basic search c

Special notes are included throughout these pages.

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Note Type |Look & Description
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ The `CollapsingQParser` is really a _post filter_ that provides more performant

The CollapsingQParser accepts the following local parameters:

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Description |Default
Expand Down
10 changes: 10 additions & 0 deletions confluence-export/converted-asciidoc/collections-api.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ The base URL for all API calls below is `http://<hostname>:<port>/solr`.

*Query Parameters*

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="20%,20%,20%,20%,20%",options="header",]
|===
|Key |Type |Required |Default |Description
Expand Down Expand Up @@ -100,6 +102,8 @@ It's possible to edit multiple attributes at a time. Changing these values only

*Query Parameters*

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="25%,25%,25%,25%",options="header",]
|===
|Key |Type |Required |Description
Expand Down Expand Up @@ -611,6 +615,8 @@ Add a replica to a shard in a collection. The node name can be specified if the

*Query Parameters*

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="25%,25%,25%,25%",options="header",]
|===
|Key |Type |Required |Description
Expand Down Expand Up @@ -1373,6 +1379,8 @@ Assign an arbitrary property to a particular replica and give it the value speci

*Query Parameters*

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="25%,25%,25%,25%",options="header",]
|===
|Key |Type |Required |Description
Expand Down Expand Up @@ -1452,6 +1460,8 @@ Deletes an arbitrary property from a particular replica.

*Query Parameters*

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="25%,25%,25%,25%",options="header",]
|===
|Key |Type |Required |Description
Expand Down
2 changes: 2 additions & 0 deletions confluence-export/converted-asciidoc/de-duplication.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ The `SignatureUpdateProcessorFactory` has to be registered in `solrconfig.xml` a

The `SignatureUpdateProcessorFactory` takes several properties:

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Default |Description
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,8 @@ To configure the standard handler, provide a configuration like this in the solr

The parameters that can be specified are as follows:

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Default |Explanation
Expand Down
2 changes: 2 additions & 0 deletions confluence-export/converted-asciidoc/format-of-solr-xml.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ As you can see, the discovery Solr configuration is "SolrCloud friendly". Howeve

There are no attributes that you can specify in the `<solr>` tag, which is the root element of `solr.xml`. The tables below list the child nodes of each XML element in `solr.xml`.

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Node |Description
Expand Down
2 changes: 2 additions & 0 deletions confluence-export/converted-asciidoc/function-queries.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ Only functions with fast random access are recommended.

The table below summarizes the functions available for function queries.

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Function |Description |Syntax Examples
Expand Down
2 changes: 2 additions & 0 deletions confluence-export/converted-asciidoc/index-replication.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,8 @@ If documents are added to the slave, then the slave is no longer in sync with it

You can use the HTTP commands below to control the ReplicationHandler's operations.

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Command |Description
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ This sets the default search field ("df") to be "_text_" for all of the request

The syntax and semantics are similar to that of a `<requestHandler>` . The following are the attributes

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|property |Description
Expand Down
2 changes: 2 additions & 0 deletions confluence-export/converted-asciidoc/other-parsers.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -623,6 +623,8 @@ The Simple query parser in Solr is based on Lucene's SimpleQueryParser. This que

This parser takes the following parameters:

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Parameter |Description
Expand Down
2 changes: 2 additions & 0 deletions confluence-export/converted-asciidoc/result-grouping.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ If you ask Solr to group these documents by "product_range", then the total amou

Result Grouping takes the following request parameters. Any number of these request parameters can be included in a single request:

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Type |Description
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,8 @@ Permissions need to be created if they are not on the list of pre-defined permis

Several properties can be used to define your custom permission.

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Property |Description
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,8 @@ The `HdfsDirectoryFactory` has a number of settings that are defined as part of
[[RunningSolronHDFS-BlockCacheSettings]]
=== Block Cache Settings

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Default |Description
Expand Down Expand Up @@ -137,6 +139,8 @@ solr.hdfs.confdir pass the location of HDFS client configuration files - needed

Hadoop can be configured to use the Kerberos protocol to verify user identity when trying to access core services like HDFS. If your HDFS directories are protected using Kerberos, then you need to configure Solr's HdfsDirectoryFactory to authenticate using Kerberos in order to read and write to HDFS. To enable Kerberos authentication from Solr, you need to set the following parameters:

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Default |Description
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ When using the restart command, you must pass all of the parameters you initiall

The bin/solr script provides many options to allow you to customize the server in common ways, such as changing the listening port. However, most of the defaults are adequate for most Solr installations, especially when just getting started.

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Description |Example
Expand Down Expand Up @@ -310,6 +312,8 @@ The create command detects the mode that Solr is running in (standalone or SolrC
[[SolrStartScriptReference-AvailableParameters.3]]
==== Available Parameters

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Description |Example
Expand Down Expand Up @@ -373,6 +377,8 @@ If running in SolrCloud mode, the delete command checks if the configuration dir
[[SolrStartScriptReference-AvailableParameters.4]]
==== Available Parameters

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Description |Example
Expand Down Expand Up @@ -412,6 +418,8 @@ Use this Zookeeper sub-command to upload one of the pre-configured configuration
[[SolrStartScriptReference-AvailableParameters_allparametersarerequired_]]
==== Available Parameters (all parameters are required)

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Description |Example
Expand Down Expand Up @@ -453,6 +461,8 @@ Use this Zookeeper sub-command to download a configuration set from Zookeeper to
[[SolrStartScriptReference-AvailableParameters_allparametersarerequired_.1]]
==== Available Parameters (all parameters are required)

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Description |Example
Expand Down Expand Up @@ -485,6 +495,8 @@ Use this Zookeeper sub-command for transferring files and directories between Zo
[[SolrStartScriptReference-AvailableParameters.5]]
==== Available Parameters

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Description |Example
Expand Down Expand Up @@ -527,6 +539,8 @@ Use this ZooKeeper sub-command to remove a znode (and optionally all child nodes
[[SolrStartScriptReference-AvailableParameters.6]]
==== Available Parameters

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Description |Example
Expand Down
4 changes: 4 additions & 0 deletions confluence-export/converted-asciidoc/spatial-search.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ See the section <<SpatialSearch-SpatialRecursivePrefixTreeFieldType_abbreviateda

There are 2 types of Spatial filters, which both support the following parameters:

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Parameter |Description
Expand Down Expand Up @@ -164,6 +166,8 @@ RPT incorporates the basic features of LatLonType and PointType, such as lat-lon

To use RPT, the field type must be registered and configured in `schema.xml`. There are many options for this field type.

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Setting |Description
Expand Down
2 changes: 2 additions & 0 deletions confluence-export/converted-asciidoc/suggester.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ The first step is to add a search component to `solrconfig.xml` and tell it to u

The Suggester search component takes several configuration parameters. The choice of the lookup implementation (`lookupImpl`, how terms are found in the suggestion dictionary) and the dictionary implementation (`dictionaryImpl`, how terms are stored in the suggestion dictionary) will dictate some of the parameters required. Below are the main parameters that can be used no matter what lookup or dictionary implementation is used. In the following sections additional parameters are provided for each implementation.

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Parameter |Description
Expand Down
4 changes: 4 additions & 0 deletions confluence-export/converted-asciidoc/the-stats-component.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ bin/solr -e techproducts

The Stats Component accepts the following parameters:

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Parameter |Description
Expand Down Expand Up @@ -90,6 +92,8 @@ The query below demonstrates computing stats against two different fields numeri

The table below explains the statistics supported by the Stats component. Not all statistics are supported for all field types, and not all statistics are computed by default (See <<TheStatsComponent-LocalParameters,Local Parameters>> below for details)

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="20%,20%,20%,20%,20%",options="header",]
|===
|Local Param |Sample Input |Description a|
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,8 @@ The example below shows the available request parameters for this component:

`http://localhost:8983/solr/techproducts/tvrh?q=includes:[* TO *]&rows=10&indent=true&tv=true&tv.tf=true&tv.df=true&tv.positions=true&tv.offsets=true&tv.payloads=true&tv.fl=includes`

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Boolean Parameters |Description |Type
Expand Down
2 changes: 2 additions & 0 deletions confluence-export/converted-asciidoc/the-terms-component.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ You could add this component to another handler if you wanted to, and pass "term

The parameters below allow you to control what terms are returned. You can also any of these to the request handler if you'd like to set them permanently. Or, you can add them to the query request. These parameters are:

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="25%,25%,25%,25%",options="header",]
|===
|Parameter |Required |Default |Description
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ Solr supports several modifiers that atomically update values of a document. Thi

To use atomic updates, add a modifier to the field that needs to be updated. The content can be updated, added to, or incrementally increased if a number.

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Modifier |Usage
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,8 @@ Then, these parameters can be passed to the full-import command or defined in th

DIH commands are sent to Solr via an HTTP request. The following operations are supported.

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Command |Description
Expand Down Expand Up @@ -433,6 +435,8 @@ Here is an example from the "```mail```" collection of the `dih` example (`examp

The entity attributes unique to the MailEntityProcessor are shown below.

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Attribute |Use
Expand Down Expand Up @@ -491,6 +495,8 @@ Here is an example from the "```tika```" collection of the `dih` example (`examp

The parameters for this processor are described in the table below:

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="50%,50%",options="header",]
|===
|Attribute |Use
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ The above example shows the optional initialization and custom tool parameters u
[[VelocityResponseWriter-VelocityResponseWriterrequestparameters]]
=== VelocityResponseWriter request parameters

// TODO: This table has cells that won't work with PDF: https://github.com/ctargett/refguide-asciidoc-poc/issues/13

[width="100%",cols="34%,33%,33%",options="header",]
|===
|Parameter |Description |Default value
Expand Down

0 comments on commit c6f6d57

Please sign in to comment.