The Battle for Wesnoth  1.13.4+dev
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
grid.hpp
Go to the documentation of this file.
1 /*
2  Copyright (C) 2008 - 2016 by Mark de Wever <[email protected]>
3  Part of the Battle for Wesnoth Project http://www.wesnoth.org/
4 
5  This program is free software; you can redistribute it and/or modify
6  it under the terms of the GNU General Public License as published by
7  the Free Software Foundation; either version 2 of the License, or
8  (at your option) any later version.
9  This program is distributed in the hope that it will be useful,
10  but WITHOUT ANY WARRANTY.
11 
12  See the COPYING file for more details.
13 */
14 
15 #ifndef GUI_WIDGETS_GRID_HPP_INCLUDED
16 #define GUI_WIDGETS_GRID_HPP_INCLUDED
17 
18 #include "gui/widgets/widget.hpp"
19 
20 namespace gui2
21 {
22 
23 /**
24  * Base container class.
25  *
26  * This class holds a number of widgets and their wanted layout parameters. It
27  * also layouts the items in the grid and handles their drawing.
28  */
29 class tgrid : public twidget
30 {
31  friend class tdebug_layout_graph;
32  friend struct tgrid_implementation;
33 
34 public:
35  explicit tgrid(const unsigned rows = 0, const unsigned cols = 0);
36 
37  virtual ~tgrid();
38 
39  /***** ***** ***** ***** LAYOUT FLAGS ***** ***** ***** *****/
40  static const unsigned VERTICAL_SHIFT = 0;
41  static const unsigned VERTICAL_GROW_SEND_TO_CLIENT = 1 << VERTICAL_SHIFT;
42  static const unsigned VERTICAL_ALIGN_TOP = 2 << VERTICAL_SHIFT;
43  static const unsigned VERTICAL_ALIGN_CENTER = 3 << VERTICAL_SHIFT;
44  static const unsigned VERTICAL_ALIGN_BOTTOM = 4 << VERTICAL_SHIFT;
45  static const unsigned VERTICAL_MASK = 7 << VERTICAL_SHIFT;
46 
47  static const unsigned HORIZONTAL_SHIFT = 3;
48  static const unsigned HORIZONTAL_GROW_SEND_TO_CLIENT = 1
50  static const unsigned HORIZONTAL_ALIGN_LEFT = 2 << HORIZONTAL_SHIFT;
51  static const unsigned HORIZONTAL_ALIGN_CENTER = 3 << HORIZONTAL_SHIFT;
52  static const unsigned HORIZONTAL_ALIGN_RIGHT = 4 << HORIZONTAL_SHIFT;
53  static const unsigned HORIZONTAL_MASK = 7 << HORIZONTAL_SHIFT;
54 
55  static const unsigned BORDER_TOP = 1 << 6;
56  static const unsigned BORDER_BOTTOM = 1 << 7;
57  static const unsigned BORDER_LEFT = 1 << 8;
58  static const unsigned BORDER_RIGHT = 1 << 9;
59  static const unsigned BORDER_ALL = BORDER_TOP | BORDER_BOTTOM | BORDER_LEFT
60  | BORDER_RIGHT;
61 
62  /***** ***** ***** ***** ROW COLUMN MANIPULATION ***** ***** ***** *****/
63 
64  /**
65  * Adds a row to end of the grid.
66  *
67  * @param count Number of rows to add, should be > 0.
68  *
69  * @returns The row number of the first row added.
70  */
71  unsigned add_row(const unsigned count = 1);
72 
73  /**
74  * Sets the grow factor for a row.
75  *
76  * @todo refer to a page with the layout manipulation info.
77  *
78  * @param row The row to modify.
79  * @param factor The grow factor.
80  */
81  void set_row_grow_factor(const unsigned row, const unsigned factor)
82  {
83  assert(row < row_grow_factor_.size());
84  row_grow_factor_[row] = factor;
85  set_is_dirty(true);
86  }
87 
88  /**
89  * Sets the grow factor for a column.
90  *
91  * @todo refer to a page with the layout manipulation info.
92  *
93  * @param column The column to modify.
94  * @param factor The grow factor.
95  */
96  void set_column_grow_factor(const unsigned column, const unsigned factor)
97  {
98  assert(column < col_grow_factor_.size());
99  col_grow_factor_[column] = factor;
100  set_is_dirty(true);
101  }
102 
103  /***** ***** ***** ***** CHILD MANIPULATION ***** ***** ***** *****/
104 
105  /**
106  * Sets a child in the grid.
107  *
108  * When the child is added to the grid the grid 'owns' the widget.
109  * The widget is put in a cell, and every cell can only contain 1 widget if
110  * the wanted cell already contains a widget, that widget is freed and
111  * removed.
112  *
113  * @param widget The widget to put in the grid.
114  * @param row The row of the cell.
115  * @param col The columnof the cell.
116  * @param flags The flags for the widget in the cell.
117  * @param border_size The size of the border for the cell, how the
118  * border is applied depends on the flags.
119  */
120  void set_child(twidget* widget,
121  const unsigned row,
122  const unsigned col,
123  const unsigned flags,
124  const unsigned border_size);
125 
126  /**
127  * Exchanges a child in the grid.
128  *
129  * It replaced the child with a certain id with the new widget but doesn't
130  * touch the other settings of the child.
131  *
132  * @param id The id of the widget to free.
133  * @param widget The widget to put in the grid.
134  * @param recurse Do we want to decent into the child grids.
135  * @param new_parent The new parent for the swapped out widget.
136  *
137  * returns The widget which got removed (the parent of
138  * the widget is cleared). If no widget found
139  * and thus not replace nullptr will returned.
140  */
141  twidget* swap_child(const std::string& id,
142  twidget* widget,
143  const bool recurse,
144  twidget* new_parent = nullptr);
145 
146  /**
147  * Removes and frees a widget in a cell.
148  *
149  * @param row The row of the cell.
150  * @param col The columnof the cell.
151  */
152  void remove_child(const unsigned row, const unsigned col);
153 
154  /**
155  * Removes and frees a widget in a cell by it's id.
156  *
157  * @param id The id of the widget to free.
158  * @param find_all If true if removes all items with the id,
159  * otherwise it stops after removing the first
160  * item (or once all children have been tested).
161  */
162  void remove_child(const std::string& id, const bool find_all = false);
163 
164  /**
165  * Activates all children.
166  *
167  * If a child inherits from tcontrol or is a tgrid it will call
168  * set_active() for the child otherwise it ignores the widget.
169  *
170  * @param active Parameter for set_active.
171  */
172  void set_active(const bool active);
173 
174 
175  /** Returns the widget in the selected cell. */
176  const twidget* widget(const unsigned row, const unsigned col) const
177  {
178  return child(row, col).widget();
179  }
180 
181  /** Returns the widget in the selected cell. */
182  twidget* widget(const unsigned row, const unsigned col)
183  {
184  return child(row, col).widget();
185  }
186 
187  virtual bool can_mouse_focus() const override { return false; }
188  /***** ***** ***** ***** layout functions ***** ***** ***** *****/
189 
190  /** See @ref twidget::layout_initialise. */
191  virtual void layout_initialise(const bool full_initialisation) override;
192 
193  /**
194  * Tries to reduce the width of a container.
195  *
196  * See @ref layout_algorithm for more information.
197  *
198  * @param maximum_width The wanted maximum width.
199  */
200  void reduce_width(const unsigned maximum_width);
201 
202  /** See @ref twidget::request_reduce_width. */
203  virtual void request_reduce_width(const unsigned maximum_width) override;
204 
205  /** See @ref twidget::demand_reduce_width. */
206  virtual void demand_reduce_width(const unsigned maximum_width) override;
207 
208  /**
209  * Tries to reduce the height of a container.
210  *
211  * See @ref layout_algorithm for more information.
212  *
213  * @param maximum_height The wanted maximum height.
214  */
215  void reduce_height(const unsigned maximum_height);
216 
217  /** See @ref twidget::request_reduce_height. */
218  virtual void request_reduce_height(const unsigned maximum_height) override;
219 
220  /** See @ref twidget::demand_reduce_height. */
221  virtual void demand_reduce_height(const unsigned maximum_height) override;
222 
223  /**
224  * Recalculates the best size.
225  *
226  * This is used for scrollbar containers when they try to update their
227  * contents size before falling back to the 'global' invalidate_layout.
228  *
229  * @returns The newly calculated size.
230  */
232 
233 private:
234  /** See @ref twidget::calculate_best_size. */
235  virtual tpoint calculate_best_size() const override;
236 
237 public:
238  /** See @ref twidget::can_wrap. */
239  virtual bool can_wrap() const override;
240 
241 public:
242  /** See @ref twidget::place. */
243  virtual void place(const tpoint& origin, const tpoint& size) override;
244 
245  /***** ***** ***** ***** Inherited ***** ***** ***** *****/
246 
247  /** See @ref twidget::set_origin. */
248  virtual void set_origin(const tpoint& origin) override;
249 
250  /** See @ref twidget::set_visible_rectangle. */
251  virtual void set_visible_rectangle(const SDL_Rect& rectangle) override;
252 
253  /** See @ref twidget::layout_children. */
254  virtual void layout_children() override;
255 
256  /** See @ref twidget::child_populate_dirty_list. */
257  virtual void
259  const std::vector<twidget*>& call_stack) override;
260 
261  /** See @ref twidget::find_at. */
262  virtual twidget* find_at(const tpoint& coordinate,
263  const bool must_be_active) override;
264 
265  /** See @ref twidget::find_at. */
266  virtual const twidget* find_at(const tpoint& coordinate,
267  const bool must_be_active) const override;
268 
269  /** See @ref twidget::find. */
270  twidget* find(const std::string& id, const bool must_be_active) override;
271 
272  /** See @ref twidget::find. */
273  const twidget* find(const std::string& id,
274  const bool must_be_active) const override;
275 
276  /** See @ref twidget::has_widget. */
277  virtual bool has_widget(const twidget& widget) const override;
278 
279  /** See @ref twidget::disable_click_dismiss. */
280  bool disable_click_dismiss() const override;
281 
282  /** See @ref twidget::create_walker. */
283  virtual iterator::twalker_* create_walker() override;
284 
285  /***** ***** ***** setters / getters for members ***** ****** *****/
286 
287  void set_rows(const unsigned rows);
288  unsigned int get_rows() const
289  {
290  return rows_;
291  }
292 
293  void set_cols(const unsigned cols);
294  unsigned int get_cols() const
295  {
296  return cols_;
297  }
298 
299  /**
300  * Wrapper to set_rows and set_cols.
301  *
302  * @param rows Parameter to call set_rows with.
303  * @param cols Parameter to call set_cols with.
304  */
305  void set_rows_cols(const unsigned rows, const unsigned cols);
306 
307 private:
308  /** Child item of the grid. */
309  class tchild
310  {
311  friend struct tgrid_implementation;
312 
313  public:
314  tchild() : flags_(0), border_size_(0), widget_(nullptr)
315 
316  // Fixme make a class where we can store some properties in the cache
317  // regarding size etc.
318  {
319  }
320 
321  /** Returns the best size for the cell. */
322  tpoint get_best_size() const;
323 
324  /**
325  * Places the widget in the cell.
326  *
327  * @param origin The origin (x, y) for the widget.
328  * @param size The size for the widget.
329  */
330  void place(tpoint origin, tpoint size);
331 
332  /** Forwards @ref tgrid::layout_initialise to the cell. */
333  void layout_initialise(const bool full_initialisation);
334 
335  /** Returns the can_wrap for the cell. */
336  bool can_wrap() const
337  {
338  return widget_ ? widget_->can_wrap() : false;
339  }
340 
341  /** Returns the id of the widget/ */
342  const std::string& id() const;
343 
344  unsigned get_flags() const
345  {
346  return flags_;
347  }
348  void set_flags(const unsigned flags)
349  {
350  flags_ = flags;
351  }
352 
353  unsigned get_border_size() const
354  {
355  return border_size_;
356  }
357  void set_border_size(const unsigned border_size)
358  {
359  border_size_ = border_size;
360  }
361 
362  const twidget* widget() const
363  {
364  return widget_;
365  }
367  {
368  return widget_;
369  }
370 
372  {
373  widget_ = widget;
374  }
375 
376  private:
377  /** The flags for the border and cell setup. */
378  unsigned flags_;
379 
380  /**
381  * The size of the border, the actual configuration of the border
382  * is determined by the flags.
383  */
384  unsigned border_size_;
385 
386  /**
387  * Pointer to the widget.
388  *
389  * Once the widget is assigned to the grid we own the widget and are
390  * responsible for it's destruction.
391  */
393 
394  /** Returns the space needed for the border. */
395  tpoint border_space() const;
396 
397  }; // class tchild
398 
399 public:
400  /** Iterator for the tchild items. */
401  class iterator
402  {
403 
404  public:
406  {
407  }
408 
410  {
411  return iterator(++itor_);
412  }
414  {
415  return iterator(--itor_);
416  }
418  {
419  return itor_->widget();
420  }
422  {
423  return itor_->widget();
424  }
425 
426  bool operator==(const iterator& i) const
427  {
428  return i.itor_ == this->itor_;
429  }
430 
431  bool operator!=(const iterator& i) const
432  {
433  return i.itor_ != this->itor_;
434  }
435 
436  private:
438  };
439 
441  {
442  return iterator(children_.begin());
443  }
445  {
446  return iterator(children_.end());
447  }
448 
449 private:
450  /** The number of grid rows. */
451  unsigned rows_;
452 
453  /** The number of grid columns. */
454  unsigned cols_;
455 
456  /***** ***** ***** ***** size caching ***** ***** ***** *****/
457 
458  /** The row heights in the grid. */
459  mutable std::vector<unsigned> row_height_;
460 
461  /** The column widths in the grid. */
462  mutable std::vector<unsigned> col_width_;
463 
464  /** The grow factor for all rows. */
465  std::vector<unsigned> row_grow_factor_;
466 
467  /** The grow factor for all columns. */
468  std::vector<unsigned> col_grow_factor_;
469 
470  /**
471  * The child items.
472  *
473  * All children are stored in a 1D vector and the formula to access a cell
474  * is: rows_ * col + row. All other vectors use the same access formula.
475  */
476  std::vector<tchild> children_;
477  const tchild& child(const unsigned row, const unsigned col) const
478  {
479  return children_[rows_ * col + row];
480  }
481  tchild& child(const unsigned row, const unsigned col)
482  {
483  return children_[rows_ * col + row];
484  }
485 
486  /** Layouts the children in the grid. */
487  void layout(const tpoint& origin);
488 
489  /** See @ref twidget::impl_draw_children. */
490  virtual void impl_draw_children(surface& frame_buffer,
491  int x_offset,
492  int y_offset) override;
493 };
494 
495 /**
496  * Sets the single child in a grid.
497  *
498  * The function initializes the grid to 1 x 1 and adds the widget with the grow
499  * to client flags.
500  *
501  * @param grid The grid to add the child to.
502  * @param widget The widget to add as child to the grid.
503  */
504 void set_single_child(tgrid& grid, twidget* widget);
505 
506 } // namespace gui2
507 
508 #endif
void set_single_child(tgrid &grid, twidget *widget)
Sets the single child in a grid.
Definition: grid.cpp:1021
static const unsigned HORIZONTAL_SHIFT
Definition: grid.hpp:47
void remove_child(const unsigned row, const unsigned col)
Removes and frees a widget in a cell.
Definition: grid.cpp:140
unsigned cols_
The number of grid columns.
Definition: grid.hpp:454
void reduce_height(const unsigned maximum_height)
Tries to reduce the height of a container.
Definition: grid.cpp:280
static const unsigned BORDER_BOTTOM
Definition: grid.hpp:56
static const unsigned BORDER_ALL
Definition: grid.hpp:59
bool operator==(const iterator &i) const
Definition: grid.hpp:426
void set_row_grow_factor(const unsigned row, const unsigned factor)
Sets the grow factor for a row.
Definition: grid.hpp:81
twidget * operator->()
Definition: grid.hpp:417
virtual void demand_reduce_height(const unsigned maximum_height) override
See twidget::demand_reduce_height.
Definition: grid.cpp:366
virtual bool can_wrap() const
Can the widget wrap.
Definition: widget.cpp:211
bool operator!=(const iterator &i) const
Definition: grid.hpp:431
virtual void layout_children() override
See twidget::layout_children.
Definition: grid.cpp:575
static const unsigned HORIZONTAL_MASK
Definition: grid.hpp:53
tgrid(const unsigned rows=0, const unsigned cols=0)
Definition: grid.cpp:37
Base container class.
Definition: grid.hpp:29
virtual bool can_mouse_focus() const override
Whether the mouse move/click event go 'through' this widget.
Definition: grid.hpp:187
static const unsigned HORIZONTAL_ALIGN_RIGHT
Definition: grid.hpp:52
virtual void impl_draw_children(surface &frame_buffer, int x_offset, int y_offset) override
See twidget::impl_draw_children.
Definition: grid.cpp:908
static const unsigned VERTICAL_GROW_SEND_TO_CLIENT
Definition: grid.hpp:41
unsigned int get_rows() const
Definition: grid.hpp:288
virtual void place(const tpoint &origin, const tpoint &size) override
See twidget::place.
Definition: grid.cpp:435
static const unsigned HORIZONTAL_GROW_SEND_TO_CLIENT
Definition: grid.hpp:48
tpoint recalculate_best_size()
Recalculates the best size.
Definition: grid.cpp:371
bool disable_click_dismiss() const override
See twidget::disable_click_dismiss.
Definition: grid.cpp:638
static const unsigned BORDER_RIGHT
Definition: grid.hpp:58
twidget * widget(const unsigned row, const unsigned col)
Returns the widget in the selected cell.
Definition: grid.hpp:182
virtual void set_origin(const tpoint &origin) override
See twidget::set_origin.
Definition: grid.cpp:542
void set_is_dirty(const bool is_dirty)
Definition: widget.cpp:435
static const unsigned BORDER_TOP
Definition: grid.hpp:55
static const unsigned VERTICAL_SHIFT
Definition: grid.hpp:40
base class of top level items, the only item which needs to store the final canvases to draw on ...
Definition: window.hpp:62
std::vector< unsigned > row_height_
The row heights in the grid.
Definition: grid.hpp:459
A class inherited from ttext_box that displays its input as stars.
Definition: field-fwd.hpp:23
void place(tpoint origin, tpoint size)
Places the widget in the cell.
Definition: grid.cpp:722
static const unsigned HORIZONTAL_ALIGN_LEFT
Definition: grid.hpp:50
virtual ~tgrid()
Definition: grid.cpp:48
void layout_initialise(const bool full_initialisation)
Forwards tgrid::layout_initialise to the cell.
Definition: grid.cpp:851
virtual iterator::twalker_ * create_walker() override
See twidget::create_walker.
Definition: grid.cpp:656
virtual void request_reduce_height(const unsigned maximum_height) override
See twidget::request_reduce_height.
Definition: grid.cpp:313
const tchild & child(const unsigned row, const unsigned col) const
Definition: grid.hpp:477
const twidget * widget() const
Definition: grid.hpp:362
iterator begin()
Definition: grid.hpp:440
unsigned rows_
The number of grid rows.
Definition: grid.hpp:451
unsigned get_border_size() const
Definition: grid.hpp:353
void set_column_grow_factor(const unsigned column, const unsigned factor)
Sets the grow factor for a column.
Definition: grid.hpp:96
std::vector< unsigned > row_grow_factor_
The grow factor for all rows.
Definition: grid.hpp:465
void layout(const tpoint &origin)
Layouts the children in the grid.
Definition: grid.cpp:886
void set_rows(const unsigned rows)
Definition: grid.cpp:661
friend class tdebug_layout_graph
Definition: grid.hpp:31
Iterator for the tchild items.
Definition: grid.hpp:401
void set_active(const bool active)
Activates all children.
Definition: grid.cpp:168
virtual void request_reduce_width(const unsigned maximum_width) override
See twidget::request_reduce_width.
Definition: grid.cpp:237
static const unsigned VERTICAL_ALIGN_TOP
Definition: grid.hpp:42
std::vector< unsigned > col_grow_factor_
The grow factor for all columns.
Definition: grid.hpp:468
GLuint GLuint GLsizei count
Definition: glew.h:1221
cl_event GLbitfield flags
Definition: glew.h:3070
virtual bool has_widget(const twidget &widget) const override
See twidget::has_widget.
Definition: grid.cpp:623
virtual void set_visible_rectangle(const SDL_Rect &rectangle) override
See twidget::set_visible_rectangle.
Definition: grid.cpp:560
twidget * widget()
Definition: grid.hpp:366
GLenum GLenum GLvoid GLvoid * column
Definition: glew.h:3805
void set_border_size(const unsigned border_size)
Definition: grid.hpp:357
std::vector< tchild >::iterator itor_
Definition: grid.hpp:437
iterator(std::vector< tchild >::iterator itor)
Definition: grid.hpp:405
std::map< std::string, tfilter >::iterator itor
Definition: filter.cpp:199
unsigned get_flags() const
Definition: grid.hpp:344
virtual bool can_wrap() const override
See twidget::can_wrap.
Definition: grid.cpp:422
iterator operator--()
Definition: grid.hpp:413
size_t i
Definition: function.cpp:1057
twidget * swap_child(const std::string &id, twidget *widget, const bool recurse, twidget *new_parent=nullptr)
Exchanges a child in the grid.
Definition: grid.cpp:99
tpoint border_space() const
Returns the space needed for the border.
Definition: grid.cpp:866
twidget * operator*()
Definition: grid.hpp:421
Holds a 2D point.
Definition: point.hpp:24
virtual tpoint calculate_best_size() const override
See twidget::calculate_best_size.
Definition: grid.cpp:378
virtual void demand_reduce_width(const unsigned maximum_width) override
See twidget::demand_reduce_width.
Definition: grid.cpp:275
Child item of the grid.
Definition: grid.hpp:309
unsigned add_row(const unsigned count=1)
Adds a row to end of the grid.
Definition: grid.cpp:58
static const unsigned VERTICAL_ALIGN_CENTER
Definition: grid.hpp:43
bool can_wrap() const
Returns the can_wrap for the cell.
Definition: grid.hpp:336
std::vector< tchild > children_
The child items.
Definition: grid.hpp:476
tchild & child(const unsigned row, const unsigned col)
Definition: grid.hpp:481
void set_widget(twidget *widget)
Definition: grid.hpp:371
GLsizeiptr size
Definition: glew.h:1649
void set_rows_cols(const unsigned rows, const unsigned cols)
Wrapper to set_rows and set_cols.
Definition: grid.cpp:679
unsigned border_size_
The size of the border, the actual configuration of the border is determined by the flags...
Definition: grid.hpp:384
GLenum GLenum GLvoid * row
Definition: glew.h:3805
iterator operator++()
Definition: grid.hpp:409
void set_cols(const unsigned cols)
Definition: grid.cpp:670
const std::string & id() const
Returns the id of the widget/.
Definition: grid.cpp:860
Base class for all widgets.
Definition: widget.hpp:49
twidget * widget_
Pointer to the widget.
Definition: grid.hpp:392
static const unsigned HORIZONTAL_ALIGN_CENTER
Definition: grid.hpp:51
void set_flags(const unsigned flags)
Definition: grid.hpp:348
unsigned flags_
The flags for the border and cell setup.
Definition: grid.hpp:378
Helper to implement private functions without modifying the header.
virtual void layout_initialise(const bool full_initialisation) override
See twidget::layout_initialise.
Definition: grid.cpp:191
twidget * find(const std::string &id, const bool must_be_active) override
See twidget::find.
Definition: grid.cpp:612
static const unsigned VERTICAL_MASK
Definition: grid.hpp:45
void set_child(twidget *widget, const unsigned row, const unsigned col, const unsigned flags, const unsigned border_size)
Sets a child in the grid.
Definition: grid.cpp:69
const twidget * widget(const unsigned row, const unsigned col) const
Returns the widget in the selected cell.
Definition: grid.hpp:176
The walker abstract base class.
Definition: walker.hpp:27
void reduce_width(const unsigned maximum_width)
Tries to reduce the width of a container.
Definition: grid.cpp:204
std::string::const_iterator iterator
Definition: tokenizer.hpp:21
tpoint get_best_size() const
Returns the best size for the cell.
Definition: grid.cpp:697
static const unsigned VERTICAL_ALIGN_BOTTOM
Definition: grid.hpp:44
virtual void child_populate_dirty_list(twindow &caller, const std::vector< twidget * > &call_stack) override
See twidget::child_populate_dirty_list.
Definition: grid.cpp:584
unsigned int get_cols() const
Definition: grid.hpp:294
GLsizei const GLcharARB ** string
Definition: glew.h:4503
virtual twidget * find_at(const tpoint &coordinate, const bool must_be_active) override
See twidget::find_at.
Definition: grid.cpp:599
std::vector< unsigned > col_width_
The column widths in the grid.
Definition: grid.hpp:462
static const unsigned BORDER_LEFT
Definition: grid.hpp:57
iterator end()
Definition: grid.hpp:444