-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How should an index be visually displayed? #35
Comments
My concept was that index entries form a kind of anchor that is visible Renderers do not have to provide an index, but if they choose to do so It is acceptable for a renderer to represent that precise reference BTW, MarkDown does permit the specification of anchors at any arbitrary point in the text,
...could be rendered to Markdown like so: Here is one paragraph about <A id="X123">interesting</A> writing. ...and then the index entry like so: ### Index
Gloss: [123](#X123) (where the As for how I envisioned index entries being rendered, here is a suggested format
I would expect something like one of the following... For a plaintext renderer (rendering links as line numbers, where the
|
@thoughtstream Much clearer now Line numbers ??
EPub has no native page numbers Apparently Kindle has some form of 'location number', but information about Kindle formats seems proprietary. Options that I can see:
I found "Theory says: |
Sorry if I'm interrupting the conversation. Page numbers are used only in printed books ( or PDF) and don't make sense for web content. For web content, URLs are used. I would suggest using document titles (or their abbreviated forms), file names, or URLs (or their shortened versions), or something that characterizes the resource along with the term. PS: In EPUB format, page numbering is handled by the Reader and depends on user preferences (such as page size and font |
@zag Not an interruption! Just a confirmation :) PDF has the same problem really. Except that PDF tends to be used for content that originally has a hard-copy. So PDF includes markers that correspond to the hard-copy. PDFs of the same book by different publishers will have different page numbers, even if the content is otherwise the same. It is a subtle problem for ebooks as well. How, for example, does a scholar reference a paragraph in an ebook when there are no line or page numbers? I looked at various sites that measure words/lines/pages of content. These are needed because many assignments are stated as 'write 3000 words about ...' or 'write a 2 page article on ...'. Authors now work exclusively on computers. So the people giving assignments use the algorithms provided by (eg) MS Word. Essentially, these breakdown to a calculation based on notional values of words/line word/page. |
You can use the paragraph number (or block number) on that page. |
Oh, I missed an important detail: |
@zag block level tagging is essentially what I meant by the place mechanism mentioned above. |
The problem is quite old, and for pre-printing press books, such as the Bible, different copiers would order text differently on pages. So citations were made by Chapter & verse. So, perhaps Section Name, para No, or |
Additionally, I'd like to keep count of paragraphs in a block scope so that I could easily implement a |
No. I meant line number in the output plaintext.
I would not use line numbers in that case. I simply meant that, for a plaintext output format,
Both EPub and PDF support internal links within a document, so I don't think page numbers I'd prefer the specification not to mandate any particular representation of the index, Personally, I think if the output format supports active internal links But we need to avoid locking the authors of renderers into |
[Oops, something went very wrong with that last comment, which was cut off and published prematurely. Sorry. |
Hmmmmm. Do we need to open a separate issue about this? Looking at the available standard block types, it seems that
It seems reasonable that every block that produces a visible rendering On the other hand, I don't think that we can specify that absolutely any block |
@thoughtstream Yes we probably need another issue for num. I'm opening one. |
closing this as resolved. Conversation about numbered blocks continued in #36 |
@thoughtstream there are several
X<DISPLAY | index options>
markup options, including hierarchical ones.Pod::To::HTML
never created an HTML representation of the index. I wondered what your original intent was.It is clear that in the text, only DISPLAY is rendered, so the question is about the index itself.
In particular, I was wondering about multiple hierarchies, eg
X<D|Main,2nd-elem,3rd-elem>
In addition, not all outputs (eg text and MarkDown) support links to arbitrary places in text (MarkDown only supports links to headers AFAIK). Consequently, I also include pass to the index generator a value place, which is the most recent heading. When a target is possible, then the term in place would contain a target at the position of the indexed item, not to the heading.
Here are some examples (DISPLAY is shortened to D as its not at issue here),
===>
means a line in the IndexX<D|Simple>
===> Simple : placeX<D|Simple;Complicated>
===> Complicated: placeX<D|Simple;Complicated,hierarchy>
===> ComplicatedThe above are assumed to be unique lines in a text. Repeated instances would be concatenated:
Would yield (I think)
But what about repeated 1st elem with multiple 2nd elem? eg
The text was updated successfully, but these errors were encountered: