public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
* Reference.docx and default Word styles
@ 2015-02-23 22:14 Nikolay Yakimov
       [not found] ` <10d80cbd-5bdb-4937-811c-24af52aaadf3-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Nikolay Yakimov @ 2015-02-23 22:14 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw


[-- Attachment #1.1: Type: text/plain, Size: 2297 bytes --]



Hi. I'm working on https://github.com/jgm/pandoc/pull/1968, and I've got 
some questions.

Some styles in reference.docx are marked as custom, some are not. Some of 
those not marked custom are recognized by Word as built-in. Some are not, 
however. Word automatically marks those as custom, but this introduces 
unnecessary ambiguity. Furthermore, some styles not recognized by Word as 
built-in actually duplicate built-in styles, and could be renamed to 
reflect that.

Here is a list of styles I'm most concerned about:
Nameambiguoustypecan be replaced byAuthoryesp?Abstractyesp?Compactyesp?Image 
Captionyespcaption?Block QuoteyespIntense Quote, Block Text, QuoteTable 
Captionyespcaption?Definition Termyesp?Definitionyesp?FirstParagraphyesp?
LinknocHyperlinkFootnote Refnocfootnote reference

these are either ambiguous (again, meaning that they are neither custom, 
nor Word defaults), duplicate default Word styles, or both.

So the question is, what should be done with them? I've got the following 
options:

   1. Update reference.docx to define ambiguous styles as custom. Do 
   nothing more. This is a quick-and-dirty solution.
   2. Replace styles in reference with word-recognized ones as best I can, 
   set those I can't as custom. This is a longer path, but leading to 
   hopefully better user experience.
   3. Do nothing at all, and hope for the best. This will likely lead to 
   'surprises' in the future, and not the pleasant kind, I fear.

First two options require significant updates to reference.docx though, and 
option 2 is not strictly backwards-compatible with pandoc-created docx 
(although it'll likely be a couple of styles, not much more).


So, what are your thoughts on this matter?

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/10d80cbd-5bdb-4937-811c-24af52aaadf3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[-- Attachment #1.2: Type: text/html, Size: 14240 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Reference.docx and default Word styles
       [not found] ` <10d80cbd-5bdb-4937-811c-24af52aaadf3-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2015-02-24 10:36   ` Matthew Pickering
       [not found]     ` <d71ce0fa-d002-474a-8e6e-b97500b27352-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  2015-02-24 17:56   ` Nikolay Yakimov
  1 sibling, 1 reply; 7+ messages in thread
From: Matthew Pickering @ 2015-02-24 10:36 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw


[-- Attachment #1.1: Type: text/plain, Size: 2981 bytes --]

Ok -- to clarify you are talking about modifying the docx writer to produce 
an output which word better understands? I don't think that there will be 
many who object to these changes as the reference.docx has been the issue 
of quite a few bug reports. It would be even better if that with these 
changes, it is possible for a user to use any file with these default 
styles defined for reasonable results. Which if I'm understanding correctly 
would be an unintended but nice consequence. 

So for the record, I think 2 is the best solution.

On Monday, February 23, 2015 at 10:14:27 PM UTC, Nikolay Yakimov wrote:
>
> Hi. I'm working on https://github.com/jgm/pandoc/pull/1968, and I've got 
> some questions.
>
> Some styles in reference.docx are marked as custom, some are not. Some of 
> those not marked custom are recognized by Word as built-in. Some are not, 
> however. Word automatically marks those as custom, but this introduces 
> unnecessary ambiguity. Furthermore, some styles not recognized by Word as 
> built-in actually duplicate built-in styles, and could be renamed to 
> reflect that.
>
> Here is a list of styles I'm most concerned about:
> Nameambiguoustypecan be replaced byAuthoryesp?Abstractyesp?Compactyesp?Image 
> Captionyespcaption?Block QuoteyespIntense Quote, Block Text, QuoteTable 
> Captionyespcaption?Definition Termyesp?Definitionyesp?FirstParagraphyesp?
> LinknocHyperlinkFootnote Refnocfootnote reference
>
> these are either ambiguous (again, meaning that they are neither custom, 
> nor Word defaults), duplicate default Word styles, or both.
>
> So the question is, what should be done with them? I've got the following 
> options:
>
>    1. Update reference.docx to define ambiguous styles as custom. Do 
>    nothing more. This is a quick-and-dirty solution.
>    2. Replace styles in reference with word-recognized ones as best I 
>    can, set those I can't as custom. This is a longer path, but leading to 
>    hopefully better user experience.
>    3. Do nothing at all, and hope for the best. This will likely lead to 
>    'surprises' in the future, and not the pleasant kind, I fear.
>
> First two options require significant updates to reference.docx though, 
> and option 2 is not strictly backwards-compatible with pandoc-created docx 
> (although it'll likely be a couple of styles, not much more).
>
>
> So, what are your thoughts on this matter?
>

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/d71ce0fa-d002-474a-8e6e-b97500b27352%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[-- Attachment #1.2: Type: text/html, Size: 13179 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Reference.docx and default Word styles
       [not found]     ` <d71ce0fa-d002-474a-8e6e-b97500b27352-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2015-02-24 17:26       ` John MacFarlane
  0 siblings, 0 replies; 7+ messages in thread
From: John MacFarlane @ 2015-02-24 17:26 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

As you point out, #2 may break some existing reference.docx setups.
(That is, people may have a reference.docx that modifies the styles
pandoc currently uses; if pandoc changes these, a new custom
reference.docx would be needed.) Still, I think this isn't sufficient
reason to avoid #2.

One further reservation.  See commit
https://github.com/jgm/pandoc/commit/3fca434737f0eee706c02fba6a2a2629338a1065
which explains (sort of) why we use FootnoteRef instead of
FootnoteReference and Hyperlink instead of Link.

See also
https://github.com/jgm/pandoc/commit/caed0df4a7ed5b2ec0cc2b15cc99e359987982e4
for further amplification.

I can't recall all the details here, just that when I used the Word
style names, Word would sometimes mess things up when the reference.docx
was saved.

I agree that it would be best to use the standard Word styles if
possible, but I wanted to call your attention to this problem I
had earlier.

John

+++ Matthew Pickering [Feb 24 15 02:36 ]:
>Ok -- to clarify you are talking about modifying the docx writer to produce
>an output which word better understands? I don't think that there will be
>many who object to these changes as the reference.docx has been the issue
>of quite a few bug reports. It would be even better if that with these
>changes, it is possible for a user to use any file with these default
>styles defined for reasonable results. Which if I'm understanding correctly
>would be an unintended but nice consequence.
>
>So for the record, I think 2 is the best solution.
>
>On Monday, February 23, 2015 at 10:14:27 PM UTC, Nikolay Yakimov wrote:
>>
>> Hi. I'm working on https://github.com/jgm/pandoc/pull/1968, and I've got
>> some questions.
>>
>> Some styles in reference.docx are marked as custom, some are not. Some of
>> those not marked custom are recognized by Word as built-in. Some are not,
>> however. Word automatically marks those as custom, but this introduces
>> unnecessary ambiguity. Furthermore, some styles not recognized by Word as
>> built-in actually duplicate built-in styles, and could be renamed to
>> reflect that.
>>
>> Here is a list of styles I'm most concerned about:
>> Nameambiguoustypecan be replaced byAuthoryesp?Abstractyesp?Compactyesp?Image
>> Captionyespcaption?Block QuoteyespIntense Quote, Block Text, QuoteTable
>> Captionyespcaption?Definition Termyesp?Definitionyesp?FirstParagraphyesp?
>> LinknocHyperlinkFootnote Refnocfootnote reference
>>
>> these are either ambiguous (again, meaning that they are neither custom,
>> nor Word defaults), duplicate default Word styles, or both.
>>
>> So the question is, what should be done with them? I've got the following
>> options:
>>
>>    1. Update reference.docx to define ambiguous styles as custom. Do
>>    nothing more. This is a quick-and-dirty solution.
>>    2. Replace styles in reference with word-recognized ones as best I
>>    can, set those I can't as custom. This is a longer path, but leading to
>>    hopefully better user experience.
>>    3. Do nothing at all, and hope for the best. This will likely lead to
>>    'surprises' in the future, and not the pleasant kind, I fear.
>>
>> First two options require significant updates to reference.docx though,
>> and option 2 is not strictly backwards-compatible with pandoc-created docx
>> (although it'll likely be a couple of styles, not much more).
>>
>>
>> So, what are your thoughts on this matter?
>>
>
>-- 
>You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
>To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
>To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
>To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/d71ce0fa-d002-474a-8e6e-b97500b27352%40googlegroups.com.
>For more options, visit https://groups.google.com/d/optout.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Reference.docx and default Word styles
       [not found] ` <10d80cbd-5bdb-4937-811c-24af52aaadf3-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  2015-02-24 10:36   ` Matthew Pickering
@ 2015-02-24 17:56   ` Nikolay Yakimov
       [not found]     ` <62149c61-fcbb-465d-b1ca-6d0b881c9072-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  1 sibling, 1 reply; 7+ messages in thread
From: Nikolay Yakimov @ 2015-02-24 17:56 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw


[-- Attachment #1.1: Type: text/plain, Size: 1550 bytes --]

Thank you for your input, Matthew, John

I think this kind of concludes this discussion, since both of you are in 
favor of #2, and I was leaning to it as well.

As for FootnoteRef and Link, I'll be sure to test for regressions to the 
best of my ability. Not sure if I'll be able to fix underlying issue, but 
I'll have to try to know for sure.

One point I'm still not sure about is captions. On one hand, ImageCaption 
and TableCaption have semantic value, since they store more information 
than just Caption style. On the other hand, there *is* a style for captions 
already.

I'm thinking about having Caption in reference.docx and generating 
ImageCaption and TableCaption in the same manner as, e.g. SourceCode, 
basing them on Caption. This will have an added benefit of simplifying 
getting captions in docx reader (something I was planning to tackle in near 
future), since all captions, including Word-created ones, will be based on 
the same style. Any objections?

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/62149c61-fcbb-465d-b1ca-6d0b881c9072%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[-- Attachment #1.2: Type: text/html, Size: 2062 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Reference.docx and default Word styles
       [not found]     ` <62149c61-fcbb-465d-b1ca-6d0b881c9072-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2015-02-24 18:11       ` John MacFarlane
       [not found]         ` <20150224181115.GA439-nFAEphtLEs/fysO+viCLMa55KtNWUUjk@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: John MacFarlane @ 2015-02-24 18:11 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

Personally, I don't see a problem with just using the Caption
style for both kinds of captions (table and image).  Is
there a strong reason to use different styles?


+++ Nikolay Yakimov [Feb 24 15 09:56 ]:
>   Thank you for your input, Matthew, John
>   I think this kind of concludes this discussion, since both of you are
>   in favor of #2, and I was leaning to it as well.
>   As for FootnoteRef and Link, I'll be sure to test for regressions to
>   the best of my ability. Not sure if I'll be able to fix underlying
>   issue, but I'll have to try to know for sure.
>   One point I'm still not sure about is captions. On one hand,
>   ImageCaption and TableCaption have semantic value, since they store
>   more information than just Caption style. On the other hand, there *is*
>   a style for captions already.
>   I'm thinking about having Caption in reference.docx and generating
>   ImageCaption and TableCaption in the same manner as, e.g. SourceCode,
>   basing them on Caption. This will have an added benefit of simplifying
>   getting captions in docx reader (something I was planning to tackle in
>   near future), since all captions, including Word-created ones, will be
>   based on the same style. Any objections?
>
>   --
>   You received this message because you are subscribed to the Google
>   Groups "pandoc-discuss" group.
>   To unsubscribe from this group and stop receiving emails from it, send
>   an email to [1]pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
>   To post to this group, send email to
>   [2]pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
>   To view this discussion on the web visit
>   [3]https://groups.google.com/d/msgid/pandoc-discuss/62149c61-fcbb-465d-
>   b1ca-6d0b881c9072%40googlegroups.com.
>   For more options, visit [4]https://groups.google.com/d/optout.
>
>References
>
>   1. mailto:pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
>   2. mailto:pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
>   3. https://groups.google.com/d/msgid/pandoc-discuss/62149c61-fcbb-465d-b1ca-6d0b881c9072-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org?utm_medium=email&utm_source=footer
>   4. https://groups.google.com/d/optout


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Reference.docx and default Word styles
       [not found]         ` <20150224181115.GA439-nFAEphtLEs/fysO+viCLMa55KtNWUUjk@public.gmane.org>
@ 2015-02-24 18:16           ` Nikolay Yakimov
       [not found]             ` <30cd30a9-014a-426a-b0f8-5be416ba4c58-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Nikolay Yakimov @ 2015-02-24 18:16 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw


[-- Attachment #1.1: Type: text/plain, Size: 1092 bytes --]

No, not really. I just assumed that giving users an ability to easily 
specify different styles for table and image captions is a good thing, not 
that I see immediate use for it, but you never know. More customization 
possibilities with little to no drawbacks (except for a little more code) 
is generally preferable IMO.

John MacFarlane:
>
> Personally, I don't see a problem with just using the Caption 
> style for both kinds of captions (table and image).  Is 
> there a strong reason to use different styles? 
>

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/30cd30a9-014a-426a-b0f8-5be416ba4c58%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[-- Attachment #1.2: Type: text/html, Size: 1642 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Reference.docx and default Word styles
       [not found]             ` <30cd30a9-014a-426a-b0f8-5be416ba4c58-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2015-02-24 20:57               ` Denis Navas
  0 siblings, 0 replies; 7+ messages in thread
From: Denis Navas @ 2015-02-24 20:57 UTC (permalink / raw)
  To: public-pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw-wOFGN7rlS/M9smdsby/KFg




Just a comment,

Word fixes by default, spaces before paragraphs.  I am not sure what
version does that, but I adopted the policy of control the spacing
between text and tables or graphs.

I prefer to use the space after the paragraph.  That way seems more 
logical to me. But this introduces the following problem: With tables I 
must give a space before the caption, because I place it above the table 
and with figures, I must give an space after, because the caption
is placed at the figure's bottom.

Tables can control its spacing too, and I prefer that does not apply
space after the table, to use a paragraph that I name pagraph_note.

An apparent solution is to use space before and after the paragraph,
but this add space between captions, tables, figures and paragraphs.

I know that this is a matter of taste and visual appearance.

Just share my opinion to save some effort.



El 2015-02-24 a las 12:16, Nikolay Yakimov escribió:
> No, not really. I just assumed that giving users an ability to easily
> specify different styles for table and image captions is a good thing,
> not that I see immediate use for it, but you never know. More
> customization possibilities with little to no drawbacks (except for a
> little more code) is generally preferable IMO.
>
> John MacFarlane:
>
>     Personally, I don't see a problem with just using the Caption
>     style for both kinds of captions (table and image).  Is
>     there a strong reason to use different styles?



-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/54ECE5D4.7060302%40gmail.com.
For more options, visit https://groups.google.com/d/optout.


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2015-02-24 20:57 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-23 22:14 Reference.docx and default Word styles Nikolay Yakimov
     [not found] ` <10d80cbd-5bdb-4937-811c-24af52aaadf3-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2015-02-24 10:36   ` Matthew Pickering
     [not found]     ` <d71ce0fa-d002-474a-8e6e-b97500b27352-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2015-02-24 17:26       ` John MacFarlane
2015-02-24 17:56   ` Nikolay Yakimov
     [not found]     ` <62149c61-fcbb-465d-b1ca-6d0b881c9072-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2015-02-24 18:11       ` John MacFarlane
     [not found]         ` <20150224181115.GA439-nFAEphtLEs/fysO+viCLMa55KtNWUUjk@public.gmane.org>
2015-02-24 18:16           ` Nikolay Yakimov
     [not found]             ` <30cd30a9-014a-426a-b0f8-5be416ba4c58-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2015-02-24 20:57               ` Denis Navas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).