stlab.adobe.com Adobe Systems Incorporated
eve.hpp
Go to the documentation of this file.
1 /*
2  Copyright 2005-2007 Adobe Systems Incorporated
3  Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt
4  or a copy at http://stlab.adobe.com/licenses.html)
5 */
6 
7 /*************************************************************************************************/
8 
9 #ifndef ADOBE_EVE_HPP
10 #define ADOBE_EVE_HPP
11 
12 #include <adobe/config.hpp>
13 
14 #include <utility>
15 
16 #include <boost/noncopyable.hpp>
17 
18 #include <adobe/forest.hpp>
19 #include <adobe/extents.hpp>
20 #include <adobe/poly_placeable.hpp>
22 
23 /*************************************************************************************************/
24 
25 namespace adobe {
26 namespace implementation {
27 
28 /*************************************************************************************************/
29 
30 struct view_proxy_t;
31 
32 /*************************************************************************************************/
33 
34 } // namespace implementation
35 } // namespace adobe
36 
37 /*************************************************************************************************/
38 
39 #if !defined(ADOBE_NO_DOCUMENTATION)
40 namespace boost {
41 namespace detail {
42  template <>
43  struct is_pod_impl<adobe::implementation::view_proxy_t>
44  {
45  BOOST_STATIC_CONSTANT(bool, value = true);
46  };
47 }
48 }
49 #endif
50 
51 /*************************************************************************************************/
52 
53 namespace adobe {
54 
55 /*************************************************************************************************/
56 
57 
65 class eve_t
66 #if !defined(ADOBE_NO_DOCUMENTATION)
67  : boost::noncopyable, public extents_slices_t, public layout_attributes_placement_t
68 #endif
69 {
70  public:
71 
72 #if !defined(ADOBE_NO_DOCUMENTATION)
73  typedef forest<implementation::view_proxy_t> proxy_tree_t;
74  typedef proxy_tree_t::iterator iterator;
75 #endif
76 
77 
78 
79 
86  {
93  };
94 
95 /*
96  REVISIT (sparent) : I'm just starting a long cleanup of the Eve API - the steps should include
97  the following:
98 
99  * eliminate the container default proc in favor of an inital extents setting.
100  * rename calculate to calculate_horizontal - all calculation passes are optional (initial should
101  often suffice).
102 */
103 
104 
105 #if !defined(ADOBE_NO_DOCUMENTATION)
106  explicit eve_t();
107  ~eve_t();
108 #endif
109 
192  iterator add_placeable( iterator parent,
193  const layout_attributes_t& initial,
194  bool is_container_type,
196  bool reverse=false);
197 
202  void set_visible(iterator, bool);
203 
204 
216  std::pair<int, int> evaluate(evaluate_options_t options, int width = 0, int height = 0);
217 
218 
235  std::pair<int, int> adjust(evaluate_options_t options, int width, int height);
236 
237  private:
238  friend struct implementation::view_proxy_t;
239 
240  class implementation_t;
241  implementation_t* object_m;
242 };
243 
244 
245 /*************************************************************************************************/
246 
247 void set_margin(layout_attributes_t& container, int x);
248 
249 /*************************************************************************************************/
250 
251 } // namespace adobe
252 
253 /*************************************************************************************************/
254 
255 #endif
256 
257 /*************************************************************************************************/
258 

Copyright © 2006-2007 Adobe Systems Incorporated.

Use of this website signifies your agreement to the Terms of Use and Online Privacy Policy.

Search powered by Google