MFMv2.0.10
Movable Feast Machine Simulator 2.0.10
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
ToolboxPanel.h
Go to the documentation of this file.
1 /* -*- mode:C++ -*-
2  ToolboxPanel.h A Panel for selecting editing tools
3  Copyright (C) 2014 The Regents of the University of New Mexico. All rights reserved.
4 
5  This library is free software; you can redistribute it and/or
6  modify it under the terms of the GNU Lesser General Public
7  License as published by the Free Software Foundation; either
8  version 2.1 of the License, or (at your option) any later version.
9 
10  This library is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  Lesser General Public License for more details.
14 
15  You should have received a copy of the GNU General Public License
16  along with this library; if not, write to the Free Software
17  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301
18  USA
19 */
20 
27 #ifndef TOOLBOXPANEL_H
28 #define TOOLBOXPANEL_H
29 
30 #include "EditingTool.h"
31 #include "FileByteSink.h"
32 #include "Parameter.h"
33 #include "AbstractButton.h"
34 #include "Slider.h"
36 #include "NeighborSelectPanel.h"
37 #include "MovablePanel.h"
38 
39 namespace MFM
40 {
45  template<class CC>
46  class ToolboxPanel : public MovablePanel
47  {
48  private:
49  typedef ElementParameterS32<CC> OurParameterS32; // ToolboxPanel controls Elements (vs AtomViewPanel)
50  typedef ElementParameterBool<CC> OurParameterBool; // ToolboxPanel controls Elements (vs AtomViewPanel)
51  typedef Slider<CC> OurSlider;
53 
54  enum {
55  ELEMENT_BOX_BUTTON_COUNT = 9,
56  TOOLBOX_MAX_CONTROLLERS = 20,
57  TOOLBOX_MAX_SLIDERS = 8,
58  TOOLBOX_MAX_CHECKBOXES = 8,
59  TOOLBOX_MAX_NEIGHBORHOODS = 8,
60  ELEMENT_RENDER_SIZE = 32,
61  ELEMENT_BIG_RENDER_SIZE = 48,
62  ELEMENT_BOX_SIZE = 77,
63 
64  R = CC::PARAM_CONFIG::EVENT_WINDOW_RADIUS,
65  SITES = EVENT_WINDOW_SITES(R)
66  };
67 
68  bool m_bigText;
69 
70  inline u32 GetElementRenderSize()
71  {
72  return m_bigText ? ELEMENT_BIG_RENDER_SIZE : ELEMENT_RENDER_SIZE;
73  }
74 
75  inline FontAsset GetElementRenderFont()
76  {
77  return m_bigText ? FONT_ASSET_ELEMENT_BIG : FONT_ASSET_ELEMENT;
78  }
79 
84  class ToolButton : public AbstractButton
85  {
86  protected:
87  EditingTool* m_toolboxTool;
88 
89  ToolboxPanel<CC>* m_parent;
90 
91  EditingTool m_tool;
92 
93  public:
101  ToolButton() :
102  AbstractButton(),
103  m_toolboxTool(0),
104  m_parent(0)
105  {
106  this->Panel::SetBackground(Drawing::GREY90);
107  this->Panel::SetBorder(Drawing::GREY40);
108  }
109 
110  void SetToolPointer(EditingTool* toolboxTool)
111  {
112  m_toolboxTool = toolboxTool;
113  }
114 
115  void SetEditingTool(EditingTool tool)
116  {
117  m_tool = tool;
118  }
119 
120  EditingTool GetEditingTool()
121  {
122  return m_tool;
123  }
124 
130  void SetParent(ToolboxPanel<CC>* parent)
131  {
132  m_parent = parent;
133  }
134 
142  void SetToolIcon(SDL_Surface* icon)
143  {
144  SetIcon(icon);
145  this->Panel::SetDimensions(icon->w, icon->h);
146  }
147 
156  void SetActivated(bool activated)
157  {
158  // DO NOT REWRITE THIS 'IF' AS A QUESTION-COLON; IT DOES NOT
159  // COMPILE ON 12.04.
160  if (activated)
161  {
162  SetBackground(Drawing::GREY40);
163  }
164  else
165  {
166  SetBackground(Drawing::GREY80);
167  }
168  }
169 
176  virtual void OnClick(u8 button)
177  {
178  *m_toolboxTool = m_tool;
179  m_parent->ActivateButton(this);
180  }
181  };
182 
183  struct ElementButton : public AbstractButton
184  {
185  ElementButton() :
187  {
188  this->Panel::SetBorder(Drawing::GREY70);
189 
190  this->Panel::SetBackground(Drawing::GREY80);
191 
192  this->Panel::SetForeground(Drawing::GREY70);
193 
194  this->Panel::SetBorder(Drawing::GREY60);
195 
197  }
198 
199  void SetElement(Element<CC>* element)
200  {
201  m_element = element;
202 
203  AbstractButton::SetEnabled(!!m_element);
204 
205  if (m_element)
206  {
207  OString16 name;
208  name.Printf("EltBtn-%s",element->GetAtomicSymbol());
209  this->SetName(name.GetZString());
210  }
211  }
212 
213  void SetParent(ToolboxPanel<CC>* parent)
214  {
215  m_parent = parent;
216  }
217 
218  virtual void PaintComponentNonClick(Drawing& d)
219  {
220  const u32 SIZE = m_parent->GetElementRenderSize();
221  if(m_element)
222  {
223  d.SetForeground(m_element->PhysicsColor());
224  d.FillRect(0, 0, SIZE, SIZE);
225  d.SetFont(AssetManager::Get(m_parent->GetElementRenderFont()));
226  d.SetBackground(Drawing::BLACK);
227  d.SetForeground(Drawing::WHITE);
228  d.BlitBackedTextCentered(m_element->GetAtomicSymbol(),
229  UPoint(0, 0),
230  UPoint(SIZE, SIZE));
231  }
232  else
233  {
234  d.SetForeground(this->GetForeground());
235  d.FillRect(0, 0, SIZE, SIZE);
236  }
237  }
238 
239  Element<CC>* GetElement()
240  {
241  return m_element;
242  }
243 
244  virtual void OnClick(u8 button)
245  {
246  switch(button)
247  {
248  case SDL_BUTTON_LEFT:
249  m_parent->SetPrimaryElement(m_element);
250  break;
251  case SDL_BUTTON_RIGHT:
252  m_parent->SetSecondaryElement(m_element);
253  break;
254  case SDL_BUTTON_MIDDLE:
255  m_element->ToggleLowlightPhysicsColor();
256  break;
257  default: break;
258  }
259 
260  m_parent->RebuildControllers();
261  }
262 
263  virtual bool OnScroll(u8 button)
264  {
265  return false;
266  }
267 
268  private:
269  Element<CC>* m_element;
270 
271  ToolboxPanel<CC>* m_parent;
272  };
273 
274  EditingTool* m_toolPtr;
275 
276  ToolButton* m_activatedButton;
277 
278  ToolButton m_toolButtons[ELEMENT_BOX_BUTTON_COUNT];
279 
280  Element<CC>* m_primaryElement;
281 
282  Element<CC>* m_secondaryElement;
283 
284  Element<CC>* m_heldElements[ELEMENT_BOX_SIZE];
285 
286  ElementButton m_elementButtons[ELEMENT_BOX_SIZE];
287 
288  u32 m_heldElementCount;
289 
290  ParameterController<CC> *(m_controllers[TOOLBOX_MAX_CONTROLLERS]);
291  u32 m_controllerCount;
292 
293  OurSlider m_sliders[TOOLBOX_MAX_SLIDERS];
294  u32 m_sliderCount;
295 
296  OurParameterControllerBool m_checkboxes[TOOLBOX_MAX_CHECKBOXES];
297  u32 m_checkboxCount;
298 
299  NeighborSelectPanel<CC,R> m_neighborhoods[TOOLBOX_MAX_NEIGHBORHOODS];
300  u32 m_neighborhoodCount;
301 
302  u32 m_brushSize;
303 
304  enum
305  {
306  ELEMENTS_PER_ROW = 11,
307  ELEMENT_ROWS = (ELEMENT_BOX_SIZE + ELEMENTS_PER_ROW - 1) / ELEMENTS_PER_ROW,
308  NON_ELEMENT_ROWS = 3,
309  TOTAL_ROWS = ELEMENT_ROWS + NON_ELEMENT_ROWS,
310  BORDER_PADDING = 2
311  };
312 
313  void AddController(ParameterController<CC> * spc)
314  {
315  MFM_API_ASSERT_NONNULL(spc);
316 
317  if (m_controllerCount >= TOOLBOX_MAX_CONTROLLERS)
318  {
319  FAIL(OUT_OF_RESOURCES);
320  }
321 
322  u32 j = m_controllerCount++;
323 
324  m_controllers[j] = spc;
325  m_controllers[j]->SetBigText(m_bigText);
326  LOG.Debug("Inniting %s controllers", m_bigText ? "big" : "normal");
327  }
328 
329  void AddSliderController(ElementParameter<CC> * sp)
330  {
331  // Sliders for S32 parameters
332  MFM_API_ASSERT_NONNULL(sp);
333 
334  if (m_sliderCount >= TOOLBOX_MAX_SLIDERS)
335  {
336  FAIL(OUT_OF_RESOURCES);
337  }
338 
339  u32 j = m_sliderCount++;
340 
341  OurSlider& s = m_sliders[j];
342  s.SetParameter(sp);
343 
344  AddController(&s);
345  }
346 
347  void AddCheckboxController(ElementParameter<CC> * bp)
348  {
349  // Checkboxes for Bool parameters
350  MFM_API_ASSERT_NONNULL(bp);
351 
352  if (m_checkboxCount >= TOOLBOX_MAX_CHECKBOXES)
353  {
354  FAIL(OUT_OF_RESOURCES);
355  }
356 
357  u32 j = m_checkboxCount++;
358 
359  OurParameterControllerBool & cb = m_checkboxes[j];
360  cb.SetParameter(bp); // FAIL unless castable to PValueTypeBool
361 
362  AddController(&cb);
363  }
364 
365  void AddNeighborhoodController(ElementParameter<CC> * np)
366  {
367  MFM_API_ASSERT_NONNULL(np);
368 
369  if (m_neighborhoodCount >= TOOLBOX_MAX_NEIGHBORHOODS)
370  {
371  FAIL(OUT_OF_RESOURCES);
372  }
373 
374  u32 j = m_neighborhoodCount++;
375 
376  NeighborSelectPanel<CC,R>& nb = m_neighborhoods[j];
377 
378  nb.SetParameter(np);
379  nb.SetText(np->GetName());
380 
381  AddController(&nb);
382  }
383 
384  public:
385 
386  ToolboxPanel(EditingTool* toolPtr) :
387  m_bigText(false),
388  m_toolPtr(toolPtr),
389  m_activatedButton(m_toolButtons),
390  m_primaryElement(&Element_Empty<CC>::THE_INSTANCE),
391  m_secondaryElement(&Element_Empty<CC>::THE_INSTANCE),
392  m_heldElementCount(0),
393  m_controllerCount(0),
394  m_sliderCount(0),
395  m_checkboxCount(0),
396  m_brushSize(2)
397  {
398  for(u32 i = 0; i < ELEMENT_BOX_BUTTON_COUNT; i++)
399  {
400  m_toolButtons[i].SetToolPointer(m_toolPtr);
401  m_toolButtons[i].SetEditingTool((EditingTool)i);
402  }
403 
404  for(u32 i = 0; i < ELEMENT_BOX_SIZE; i++)
405  {
406  m_heldElements[i] = NULL;
407  }
408  }
409 
418  void SetBigText(bool value)
419  {
420  m_bigText = value;
421 
422  for(u32 i = 0; i < TOOLBOX_MAX_CONTROLLERS; i++)
423  {
424  if(m_controllers[i])
425  {
426  m_controllers[i]->SetBigText(value);
427  }
428  }
429  }
430 
431  void RebuildControllers()
432  {
433  /* Remove any old controllers */
434  for(u32 i = 0; i < m_controllerCount; i++)
435  {
436  Panel::Remove(m_controllers[i]);
437  }
438  m_controllerCount = 0;
439 
440  /* Set up the new controllers, if any */
441  ElementParameters<CC> & parms = m_primaryElement->GetElementParameters();
442  u32 totalParms = parms.GetParameterCount();
443 
444  m_sliderCount = 0;
445  m_checkboxCount = 0;
446  m_neighborhoodCount = 0;
447  for(u32 i = 0; i < totalParms; i++)
448  {
449  ElementParameter<CC> * parm = parms.GetParameter(i);
450  switch (parm->GetType())
451  {
452  case VD::S32:
453  AddSliderController(parm);
454  break;
455  case VD::BOOL:
456  AddCheckboxController(parm);
457  break;
458  case VD::BITS:
459  {
460  ElementParameterNeighborhood<CC,SITES>* epn =
461  dynamic_cast<ElementParameterNeighborhood<CC,SITES>*>(parm);
462  if (epn)
463  {
464  AddNeighborhoodController(epn);
465  }
466  break;
467  }
468  // ELSE FALL THROUGH
469  default:
470  FAIL(ILLEGAL_STATE);
471  }
472  }
473 
474  /* Put in the new controllers */
475  SPoint rpt(16, 6 + GetElementRenderSize() * TOTAL_ROWS);
476  for(u32 i = 0; i < m_controllerCount; i++)
477  {
478  ParameterController<CC> * c = m_controllers[i];
479  c->Init();
480  c->SetRenderPoint(rpt);
481  c->SetBigText(m_bigText);
482  Panel::Insert(c, NULL);
483  UPoint desired = c->GetDesiredSize();
484  rpt.SetY(rpt.GetY() + desired.GetY());
485  }
486 
487  Panel::SetDimensions(6 + GetElementRenderSize() * ELEMENTS_PER_ROW + BORDER_PADDING,
488  rpt.GetY() + BORDER_PADDING);
489  Panel::SetDesiredSize(6 + GetElementRenderSize() * ELEMENTS_PER_ROW + BORDER_PADDING,
490  rpt.GetY() + BORDER_PADDING);
491 
492  //debug: this->Print(STDOUT);
493 
494  // Tell ourselfs to resize (our cheeso repacking)
495  HandleResize(this->m_parent->GetDimensions());
496 
497  }
498 
499  void AddButtons()
500  {
501  Asset assets[ELEMENT_BOX_BUTTON_COUNT];
502  if(m_bigText)
503  {
504  assets[0] = ASSET_SELECTOR_ICON_BIG;
505  assets[1] = ASSET_ATOM_SELECTOR_ICON_BIG;
506  assets[2] = ASSET_PENCIL_ICON_BIG;
507  assets[3] = ASSET_BUCKET_ICON_BIG;
508  assets[4] = ASSET_ERASER_ICON_BIG;
509  assets[5] = ASSET_BRUSH_ICON_BIG;
510  assets[6] = ASSET_XRAY_ICON_BIG;
511  assets[7] = ASSET_CLONE_ICON_BIG;
512  assets[8] = ASSET_AIRBRUSH_ICON_BIG;
513  }
514  else
515  {
516  assets[0] = ASSET_SELECTOR_ICON;
517  assets[1] = ASSET_ATOM_SELECTOR_ICON;
518  assets[2] = ASSET_PENCIL_ICON;
519  assets[3] = ASSET_BUCKET_ICON;
520  assets[4] = ASSET_ERASER_ICON;
521  assets[5] = ASSET_BRUSH_ICON;
522  assets[6] = ASSET_XRAY_ICON;
523  assets[7] = ASSET_CLONE_ICON;
524  assets[8] = ASSET_AIRBRUSH_ICON;
525  }
526 
527  for(u32 i = 0; i < ELEMENT_BOX_BUTTON_COUNT; i++)
528  {
529  m_toolButtons[i].SetParent(this);
530  m_toolButtons[i].Panel::SetRenderPoint(SPoint(16 + i * GetElementRenderSize(), 3));
531  m_toolButtons[i].SetToolIcon(AssetManager::Get(assets[i]));
532  Panel::Insert(m_toolButtons + i, NULL);
533  }
534 
535  for(u32 i = 0; i < ELEMENT_BOX_SIZE; i++)
536  {
537  u32 x, y;
538 
539  x = 3 + GetElementRenderSize() * (i % ELEMENTS_PER_ROW);
540  y = 3 + GetElementRenderSize() * (3 + (i / ELEMENTS_PER_ROW));
541 
542  /* These will render correctly because ElementButtons render
543  grey when SetElement is fed NULL. */
544  m_elementButtons[i].SetElement(m_heldElements[i]);
545  m_elementButtons[i].SetParent(this);
546  m_elementButtons[i].Panel::SetDimensions(GetElementRenderSize(),
547  GetElementRenderSize());
548  m_elementButtons[i].Panel::SetRenderPoint(SPoint(x, y));
549 
550  Panel::Insert(m_elementButtons + i, NULL);
551  }
552 
553  m_primaryElement = m_heldElements[0];
554  m_secondaryElement = m_heldElements[1];
555 
556  Panel::SetDimensions(6 + GetElementRenderSize() * ELEMENTS_PER_ROW,
557  6 + GetElementRenderSize() * TOTAL_ROWS);
558  Panel::SetDesiredSize(6 + GetElementRenderSize() * ELEMENTS_PER_ROW,
559  6 + GetElementRenderSize() * TOTAL_ROWS);
560 
561  /* Set pencil tool to default */
562  m_toolButtons[2].OnClick(SDL_BUTTON_LEFT);
563  }
564 
565  void SetPrimaryElement(Element<CC>* element)
566  { m_primaryElement = element; }
567 
568  Element<CC>* GetPrimaryElement()
569  { return m_primaryElement; }
570 
571  void SetSecondaryElement(Element<CC>* element)
572  { m_secondaryElement = element; }
573 
574  u32 GetBrushSize()
575  {
576  if(!Panel::IsVisible())
577  {
578  return 0;
579  }
580 
581  switch(m_activatedButton->GetEditingTool())
582  {
583  case TOOL_SELECTOR:
584  case TOOL_ATOM_SELECTOR:
585  case TOOL_PENCIL:
586  case TOOL_BUCKET:
587  case TOOL_ERASER:
588  return 1;
589  case TOOL_BRUSH:
590  case TOOL_XRAY:
591  case TOOL_CLONE:
592  case TOOL_AIRBRUSH:
593  return m_brushSize;
594  default:
595  FAIL(ILLEGAL_STATE);
596  return 0;
597  }
598  }
599 
600  Element<CC>* GetSecondaryElement()
601  { return m_secondaryElement; }
602 
603  void RegisterElement(Element<CC>* element)
604  {
605  if(m_heldElementCount >= ELEMENT_BOX_SIZE)
606  {
607  FAIL(OUT_OF_ROOM);
608  }
609  m_heldElements[m_heldElementCount++] = element;
610  }
611 
612  void ActivateButton(ToolButton* button)
613  {
614  if(m_activatedButton)
615  {
616  m_activatedButton->SetActivated(false);
617  }
618  m_activatedButton = button;
619  button->SetActivated(true);
620  }
621 
622  EditingTool GetSelectedTool()
623  {
624  return *m_toolPtr;
625  }
626 
627  bool IsBrushableSelected()
628  {
629  return GetSelectedTool() == TOOL_BRUSH ||
630  GetSelectedTool() == TOOL_ERASER ||
631  GetSelectedTool() == TOOL_XRAY ||
632  GetSelectedTool() == TOOL_CLONE ||
633  GetSelectedTool() == TOOL_AIRBRUSH;
634  }
635 
636  virtual bool PostDragHandle(MouseButtonEvent& mbe)
637  {
638  SDL_MouseButtonEvent & event = mbe.m_event.button;
639 
640  /* Only fire on wheel 'press' to avoid double-counting */
641  if(event.type != SDL_MOUSEBUTTONDOWN)
642  {
643  return true;
644  }
645 
646  if(IsBrushableSelected())
647  {
648  switch(event.button)
649  {
650  case SDL_BUTTON_WHEELUP:
651  m_brushSize++;
652  break;
653  case SDL_BUTTON_WHEELDOWN:
654  if (m_brushSize > 0)
655  {
656  m_brushSize--;
657  }
658  break;
659  default:
660  break;
661  }
662  }
663 
664  return true;
665  }
666 
667  virtual bool PostDragHandle(MouseMotionEvent& mme)
668  {
669  /* Try to keep the grid from taking this event too */
670  return true;
671  }
672 
673  virtual void PaintComponent(Drawing& d)
674  {
675  const u32 ELEMENT_START_X = 64;
676  const u32 ELEMENT_START_Y = m_bigText ? 64 : 40;
677  const u32 ELEMENT_TOOL_SIZE = GetElementRenderSize() + 8;
678 
680  d.FillRect(0, 0, this->Panel::GetWidth(), this->Panel::GetHeight());
681 
682  d.SetFont(AssetManager::Get(GetElementRenderFont()));
683 
684  if (m_primaryElement)
685  {
686  d.SetForeground(m_primaryElement->PhysicsColor());
687  d.FillCircle(ELEMENT_START_X, ELEMENT_START_Y, ELEMENT_TOOL_SIZE,
688  ELEMENT_TOOL_SIZE, ELEMENT_TOOL_SIZE / 2);
689 
690  d.SetBackground(Drawing::BLACK);
691  d.SetForeground(Drawing::WHITE);
692  d.BlitBackedTextCentered(m_primaryElement->GetAtomicSymbol(),
693  UPoint(ELEMENT_START_X, ELEMENT_START_Y),
694  UPoint(ELEMENT_TOOL_SIZE, ELEMENT_TOOL_SIZE));
695  }
696  if (m_secondaryElement)
697  {
698  const u32 SECONDARY_X_START = ELEMENT_START_X + ELEMENT_TOOL_SIZE;
699  d.SetForeground(m_secondaryElement->PhysicsColor());
700  d.FillCircle(SECONDARY_X_START, ELEMENT_START_Y, ELEMENT_TOOL_SIZE,
701  ELEMENT_TOOL_SIZE, ELEMENT_TOOL_SIZE / 2);
702 
703  d.SetBackground(Drawing::BLACK);
704  d.SetForeground(Drawing::WHITE);
705  d.BlitBackedTextCentered(m_secondaryElement->GetAtomicSymbol(),
706  UPoint(SECONDARY_X_START, ELEMENT_START_Y),
707  UPoint(ELEMENT_TOOL_SIZE, ELEMENT_TOOL_SIZE));
708  }
709 
710  if(IsBrushableSelected())
711  {
712  d.SetBackground(Drawing::BLACK);
713  d.SetForeground(Drawing::WHITE);
714 
715  char brushSizeArray[64];
716 
717  snprintf(brushSizeArray, 64, "%d", m_brushSize);
718 
719  const SPoint brushPos = m_toolButtons[TOOL_AIRBRUSH].Panel::GetRenderPoint();
720  UPoint pos(brushPos.GetX() + GetElementRenderSize(), brushPos.GetY());
721  d.BlitBackedText(brushSizeArray, pos, UPoint(128, 128));
722  }
723 
724  }
725  };
726 }
727 
728 #endif /* TOOLBOXPANEL_H */
u32 GetBackground() const
Definition: Panel.h:212
void FillCircle(int x, int y, int w, int h, int radius) const
Definition: Drawing.cpp:135
void BlitBackedTextCentered(const char *message, UPoint loc, UPoint size)
Definition: Drawing.cpp:220
Definition: Element_Empty.h:41
u32 SetBorder(const u32 color)
Definition: Panel.h:238
Definition: Parameter.h:43
u32 SetForeground(const u32 color)
Definition: Drawing.h:188
Definition: ParameterControllerBool.h:42
void ToggleLowlightPhysicsColor()
Definition: Element.h:458
Definition: Parameter.h:628
Definition: AbstractButton.h:44
u32 SetForeground(const u32 color)
Definition: Panel.h:256
virtual void HandleResize(const UPoint &parentSize)
Definition: Panel.cpp:265
Definition: MovablePanel.h:34
void SetEnabled(bool isEnabled)
Definition: AbstractButton.h:200
const char * GetZString()
Definition: OverflowableCharBufferByteSink.h:143
T GetY() const
Definition: Point.tcc:40
Definition: ParameterController.h:40
Definition: Parameter.h:593
void BlitBackedText(const char *message, UPoint loc, UPoint size)
Definition: Drawing.cpp:233
virtual void PaintComponent(Drawing &d)
Definition: ToolboxPanel.h:673
u32 SetBackground(const u32 color)
Definition: Drawing.h:170
u32 GetForeground() const
Definition: Panel.h:248
void Debug(const char *format,...)
Definition: Logger.h:301
Definition: Slider.h:40
void SetY(T y)
Definition: Point.tcc:170
const char * GetAtomicSymbol() const
Definition: Element.h:305
void FillRect(int x, int y, int w, int h) const
Definition: Drawing.cpp:115
#define EVENT_WINDOW_SITES(radius)
Definition: MDist.h:46
Definition: ToolboxPanel.h:46
const char * GetName() const
Definition: Parameter.h:352
void SetBigText(bool value)
Definition: ToolboxPanel.h:418
TTF_Font * SetFont(TTF_Font *newFont)
Definition: Drawing.h:209
Definition: Atom.h:43
Definition: NeighborSelectPanel.h:37
Definition: Drawing.h:44
u32 SetBackground(const u32 color)
Definition: Panel.h:220
T GetX() const
Definition: Point.tcc:34