Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > Non-English Discussions > Forum Français > Assistance

Notices

Reply
 
Thread Tools Search this Thread
Old 04-10-2015, 11:41 AM   #1
manon123
Enthusiast
manon123 began at the beginning.
 
manon123's Avatar
 
Posts: 29
Karma: 10
Join Date: Nov 2014
Location: Belgium
Device: Kobo glo
Souligner dans un epub.

Bonjour,

Je fais des epubs à partir de documents odt et fais la conversion avec writer2xhtml.

Dans les premières pages, j'ai le nom de l'auteur, 5cm plus bas un soulignement (2 cm), puis 2 cm plus bas le titre du livre.

Comment puis-je effectuer un soulignement en epub, en indiquant une class à un paragraphe et mettre un hr dans la css ? Si oui, comment définir cet attribut et le hr dans la css ?

Merci de vos réponses.
manon123 is offline   Reply With Quote
Old 04-10-2015, 12:33 PM   #2
Arios
A curiosus lector!
Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.
 
Arios's Avatar
 
Posts: 463
Karma: 2015140
Join Date: Jun 2012
Device: Sony PRS-T1, Kobo Touch
Salut Manon123,

Tu pourrais effectuer ce formatage dès le départ avec LibreOffice.

Pour éditer ton epub, tu peux utiliser Sigil ou encore l'ebook-edit qui vient avec Calibre.

Dans ton fichier (x)html, tu mets au bon endroit, pour la ligne horizontale:

Code:
 <hr />
et dans la css, par exemple:

Code:
hr {
    margin-right: 30%;
    margin-left: 30%;
    margin-bottom: .8em;
    margin-top: 1.4em;
}
De la sorte, la ligne de séparation (hr) sera centrée. Si tu veux que la <hr> soit alignée à gauche, mets margin-left: 0;, etc.

Pour le soulignement, par exemple:
Code:
Il était une fois, dans un <span class="soul">village</span> fort lointain....
Dans la css:

Code:
span.soul {
text-decoration: underline;
}
Tu peux toujours utiliser <u>mot à souligner</u>, mais pour des raisons sémantiques, l'utilisation de cet élément est déconseillé. (jettes un coup d'oeil ici: http://www.w3schools.com/tags/tag_u.asp) pour <u> et le reste.
En passant <span> est un attribut inline; il est appliqué à une portion de texte à l'intérieur d'un élément block (un paragraphe ou une <div>).

Finalement, n'oublie pas d'associer ton/tes fichiers (x)html avec la feuille de style, sinon cela ne marchera pas!
Arios is offline   Reply With Quote
Advert
Old 04-10-2015, 12:52 PM   #3
manon123
Enthusiast
manon123 began at the beginning.
 
manon123's Avatar
 
Posts: 29
Karma: 10
Join Date: Nov 2014
Location: Belgium
Device: Kobo glo
Merci beaucoup, c'est tout ce que je voulais savoir. ;-)
manon123 is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
image en arrière plan dans epub depuis odt virg Assistance 1 05-03-2013 11:46 AM
image dans Calibre morapat Software 0 08-15-2011 04:34 AM
avoir un # dans le clavier jaimesbonde007 PocketBook 2 03-13-2011 07:49 PM
Et Wikipedia dans tout ça ? fred Cybook 7 10-04-2009 07:33 AM
Récuperer un epub dans l'iphone Michel.L Autres liseuses 11 09-07-2009 03:57 AM


All times are GMT -4. The time now is 06:29 AM.


MobileRead.com is a privately owned, operated and funded community.