|
|
#1 |
|
Member
![]() Posts: 10
Karma: 10
Join Date: Jan 2011
Device: none
|
How do I centralize the box?
|
|
|
|
|
|
#2 | |
|
Staff to 4 Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,705
Karma: 2485850
Join Date: Aug 2009
Location: The (original) Silicon Valley, USA
Device: Galaxy Tab 2,Black Astak PEz, K4NT(now Wifes)
|
Quote:
to fake centering , care needs to be taken that the box will always fit the display width (ADE has issues with auto margins, so be forewarned)
__________________
Using: Ubuntu(32 bit):Oneric,Precise and XPpro SP3, W7HP(64)- - Libre Office w/Writer2EPUB
|
|
|
|
|
|
Enthusiast
|
|
|
|
#3 |
|
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,102
Karma: 927511
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-300, PRS-T1
|
You might try a table. It is not nice, but it will probably work.
__________________
Creator and maintainer of the e-Book Tools Word add-in. Creator and maintainer of the Clean HTML macro for MS Word. |
|
|
|
|
|
#4 |
|
Zealot
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 121
Karma: 5070
Join Date: Dec 2010
Device: none
|
May i ask what this have to do with Sigil? Thats HTML or ePub where we have a special forum for.
|
|
|
|
|
|
#5 |
|
Staff to 4 Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,705
Karma: 2485850
Join Date: Aug 2009
Location: The (original) Silicon Valley, USA
Device: Galaxy Tab 2,Black Astak PEz, K4NT(now Wifes)
|
You are probably correct. If the question was 'How can I make Sigil do this (without resorting to CV ), it would be a Sigil question.
__________________
Using: Ubuntu(32 bit):Oneric,Precise and XPpro SP3, W7HP(64)- - Libre Office w/Writer2EPUB
|
|
|
|
|
|
#6 | |
|
Det
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 716
Karma: 450180
Join Date: Jan 2012
Location: Zischebattem
Device: Acer Lumiread
|
Quote:
IMO it's not possible to find a solution with paragraph or table formatting which is perfect everywhere. Table-fomatting: Code:
table { margin: 1em auto }
td { border: 1px solid black; text-align: center; width: 200px }
With paragraph-formatting it will be a bit difficult to keep the box at the same size, if the screen size changes. So i got a third suggestion: make a image. |
|
|
|
|
|
|
#7 |
|
Fanatic
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 552
Karma: 23783
Join Date: Sep 2010
Location: Kent, England, Sol 3, ZZ9 plural Z Alpha
Device: Sony PRS-300
|
If the box can be defined width as a % of display width, then the left margin coluld be 100%-BoxWidth% divided by 2, so if BoxWidth=70% then left margin would be 15%
|
|
|
|
|
|
#8 | |
|
eBook FANatic
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,858
Karma: 13081948
Join Date: Apr 2008
Location: Alabama, USA
Device: HP ipac RX5915 Wife's Kindle
|
Quote:
Code:
.centerbox{
width:50%;
padding:10px;
border:3px solid black;
margin-left:auto;
margin-right:auto;
margin-bottom:1em;
}
You can adjust as needed.
__________________
Charlie 'Bene legere saecla vincere'. 'To read well is to master the ages' [Prof. Issac Flagg] Last edited by crutledge; 03-13-2012 at 03:30 PM. Reason: Sorry about the double post. |
|
|
|
|
|
|
#9 | |
|
Staff to 4 Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,705
Karma: 2485850
Join Date: Aug 2009
Location: The (original) Silicon Valley, USA
Device: Galaxy Tab 2,Black Astak PEz, K4NT(now Wifes)
|
Quote:
Use the formula above
__________________
Using: Ubuntu(32 bit):Oneric,Precise and XPpro SP3, W7HP(64)- - Libre Office w/Writer2EPUB
|
|
|
|
|
|
|
#10 |
|
eBook Enthusiast
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 54,660
Karma: 26165759
Join Date: Nov 2006
Location: UK
Device: Kindle Touch, PW, Fire HD, iPad 3, iPhone 4, Samsung Tab 2 7 + More
|
This will probably have the HTML purists beating their heads against the wall in horror, but the "depracated-but-still-supported-by-all-devices" <center> tag is jolly useful for this kind of thing.
__________________
Harry Currently proofreading The Poison Belt, by Sir Arthur Conan Doyle. |
|
|
|
|
|
#11 | |
|
Det
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 716
Karma: 450180
Join Date: Jan 2012
Location: Zischebattem
Device: Acer Lumiread
|
Quote:
Sigil transforms the "<center>" to an "sgc-1 {text-align: center}" without hesitation. "<center>" ist html-transitional only, so i won't assume, that it will be supportet by all devices. |
|
|
|
|
|
|
#12 | |
|
Member
![]() Posts: 10
Karma: 10
Join Date: Jan 2011
Device: none
|
Quote:
WOW!!! There are so many replies!!! A great thank to all of you. I will give it a try on the suggestions all of you have put here. Thanks to you all! |
|
|
|
|
|
|
#13 |
|
Enthusiast
![]() Posts: 31
Karma: 10
Join Date: Aug 2012
Device: Kindle
|
This was a huge help to me today. Karma all around; thank you.
|
|
|
|
![]() |
| Thread Tools | Search this Thread |
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Text in a box? | Skeezix | Mobi | 3 | 01-23-2012 07:22 AM |
| Thinking 'outside the box'...new uses... | Reader Paradice | Kobo Tablets | 20 | 12-01-2011 06:42 PM |
| $119.99 PE New in Box | Emptora | enTourage eDGe | 4 | 08-17-2011 02:14 PM |
| Sell Smart Q7, w/ box etc. | rogue_ronin | Flea Market | 0 | 12-17-2009 06:46 PM |
| Kindle out of the box | aconfrere | Introduce Yourself | 3 | 01-18-2008 07:02 PM |