User:ArdentPerf/Sandbox

From Wikibooks, open books for an open world
Jump to navigation Jump to search

Sandbox Page...

Wiki Formatting for Screenshots and Steps - Good Appearance in Print[edit | edit source]

Problem: This book is a how-to and it has steps which contain screenshots. Each step has an initial screenshot. The steps are in a numbered list.

I want the step text (instructions) to appear immediately after the number, and the screenshot to appear underneath the text. However I don't want the screenshot to ever break onto the next page when this is printed or converted to PDF. That will almost always happen naturally.

Note: I'm just going to choose one situation, and be concerned about that. (Rather than the 50 ways you can print a wiki page.) I'm going to look at printing via collections, hopefully direct-to-PDF (without passing through OpenOffice). I don't care how the pages render when printed by any browser, or with other tools for PDF conversion.

WikiBooks uses a software called ReportLab under the hood to render the PDF. The "export to PDF" link from each individual page can be used to test functionality.

Filler Text[edit | edit source]

A little filler text so that the testing section below falls on a page break!

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

Testing[edit | edit source]

  1. here.

    And an additional comment...

  2. Next step text... follow these instructions after doing step 1! Here is another sentence about this.
  3. And next step which of course comes after both steps 1 and 2.
  4. Here's a step with some text output...
    [root@collabn1 ~]# fdisk /dev/sdb
    Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
    Building a new DOS disklabel. Changes will remain in memory only,
    until you decide to write them. After that, of course, the previous
    content won't be recoverable.
    
    Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)
    
    Command (m for help): n
    Command action
       e   extended
       p   primary partition (1-4)
    p
    Partition number (1-4): 1
    First cylinder (1-652, default 1): ^M  [default]
    Using default value 1
    Last cylinder or +size or +sizeM or +sizeK (1-652, default 652):
    Using default value 652
    
    Command (m for help): t
    Selected partition 1
    Hex code (type L to list codes): da
    Changed system type of partition 1 to da (Non-FS data)
    
    Command (m for help): w
    The partition table has been altered! 
    
    WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
    The kernel still uses the old table.
    Syncing disks.
    
  5. Another step -- going to repeat the image from step 1...


Testing Control - Text Block[edit | edit source]

[root@collabn1 ~]# fdisk /dev/sdb
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel. Changes will remain in memory only,
until you decide to write them. After that, of course, the previous
content won't be recoverable.

Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)

Command (m for help): n
Command action
   e   extended
   p   primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-652, default 1): ^M  [default]
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-652, default 652):
Using default value 652

Command (m for help): t
Selected partition 1
Hex code (type L to list codes): da
Changed system type of partition 1 to da (Non-FS data)

Command (m for help): w
The partition table has been altered! 

WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
The kernel still uses the old table.
Syncing disks.

Testing Control - Images from WikiBooks[edit | edit source]