Last modified: 2005-08-31 19:41:10 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T3842, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 1842 - New syntax <verse> for texts in verse
New syntax <verse> for texts in verse
Status: RESOLVED FIXED
Product: Wikimedia
Classification: Unclassified
General/Unknown (Other open bugs)
unspecified
Other Linux
: Normal enhancement with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-04-07 09:46 UTC by Yann Forget
Modified: 2005-08-31 19:41 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Yann Forget 2005-04-07 09:46:32 UTC
Hi, 
 
There is no specific syntax for formatting a text in verse. 
People from Wikisource have expressed the wish to have a <verse> syntax which would produce 
something like  
 
<pre style="background: #ffffff; border: 0px; padding-left: 2em; margin: 0em;"> 
 
</pre> 
 
Thanks, 
Yann
Comment 1 Yann Forget 2005-04-07 11:34:12 UTC
Actually, it should be: 
 
<pre style="background: #ffffff; border: 0px; line-height: 150%; padding-left: 2em; margin: 0em;"> 
 
Comment 2 Alexander Sigachov 2005-04-10 11:31:09 UTC
It is language and style dependent
Comment 3 Yann Forget 2005-04-10 16:09:45 UTC
(In reply to comment #2) 
> It is language and style dependent 
 
This syntax would be useful for all languages with the Latin alphabet and all Indian languages, at least. 
Not everybody is obliged to use it. 
 
Comment 4 Ævar Arnfjörð Bjarmason 2005-04-10 19:54:18 UTC
Is there any specific reason why the "people on wikisource" can't just add the
following to MediaWiki:Monobook.css:

.verse {
  background-color: #ffffff;
  border-width 0;
  padding-left: 2em;
  margin: 0;
}

And use this with:

<pre class="verse">
 verse text here
</pre>
Comment 5 Yann Forget 2005-04-11 11:20:03 UTC
Hi, 
 
Actuellement, I was told that this feature should NOT be based on <pre> because <pre> doesn't allow other wiki 
syntax inside the tag. So it should be a new tag with just take into account the carriage return. 
 
Example: 
 
<verse> 
test 1 
test 2 
test 3 
</verse> 
 
should produce 
 
test 1 
test 2 
test 3 
 
instead of 
 
test 1test 2test 3 
 
Comment 6 Brion Vibber 2005-04-14 05:23:24 UTC
This is just the sort of thing global style sheets are good for. Note that a <div> should work fine here:

.verse {
  background-color: #ffffff;
  border-width 0;
  padding-left: 2em;
  margin: 0;
  white-space: pre;
}

<div class="verse">
verse is fun
verse is art
making it rhyme
is the best part
</div>
Comment 7 Christian Neubauer 2005-04-30 16:12:40 UTC
There is apparently no solution to this with plain CSS.  What we really need is
the ability to turn off the ignoring of single line breaks.  The only other
alternatives that I can think of are to use a pre block which causes other
formatting problems discussed in the comments or to use a br on the end of every
line which is just ridiculous.  A div would NOT work fine because the goal is to
make mediawiki obey single line breaks... This is most likely not possible with CSS.
Comment 8 Christian Neubauer 2005-04-30 16:15:00 UTC
Oh sorry.  I have never heard of whitespace: pre.  I guess that was what we needed.
Comment 9 Yann Forget 2005-06-21 09:22:38 UTC
(In reply to comment #6)  
> This is just the sort of thing global style sheets are good for. Note that a <div> should work fine here:  
>   
> .verse {  
>   background-color: #ffffff;  
>   border-width 0;  
>   padding-left: 2em;  
>   margin: 0;  
>   white-space: pre;  
> }  
>   
> <div class="verse">  
> verse is fun  
> verse is art  
> making it rhyme  
> is the best part  
> </div>  
   
A <div> DOES NOT do what is needed. That is the problem. This would work if a <pre class="verse"> could be 
used, but it doesn't work. 
 
Comment 10 Yann Forget 2005-06-21 09:44:58 UTC
There was 2 problems: 
 
1. The cache doesn't clear. 
2. It should be style="border: 0px; 
 
Comment 11 Christian Tanguy 2005-06-22 20:03:18 UTC
(In reply to comment #5)
It seems to me that pre DOES allow other wiki syntax
but that p style="white-space: pre;" removes the CR in wikimedia

(In reply to comment #10)
So what we must do is just add "font-family:sans-serif;" to the verse class.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links