Changes between Version 4 and Version 5 of documentation/tutorials/Dragging

Show
Ignore:
Author:
peterc (IP: 203.114.164.70)
Timestamp:
02/13/08 23:02:15 (10 years ago)
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • documentation/tutorials/Dragging

    v4 v5  
    1313Compile the drag tutorial (at ''/samples/tutorials/drag/'') and run the program; it should end up looking like this: 
    1414 
    15 < insert piccie > 
     15[[Image(tutorial_template_1.gif, nolink)]] 
    1616 
    1717Take a look at the source code. As you can see, the application creates two ''Inventory'' objects, each of which loads a document from the 'inventory.rml' file. The application then creates four inventory objects in one of the inventories; each of these objects is a libRocket element with a tag of 'icon'. At the bottom of the 'tutorial.rcss' file you can see the properties applied to 'icon'. It is sized to 100px x 100px with a margin to separate it from its neighbour icons and a decorator for its background image. It is floated left so icons will stack from left to right in the inventory windows.