diff --git a/docs/abstract__network_8cpp.xml b/docs/abstract__network_8cpp.xml new file mode 100644 index 0000000..8972fee --- /dev/null +++ b/docs/abstract__network_8cpp.xml @@ -0,0 +1,97 @@ + + + + abstract_network.cpp + abstract_network.hpp + format.hpp + QByteArray + QString + string + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + sk::anonymous_namespace{abstract_network.cpp} + + + + + + + diff --git a/docs/abstract__network_8cpp_source.html b/docs/abstract__network_8cpp_source.html deleted file mode 100644 index 63d8228..0000000 --- a/docs/abstract__network_8cpp_source.html +++ /dev/null @@ -1,179 +0,0 @@ - - - - - - - -Skribble: src/abstract_network.cpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
abstract_network.cpp
-
-
-
1 #include "abstract_network.hpp"
-
2 #include "format.hpp"
-
3 
-
4 #include <QByteArray>
-
5 #include <QString>
-
6 
-
7 #include <string>
-
8 
-
9 namespace sk {
-
10 
-
11 namespace {
-
12 
-
13 auto handleWrite(QTcpSocket& socket) -> void
-
14 {
-
15  if(!socket.waitForBytesWritten()) {
-
16  qDebug() << "Couldn't send message!";
-
17  }
-
18 }
-
19 
-
20 } // namespace
-
21 
-
22 AbstractNetwork::AbstractNetwork(QObject* parent)
-
23  : QObject{ parent }
-
24 {
-
25 }
-
26 
-
27 auto AbstractNetwork::sendDrawAt(QPoint const& pos) -> void
-
28 {
-
29  if(auto* socket = this->getSocket(); socket != nullptr) {
-
30  std::string msg = sk::format("d %1 %2", pos.x(), pos.y());
-
31  socket->write(QByteArray::fromStdString(msg));
-
32  handleWrite(*socket);
-
33  }
-
34 }
-
35 
-
36 auto AbstractNetwork::sendMouseReleased() -> void
-
37 {
-
38  if(auto* socket = this->getSocket(); socket != nullptr) {
-
39  socket->write("m");
-
40  handleWrite(*socket);
-
41  }
-
42 }
-
43 
-
44 auto AbstractNetwork::sendUndo() -> void
-
45 {
-
46  if(auto* socket = this->getSocket(); socket != nullptr) {
-
47  socket->write("u");
-
48  handleWrite(*socket);
-
49  }
-
50 }
-
51 
-
52 auto AbstractNetwork::sendRedo() -> void
-
53 {
-
54  if(auto* socket = this->getSocket(); socket != nullptr) {
-
55  socket->write("r");
-
56  handleWrite(*socket);
-
57  }
-
58 }
-
59 
-
60 auto AbstractNetwork::sendChangeColor(QColor const& color) -> void
-
61 {
-
62  if(auto* socket = this->getSocket(); socket != nullptr) {
-
63  std::string msg = sk::format("c %1 %2 %3 %4",
-
64  color.red(),
-
65  color.green(),
-
66  color.blue(),
-
67  color.alpha());
-
68  socket->write(QByteArray::fromStdString(msg));
-
69  handleWrite(*socket);
-
70  }
-
71 }
-
72 
-
73 auto AbstractNetwork::sendChangeWidth(int const width) -> void
-
74 {
-
75  if(auto* socket = this->getSocket(); socket != nullptr) {
-
76  std::string msg = sk::format("w %1", width);
-
77  socket->write(QByteArray::fromStdString(msg));
-
78  handleWrite(*socket);
-
79  }
-
80 }
-
81 
-
82 auto AbstractNetwork::sendToBrush() -> void
-
83 {
-
84  if(auto* socket = this->getSocket(); socket != nullptr) {
-
85  socket->write("b");
-
86  handleWrite(*socket);
-
87  }
-
88 }
-
89 
-
90 auto AbstractNetwork::sendToPen() -> void
-
91 {
-
92  if(auto* socket = this->getSocket(); socket != nullptr) {
-
93  socket->write("p");
-
94  handleWrite(*socket);
-
95  }
-
96 }
-
97 
-
98 } // namespace sk
-
- - - - diff --git a/docs/abstract__network_8hpp.xml b/docs/abstract__network_8hpp.xml new file mode 100644 index 0000000..c42f669 --- /dev/null +++ b/docs/abstract__network_8hpp.xml @@ -0,0 +1,144 @@ + + + + abstract_network.hpp + QColor + QObject + QPoint + QString + QTcpSocket + src/abstract_network.cpp + src/canvas.hpp + src/client.hpp + src/dummy_network.hpp + src/server.hpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::AbstractNetwork + sk + + + + + + + diff --git a/docs/abstract__network_8hpp_source.html b/docs/abstract__network_8hpp_source.html deleted file mode 100644 index 64bca14..0000000 --- a/docs/abstract__network_8hpp_source.html +++ /dev/null @@ -1,125 +0,0 @@ - - - - - - - -Skribble: src/abstract_network.hpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
abstract_network.hpp
-
-
-
1 #ifndef ABSTRACT_NETWORK_HPP
-
2 #define ABSTRACT_NETWORK_HPP
-
3 #pragma once
-
4 
-
5 #include <QColor>
-
6 #include <QObject>
-
7 #include <QPoint>
-
8 #include <QString>
-
9 #include <QTcpSocket>
-
10 
-
11 namespace sk {
-
12 
-
13 class AbstractNetwork : public QObject
-
14 {
-
15  Q_OBJECT
-
16 
-
17 public:
-
18  explicit AbstractNetwork(QObject* parent = nullptr);
-
19  AbstractNetwork(AbstractNetwork const&) = delete;
-
20  AbstractNetwork(AbstractNetwork&&) noexcept = delete;
-
21  ~AbstractNetwork() noexcept override = default;
-
22 
-
23  auto operator=(AbstractNetwork const&) -> AbstractNetwork& = delete;
-
24  auto operator=(AbstractNetwork&&) noexcept -> AbstractNetwork& = delete;
-
25 
-
26  virtual auto getSocket() -> QTcpSocket* = 0;
-
27 
-
28  auto sendDrawAt(QPoint const& pos) -> void;
-
29  auto sendMouseReleased() -> void;
-
30  auto sendUndo() -> void;
-
31  auto sendRedo() -> void;
-
32  auto sendChangeColor(QColor const& color) -> void;
-
33  auto sendChangeWidth(int const width) -> void;
-
34  auto sendToPen() -> void;
-
35  auto sendToBrush() -> void;
-
36 
-
37 signals:
-
38  void receivedMessage(QString const& msg);
-
39 };
-
40 
-
41 } // namespace sk
-
42 
-
43 #endif // !ABSTRACT_NETWORK_HPP
-
-
sk::AbstractNetwork
Definition: abstract_network.hpp:13
- - - - diff --git a/docs/annotated.html b/docs/annotated.html index 53f06ec..aff00b4 100644 --- a/docs/annotated.html +++ b/docs/annotated.html @@ -1,106 +1,141 @@ - - + + - - - - -Skribble: Class List - - - - - - - + + Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

Classes

+ + +
+
+
+
+ - - - - - - - -
- -
-
- - -
- -
- -
-
-
Class List
-
-
-
Here are the classes, structs, unions and interfaces with brief descriptions:
-
[detail level 123]
- - - - - - - - - - - - - - - - - - - - - - - - - -
 Nsk
 Nimpl
 CCachedLayers
 CAbstractNetwork
 CBrushMode
 CCachedResource
 CCanvas
 CClient
 CDrawHistory
 CDrawMode
 CDummyNetwork
 CFCachedResource
 CFResTraits
 CNetworkFactory
 CPenMode
 CResourceTraits
 CServer
 CDummy
 CFTrait2
 CFTraits
 CFTraits3
 CTestBase
 CProxy
 CTrait2
 CTraits3
-
-
- - + + + diff --git a/docs/bc_s.png b/docs/bc_s.png deleted file mode 100644 index 224b29a..0000000 Binary files a/docs/bc_s.png and /dev/null differ diff --git a/docs/bdwn.png b/docs/bdwn.png deleted file mode 100644 index 940a0b9..0000000 Binary files a/docs/bdwn.png and /dev/null differ diff --git a/docs/cached__resource_8hpp.xml b/docs/cached__resource_8hpp.xml new file mode 100644 index 0000000..907238c --- /dev/null +++ b/docs/cached__resource_8hpp.xml @@ -0,0 +1,100 @@ + + + + cached_resource.hpp + algorithm + deque + functional + iterator + limits + utility + src/draw_history.hpp + tests/cached_resource_test.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::ResourceTraits + sk::CachedResource + sk + + + + + + + diff --git a/docs/cached__resource_8hpp_source.html b/docs/cached__resource_8hpp_source.html deleted file mode 100644 index c284429..0000000 --- a/docs/cached__resource_8hpp_source.html +++ /dev/null @@ -1,362 +0,0 @@ - - - - - - - -Skribble: src/cached_resource.hpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
cached_resource.hpp
-
-
-
1 #ifndef CACHED_RESOURCE_HPP
-
2 #define CACHED_RESOURCE_HPP
-
3 #pragma once
-
4 
-
5 #include <algorithm>
-
6 #include <deque>
-
7 #include <functional>
-
8 #include <iterator>
-
9 #include <limits>
-
10 #include <utility>
-
11 
-
12 namespace sk {
-
13 
-
14 template<typename T>
- -
16 {
-
17  using ContainerType = std::deque<T>;
-
18  static constexpr int cacheGap = 5;
-
19  static constexpr int maxCount = 20;
-
20 };
-
21 
-
22 template<typename T, typename Traits = ResourceTraits<T>>
- -
24 {
-
25 private:
-
26  using ContainerType = typename Traits::ContainerType;
-
27  using Iterator = typename ContainerType::iterator;
-
28 
-
29  static constexpr auto m_cacheGap = Traits::cacheGap;
-
30  static constexpr auto m_maxCount = Traits::maxCount;
-
31 
-
32  static_assert(m_cacheGap > 0, "The cache gap should be bigger than 0!");
-
33  static_assert(m_maxCount > 1, "The cache limit should be bigger than 1!");
-
34 
-
35  ContainerType m_data{};
-
36  ContainerType m_cache{};
-
37 
-
38  Iterator m_dataLimit{};
-
39  Iterator m_cacheLimit{};
-
40 
-
41  bool m_underUndo{ false };
-
42 
-
43  using Function = void (*)(T&, T&);
-
44  Function m_function;
-
45 
-
46  [[nodiscard]] auto plus(Iterator it, int const count) const
-
47  {
-
48  std::advance(it, count);
-
49  return it;
-
50  }
-
51 
-
52  [[nodiscard]] auto getNumCaches() noexcept -> int
-
53  {
-
54  return m_cache.empty() ? 0
-
55  : static_cast<int>(std::distance(m_cache.begin(),
-
56  m_cacheLimit));
-
57  }
-
58 
-
59  [[nodiscard]] inline auto noCaches() noexcept -> bool
-
60  {
-
61  return this->getNumCaches() <= 0;
-
62  }
-
63 
-
64  [[nodiscard]] auto getIteratorPastCache() noexcept -> Iterator
-
65  {
-
66  auto it = m_data.begin();
-
67  auto const offset = this->getNumCaches() * m_cacheGap;
-
68  auto const max =
-
69  static_cast<int>(std::distance(m_data.begin(), m_dataLimit));
-
70 
-
71  std::advance(it, std::min(max, offset));
-
72 
-
73  return it;
-
74  }
-
75 
-
76  auto clearUndo() -> void
-
77  {
-
78  auto const dist = std::distance(m_dataLimit, m_data.end());
-
79 
-
80  for(int i = 0; i < dist; ++i) {
-
81  m_data.pop_back();
-
82  }
-
83  m_dataLimit = m_data.end();
-
84 
-
85  if(this->noCaches()) {
-
86  m_cache.clear();
-
87  }
-
88  else {
-
89  auto const cacheDist = std::distance(m_cacheLimit, m_cache.end());
-
90 
-
91  for(int i = 0; i < cacheDist; ++i) {
-
92  m_cache.pop_back();
-
93  }
-
94  m_cacheLimit = m_cache.end();
-
95  }
-
96 
-
97  m_underUndo = false;
-
98  }
-
99 
-
100 public:
-
101  CachedResource() = default;
-
102  explicit CachedResource(Function f)
-
103  : m_function{ f }
-
104  {
-
105  }
-
106  CachedResource(CachedResource const&) = default;
-
107  CachedResource(CachedResource&&) noexcept = default;
-
108  ~CachedResource() noexcept = default;
-
109 
-
110  auto operator=(CachedResource const&) -> CachedResource& = default;
-
111  auto operator=(CachedResource&&) noexcept -> CachedResource& = default;
-
112 
-
113  template<typename... Ts>
-
114  auto emplaceBack(Ts&&... ts) -> T&
-
115  {
-
116  if(m_underUndo) {
-
117  this->clearUndo();
-
118 
-
119  if(m_data.size() % m_cacheGap == 0) {
-
120  goto skip_cache;
-
121  }
-
122  }
-
123 
-
124  if(m_data.size() == m_cacheGap) {
-
125  m_cache.emplace_back(*(m_data.begin()));
-
126  auto begin = this->plus(m_data.begin(), 1);
-
127 
-
128  for(auto it = begin; it != m_data.end(); ++it) {
-
129  m_function(m_cache.back(), *it);
-
130  }
-
131 
-
132  m_cacheLimit = m_cache.end();
-
133  }
-
134  else if(!m_data.empty() && m_data.size() % m_cacheGap == 0) {
-
135  auto const begin = this->getIteratorPastCache();
-
136  m_cache.emplace_back(m_cache.back());
-
137 
-
138  for(auto it = begin; it != m_data.end(); ++it) {
-
139  m_function(m_cache.back(), *it);
-
140  }
-
141 
-
142  m_cacheLimit = m_cache.end();
-
143  }
-
144  if(m_cache.size() > m_maxCount) {
-
145  m_function(m_cache.front(),
-
146  *(this->plus(m_data.begin(), m_cacheGap)));
-
147 
-
148  for(int i = 0; i <= m_cacheGap; ++i) {
-
149  m_data.pop_front();
-
150  }
-
151 
-
152  m_data.emplace_front(m_cache.front());
-
153  m_cache.pop_front();
-
154  }
-
155 
-
156  skip_cache:
-
157  m_data.emplace_back(std::forward<Ts>(ts)...);
-
158  m_dataLimit = m_data.end();
-
159  return m_data.back();
-
160  }
-
161 
-
162  [[nodiscard]] auto getLastCache() noexcept -> T*
-
163  {
-
164  if(this->noCaches()) {
-
165  return nullptr;
-
166  }
-
167 
-
168  return &(*(this->plus(m_cacheLimit, -1)));
-
169  }
-
170 
-
171  auto reduceTo(T& value) -> void
-
172  {
-
173  if(this->noCaches()) {
-
174  for(auto it = m_data.begin(); it != m_dataLimit; ++it) {
-
175  m_function(value, *it);
-
176  }
-
177  return;
-
178  }
-
179 
-
180  m_function(value, *(this->getLastCache()));
-
181  auto begin = this->getIteratorPastCache();
-
182 
-
183  for(auto it = begin; it != m_dataLimit; ++it) {
-
184  m_function(value, *it);
-
185  }
-
186  }
-
187 
-
188  template<typename F2>
-
189  auto reduceTo(F2 f) -> void
-
190  {
-
191  if(this->noCaches()) {
-
192  for(auto it = m_data.begin(); it != m_dataLimit; ++it) {
-
193  f(*it);
-
194  }
-
195  return;
-
196  }
-
197 
-
198  f(*(this->getLastCache()));
-
199  auto begin = this->getIteratorPastCache();
-
200 
-
201  for(auto it = begin; it != m_dataLimit; ++it) {
-
202  f(*it);
-
203  }
-
204  }
-
205 
-
206  [[nodiscard]] auto getLast() noexcept -> T&
-
207  {
-
208  return *(this->plus(m_dataLimit, -1));
-
209  }
-
210  [[nodiscard]] auto getLast() const noexcept -> T const&
-
211  {
-
212  return *(this->plus(m_dataLimit, -1));
-
213  }
-
214 
-
215  [[nodiscard]] constexpr auto underUndo() const noexcept -> bool
-
216  {
-
217  return m_underUndo;
-
218  }
-
219 
-
224  [[nodiscard]] auto undo() -> bool
-
225  {
-
226  m_underUndo = true;
-
227 
-
228  auto const distance = std::distance(m_data.begin(), m_dataLimit);
-
229  if(distance == 0) {
-
230  return false;
-
231  }
-
232 
-
233  --m_dataLimit;
-
234 
-
235  bool const onCache = ((distance % m_cacheGap) == 0);
-
236  if(!this->noCaches() && onCache) {
-
237  --m_cacheLimit;
-
238  }
-
239 
-
240  return true;
-
241  }
-
242 
-
247  [[nodiscard]] auto redo() -> bool
-
248  {
-
249  if(!m_underUndo) {
-
250  return false;
-
251  }
-
252  bool val = true;
-
253  if(this->plus(m_dataLimit, 1) == m_data.end()) {
-
254  m_underUndo = false;
-
255  val = false;
-
256  }
-
257 
-
258  ++m_dataLimit;
-
259 
-
260  auto const distance = std::distance(m_data.begin(), m_dataLimit);
-
261 
-
262  if(!m_cache.empty()) {
-
263  auto const availableCaches =
-
264  std::distance(m_cacheLimit, m_cache.end()) > 0;
-
265  if(availableCaches && distance % m_cacheGap == 0) {
-
266  ++m_cacheLimit;
-
267  }
-
268  }
-
269 
-
270  return val;
-
271  }
-
272 
-
273  [[nodiscard]] auto getUnderlying() noexcept -> ContainerType&
-
274  {
-
275  return m_data;
-
276  }
-
277  [[nodiscard]] auto getUnderlying() const noexcept -> ContainerType const&
-
278  {
-
279  return m_data;
-
280  }
-
281 };
-
282 
-
283 } // namespace sk
-
284 
-
285 #endif // !CACHED_SEQ_HPP
-
-
-
auto undo() -> bool
-
-
auto redo() -> bool
- - - - diff --git a/docs/cached__resource__test_8cpp.xml b/docs/cached__resource__test_8cpp.xml new file mode 100644 index 0000000..5f00444 --- /dev/null +++ b/docs/cached__resource__test_8cpp.xml @@ -0,0 +1,190 @@ + + + + cached_resource_test.cpp + test.hpp + cached_resource.hpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + FTraits + Trait2 + Traits3 + anonymous_namespace{cached_resource_test.cpp} + + + MAIN_EXECUTABLE + + + + + + + + + + + + + TEST + ("[CachedResource] Undo/Redo") + TEST + + " Undo/Redo" + [CachedResource] + + + + + + + + + + + + TEST + ("[CachedResource] emplaceBack") + TEST + + " emplaceBack" + [CachedResource] + + + + + + + + + + + + TEST + ("[CachedResource] maxCount") + TEST + + " maxCount" + [CachedResource] + + + + + + + + + + + + + + + + + diff --git a/docs/cached__resource__test_8cpp_source.html b/docs/cached__resource__test_8cpp_source.html deleted file mode 100644 index 4040270..0000000 --- a/docs/cached__resource__test_8cpp_source.html +++ /dev/null @@ -1,360 +0,0 @@ - - - - - - - -Skribble: tests/cached_resource_test.cpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
cached_resource_test.cpp
-
-
-
1 #define MAIN_EXECUTABLE
-
2 #include "test.hpp"
-
3 
-
4 #include "cached_resource.hpp"
-
5 
-
6 namespace {
-
7 
-
8 auto adder = [](int& dest, int& src) -> void { dest += src; };
-
9 
-
10 }
-
11 
-
12 template<typename T>
-
13 struct FTraits
-
14 {
-
15  using ContainerType = std::deque<T>;
-
16  static constexpr int cacheGap = 3;
-
17  static constexpr int maxCount = sk::ResourceTraits<T>::maxCount;
-
18 };
-
19 
-
20 TEST("[CachedResource] Undo/Redo")
-
21 {
- -
23 
-
24  for(int i = 0; i < 10; ++i) {
-
25  res.emplaceBack(i + 1);
-
26  }
-
27 
-
28  int sum{ 0 };
-
29  res.reduceTo(sum);
-
30 
-
31  ASSERT(sum == 55);
-
32  ASSERT(res.getLast() == 10);
-
33  ASSERT((*res.getLastCache()) == 45);
-
34 
-
35  bool undo = res.undo();
-
36 
-
37  ASSERT(undo == true);
-
38  ASSERT((*res.getLastCache()) == 45);
-
39  ASSERT(res.underUndo());
-
40 
-
41  undo = res.undo();
-
42 
-
43  ASSERT(undo == true);
-
44  ASSERT((*res.getLastCache()) == 21);
-
45  ASSERT(res.underUndo());
-
46 
-
47  bool redo = res.redo();
-
48 
-
49  ASSERT(redo == true);
-
50  ASSERT(*(res.getLastCache()) == 45);
-
51  ASSERT(res.underUndo());
-
52 
-
53  redo = res.redo();
-
54 
-
55  ASSERT(redo == false);
-
56  ASSERT(*(res.getLastCache()) == 45);
-
57  ASSERT(res.underUndo() == false);
-
58 
-
59  for(int i = 0; i < 9; ++i) {
-
60  undo = res.undo();
-
61  ASSERT(res.underUndo());
-
62  }
-
63 
-
64  ASSERT(undo == true);
-
65  ASSERT(res.getLastCache() == nullptr);
-
66  ASSERT(res.getLast() == 1);
-
67  ASSERT(res.underUndo());
-
68 
-
69  undo = res.undo();
-
70 
-
71  ASSERT(undo == true);
-
72  ASSERT(res.underUndo());
-
73 
-
74  sum = 0;
-
75  res.reduceTo(sum);
-
76 
-
77  ASSERT(sum == 0);
-
78 
-
79  undo = res.undo();
-
80 
-
81  ASSERT(undo == false);
-
82  ASSERT(res.underUndo());
-
83 
-
84  for(int i = 0; i < 9; ++i) {
-
85  redo = res.redo();
-
86  }
-
87 
-
88  ASSERT(redo == true);
-
89  ASSERT(res.underUndo());
-
90 
-
91  redo = res.redo();
-
92 
-
93  ASSERT(redo == false);
-
94  ASSERT(res.underUndo() == false);
-
95 }
-
96 
-
97 template<typename T>
-
98 struct Trait2
-
99 {
-
100  using ContainerType = std::deque<T>;
-
101  static constexpr int cacheGap = 5;
-
102  static constexpr int maxCount = sk::ResourceTraits<T>::maxCount;
-
103 };
-
104 
-
105 TEST("[CachedResource] emplaceBack")
-
106 {
- -
108  bool undo{ true };
-
109  bool redo{ true };
-
110 
-
111  for(int i = 0; i < Trait2<int>::cacheGap * 2; ++i) {
-
112  res.emplaceBack(i + 1);
-
113  ASSERT(res.underUndo() == false);
-
114  }
-
115 
-
116  ASSERT(res.getLast() == 10);
-
117  ASSERT(*(res.getLastCache()) == 15);
-
118 
-
119  for(int i = 0; i < Trait2<int>::cacheGap; ++i) {
-
120  undo = res.undo();
-
121  ASSERT(undo == true);
-
122  ASSERT(res.underUndo() == true);
-
123  }
-
124 
-
125  ASSERT(res.getLastCache() == nullptr);
-
126  ASSERT(res.getLast() == 5);
-
127 
-
128  undo = res.undo();
-
129 
-
130  ASSERT(undo == true);
-
131  ASSERT(res.getLastCache() == nullptr);
-
132 
-
133  redo = res.redo();
-
134 
-
135  ASSERT(redo == true);
-
136  ASSERT(res.getLastCache() != nullptr);
-
137  ASSERT(*(res.getLastCache()) == 15);
-
138  ASSERT(res.underUndo() == true);
-
139 
-
140  res.emplaceBack(100);
-
141 
-
142  ASSERT(res.underUndo() == false);
-
143  ASSERT(res.redo() == false);
-
144  ASSERT(res.getLastCache() != nullptr);
-
145  ASSERT(*(res.getLastCache()) == 15);
-
146  ASSERT(res.getLast() == 100);
-
147 
-
148  int sum{ 0 };
-
149  res.reduceTo(sum);
-
150 
-
151  ASSERT(sum == 115);
-
152 }
-
153 
-
154 template<typename T>
-
155 struct Traits3
-
156 {
-
157  using ContainerType = std::deque<T>;
-
158  static constexpr int maxCount = 2;
-
159  static constexpr int cacheGap = 3;
-
160 };
-
161 
-
162 TEST("[CachedResource] maxCount")
-
163 {
- -
165 
-
166  for(int i = 0; i < 10; ++i) {
-
167  res.emplaceBack(i + 1);
-
168  }
-
169 
-
170  ASSERT(res.getLastCache() != nullptr);
-
171  ASSERT(*(res.getLastCache()) == 45);
-
172  ASSERT(res.getUnderlying().size() == 7);
-
173  ASSERT(res.getUnderlying().front() == 10);
-
174 
-
175  res.emplaceBack(11);
-
176  res.emplaceBack(12);
-
177 
-
178  ASSERT(res.getLastCache() != nullptr);
-
179  ASSERT(*(res.getLastCache()) == 45);
-
180 
-
181  res.emplaceBack(13);
-
182 
-
183  ASSERT(res.getLastCache() != nullptr);
-
184  ASSERT(*(res.getLastCache()) == 78);
-
185 
-
186  bool undo{ true };
-
187 
-
188  for(int i = 0; i < 3; ++i) {
-
189  undo = res.undo();
-
190  ASSERT(undo == true);
-
191  ASSERT(res.underUndo() == true);
-
192  }
-
193 
-
194  ASSERT(res.getLastCache() != nullptr);
-
195  ASSERT(*(res.getLastCache()) == 45);
-
196 
-
197  int sum{ 0 };
-
198  res.reduceTo(sum);
-
199 
-
200  ASSERT(sum == 55);
-
201 
-
202  undo = res.undo();
-
203 
-
204  ASSERT(undo == true);
-
205 
-
206  sum = 0;
-
207  res.reduceTo(sum);
-
208 
-
209  ASSERT(sum == 45);
-
210  ASSERT(res.getLastCache() != nullptr);
-
211  ASSERT(*(res.getLastCache()) == 45);
-
212 
-
213  bool redo{ true };
-
214 
-
215  for(int i = 0; i < 3; ++i) {
-
216  redo = res.redo();
-
217  ASSERT(res.underUndo() == true);
-
218  ASSERT(redo == true);
-
219  }
-
220 
-
221  redo = res.redo();
-
222 
-
223  ASSERT(redo == false);
-
224  ASSERT(res.getLastCache() != nullptr);
-
225  ASSERT(*(res.getLastCache()) == 78);
-
226 
-
227  sum = 0;
-
228  res.reduceTo(sum);
-
229 
-
230  ASSERT(sum == 91);
-
231  ASSERT(res.getUnderlying().front() == 28);
-
232  ASSERT(res.getUnderlying().size() == 7);
-
233 
-
234  for(int i = 0; i < 7; ++i) {
-
235  undo = res.undo();
-
236  ASSERT(res.underUndo() == true);
-
237  ASSERT(undo == true);
-
238  }
-
239 
-
240  undo = res.undo();
-
241 
-
242  ASSERT(undo == false);
-
243 
-
244  redo = res.redo();
-
245  sum = 0;
-
246  res.reduceTo(sum);
-
247 
-
248  ASSERT(redo == true);
-
249  ASSERT(res.getLastCache() == nullptr);
-
250  ASSERT(res.underUndo() == true);
-
251  ASSERT(sum == 28);
-
252 
-
253  static_cast<void>(res.redo());
-
254  static_cast<void>(res.redo());
-
255  sum = 0;
-
256  res.reduceTo(sum);
-
257 
-
258  ASSERT(res.getLastCache() != nullptr);
-
259  ASSERT(*(res.getLastCache()) == 45);
-
260  ASSERT(res.underUndo() == true);
-
261  ASSERT(sum == 45);
-
262 
-
263  res.emplaceBack(10);
-
264  sum = 0;
-
265  res.reduceTo(sum);
-
266 
-
267  ASSERT(res.underUndo() == false);
-
268  ASSERT(sum == 55);
-
269 
-
270  sum = 0;
-
271  res.reduceTo(sum);
-
272 
-
273  ASSERT(sum == 55);
-
274 }
-
-
-
-
-
-
- - - - diff --git a/docs/canvas_8cpp.xml b/docs/canvas_8cpp.xml new file mode 100644 index 0000000..dd79256 --- /dev/null +++ b/docs/canvas_8cpp.xml @@ -0,0 +1,323 @@ + + + + canvas.cpp + canvas.hpp + client.hpp + dummy_network.hpp + message_parser.hpp + network_config.hpp + network_factory.hpp + server.hpp + cstddef + iostream + utility + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + + + + + + + diff --git a/docs/canvas_8cpp_source.html b/docs/canvas_8cpp_source.html deleted file mode 100644 index 060a5b8..0000000 --- a/docs/canvas_8cpp_source.html +++ /dev/null @@ -1,211 +0,0 @@ - - - - - - - -Skribble: src/canvas.cpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
canvas.cpp
-
-
-
1 #include "canvas.hpp"
-
2 #include "client.hpp"
-
3 #include "dummy_network.hpp"
-
4 #include "message_parser.hpp"
-
5 #include "network_config.hpp"
-
6 #include "network_factory.hpp"
-
7 #include "server.hpp"
-
8 
-
9 #include <cstddef>
-
10 #include <iostream>
-
11 #include <utility>
-
12 
-
13 namespace sk {
-
14 
-
15 Canvas::Canvas(QQuickPaintedItem* parent)
-
16  : QQuickPaintedItem{ parent }
-
17 {
-
18  m_drawMode = makeDrawMode(PenMode{});
-
19  m_network = NetworkFactory::create(sk::networkMode);
-
20  connect(m_network.get(),
-
21  &AbstractNetwork::receivedMessage,
-
22  this,
-
23  &Canvas::onReceivedMessage);
-
24 }
-
25 
-
26 auto Canvas::mousePositionChanged(QPoint const& pos) -> void
-
27 {
-
28  m_history.drawAt(pos, *m_drawMode, false);
-
29  m_network->sendDrawAt(pos);
-
30  this->update();
-
31 }
-
32 
-
33 auto Canvas::paint(QPainter* painter) -> void
-
34 {
-
35  painter->setRenderHints(QPainter::Antialiasing |
-
36  QPainter::SmoothPixmapTransform);
-
37  m_history.paintCanvas(painter);
-
38 }
-
39 
-
40 auto Canvas::mouseReleased() -> void
-
41 {
-
42  m_history.pushNewLayer(false);
-
43  m_network->sendMouseReleased();
-
44 }
-
45 
-
46 auto Canvas::undo() -> void
-
47 {
-
48  m_history.undo(false);
-
49  m_network->sendUndo();
-
50  this->update();
-
51 }
-
52 
-
53 auto Canvas::redo() -> void
-
54 {
-
55  m_history.redo(false);
-
56  m_network->sendRedo();
-
57  this->update();
-
58 }
-
59 
-
60 auto Canvas::onReceivedMessage(QString const& msg) -> void
-
61 {
-
62  auto const& [op, a, b, c, d] = sk::parse(msg.toStdString());
-
63 
-
64  switch(op) {
-
65  case sk::Operation::DRAW_AT: {
-
66  auto const prevColor = m_drawMode->getColor();
-
67  int const prevWidth = m_drawMode->getWidth();
-
68 
-
69  m_drawMode->setColor(m_foreignColor);
-
70  m_drawMode->setWidth(m_foreignWidth);
-
71 
-
72  m_history.drawAt({ a, b }, *m_drawMode, true);
-
73 
-
74  m_drawMode->setColor(prevColor);
-
75  m_drawMode->setWidth(prevWidth);
-
76 
-
77  this->update();
-
78  return;
-
79  }
-
80  case sk::Operation::MOUSE_RELEASED: {
-
81  m_history.pushNewLayer(true);
-
82  return;
-
83  }
-
84  case sk::Operation::CHANGE_COLOR: {
-
85  m_foreignColor = QColor{ a, b, c, d };
-
86  return;
-
87  }
-
88  case sk::Operation::CHANGE_WIDTH: {
-
89  m_foreignWidth = a;
-
90  return;
-
91  }
-
92  case sk::Operation::UNDO: {
-
93  m_history.undo(true);
-
94  this->update();
-
95  return;
-
96  }
-
97  case sk::Operation::REDO: {
-
98  m_history.redo(true);
-
99  this->update();
-
100  return;
-
101  }
-
102  case sk::Operation::TO_PEN:
-
103  case sk::Operation::TO_BRUSH: {
-
104  qDebug() << "[Canvas] Received tool change!";
-
105  return;
-
106  }
-
107  case sk::Operation::NONE: {
-
108  qDebug() << "[Canvas] Received empty string, shouldn't happen!";
-
109  return;
-
110  }
-
111  default: {
-
112  qDebug() << "[Canvas] Case not handled when receiving message!";
-
113  return;
-
114  }
-
115  }
-
116 }
-
117 
-
118 auto Canvas::changeColor(QColor const& color) -> void
-
119 {
-
120  m_drawMode->setColor(color);
-
121  m_network->sendChangeColor(color);
-
122 }
-
123 
-
124 auto Canvas::changeWidth(const int width) -> void
-
125 {
-
126  m_drawMode->setWidth(width);
-
127  m_network->sendChangeWidth(width);
-
128 }
-
129 
-
130 } // namespace sk
-
- - - - diff --git a/docs/canvas_8hpp.xml b/docs/canvas_8hpp.xml new file mode 100644 index 0000000..68622f0 --- /dev/null +++ b/docs/canvas_8hpp.xml @@ -0,0 +1,257 @@ + + + + canvas.hpp + abstract_network.hpp + draw_history.hpp + draw_mode.hpp + QPainter + QPoint + QQuickPaintedItem + QTcpServer + QTcpSocket + memory + vector + src/canvas.cpp + src/main.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::Canvas + sk + + + + + + + diff --git a/docs/canvas_8hpp_source.html b/docs/canvas_8hpp_source.html deleted file mode 100644 index 332ae5d..0000000 --- a/docs/canvas_8hpp_source.html +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - - -Skribble: src/canvas.hpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
canvas.hpp
-
-
-
1 #ifndef CANVAS_HPP
-
2 #define CANVAS_HPP
-
3 #pragma once
-
4 
-
5 #include "abstract_network.hpp"
-
6 #include "draw_history.hpp"
-
7 #include "draw_mode.hpp"
-
8 
-
9 #include <QPainter>
-
10 #include <QPoint>
-
11 #include <QQuickPaintedItem>
-
12 #include <QTcpServer>
-
13 #include <QTcpSocket>
-
14 
-
15 #include <memory>
-
16 #include <vector>
-
17 
-
18 namespace sk {
-
19 
-
20 class Canvas : public QQuickPaintedItem
-
21 {
-
22 private:
-
23  Q_OBJECT
-
24 
-
25  DrawHistory m_history{};
-
26  std::unique_ptr<DrawMode> m_drawMode{};
-
27  std::unique_ptr<AbstractNetwork> m_network{ nullptr };
-
28 
-
29  QColor m_foreignColor{ DrawMode::getDefaultColor() };
-
30  int m_foreignWidth{ DrawMode::getDefaultWidth() };
-
31 
-
32 public:
-
33  explicit Canvas(QQuickPaintedItem* parent = nullptr);
-
34  Canvas(Canvas const&) = delete;
-
35  Canvas(Canvas&&) = delete;
-
36  ~Canvas() noexcept override = default;
-
37 
-
38  auto operator=(Canvas const&) = delete;
-
39  auto operator=(Canvas&&) = delete;
-
40 
-
41  auto paint(QPainter* painter) -> void override;
-
42 
-
43 public slots:
-
44  void mousePositionChanged(QPoint const& pos);
-
45  void mouseReleased();
-
46  void undo();
-
47  void redo();
-
48  void onReceivedMessage(QString const& msg);
-
49  void changeColor(QColor const& color);
-
50  void changeWidth(const int width);
-
51 };
-
52 
-
53 } // namespace sk
-
54 
-
55 #endif // !CANVAS_HPP
-
-
-
Definition: canvas.hpp:20
- - - - diff --git a/docs/canvas__config_8hpp.xml b/docs/canvas__config_8hpp.xml new file mode 100644 index 0000000..06f5fc3 --- /dev/null +++ b/docs/canvas__config_8hpp.xml @@ -0,0 +1,50 @@ + + + + canvas_config.hpp + src/draw_history.hpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + sk::config + + + + + + + diff --git a/docs/canvas__config_8hpp_source.html b/docs/canvas__config_8hpp_source.html deleted file mode 100644 index 3578e10..0000000 --- a/docs/canvas__config_8hpp_source.html +++ /dev/null @@ -1,93 +0,0 @@ - - - - - - - -Skribble: src/canvas_config.hpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
canvas_config.hpp
-
-
-
1 #ifndef CANVAS_CONFIG_HPP
-
2 #define CANVAS_CONFIG_HPP
-
3 #pragma once
-
4 
-
5 namespace sk::config {
-
6 
-
7 inline constexpr int width = 400;
-
8 inline constexpr int height = 600;
-
9 
-
10 } // namespace sk::config
-
11 
-
12 #endif // !CANVAS_CONFIG_HPP
-
- - - - diff --git a/docs/classDummy-members.html b/docs/classDummy-members.html deleted file mode 100644 index bacb2e0..0000000 --- a/docs/classDummy-members.html +++ /dev/null @@ -1,88 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- -
-
-
-
Dummy Member List
-
-
- -

This is the complete list of members for Dummy, including all inherited members.

- - - - - - - - - -
Dummy() noexcept=default (defined in Dummy)Dummy
Dummy(Dummy const &) noexcept=default (defined in Dummy)Dummy
Dummy(Dummy &&) noexcept=default (defined in Dummy)Dummy
Dummy(int const num) (defined in Dummy)Dummyinlineexplicit
operator<< (defined in Dummy)Dummyfriend
operator=(Dummy const &) noexcept -> Dummy &=default (defined in Dummy)Dummy
operator=(Dummy &&) noexcept -> Dummy &=default (defined in Dummy)Dummy
~Dummy() noexcept=default (defined in Dummy)Dummy
- - - - diff --git a/docs/classDummy.html b/docs/classDummy.html deleted file mode 100644 index 4a3114d..0000000 --- a/docs/classDummy.html +++ /dev/null @@ -1,112 +0,0 @@ - - - - - - - -Skribble: Dummy Class Reference - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- -
-
- -
-
Dummy Class Reference
-
-
- - - - - - - - - - - - -

-Public Member Functions

Dummy (Dummy const &) noexcept=default
 
Dummy (Dummy &&) noexcept=default
 
Dummy (int const num)
 
-auto operator= (Dummy const &) noexcept -> Dummy &=default
 
-auto operator= (Dummy &&) noexcept -> Dummy &=default
 
- - - -

-Friends

-auto operator<< (std::ostream &os, Dummy const &d) -> std::ostream &
 
-

Detailed Description

-
-

Definition at line 35 of file format_test.cpp.

-

The documentation for this class was generated from the following file: -
- - - - diff --git a/docs/classDummy.xml b/docs/classDummy.xml new file mode 100644 index 0000000..5290395 --- /dev/null +++ b/docs/classDummy.xml @@ -0,0 +1,170 @@ + + + + Dummy + + + int + int Dummy::m_num + + m_num + { 0 } + + + + + + + + + + + + + Dummy::Dummy + () noexcept=default + Dummy + + + + + + + + + + + Dummy::Dummy + (Dummy const &) noexcept=default + Dummy + + Dummy const & + + + + + + + + + + + + Dummy::Dummy + (Dummy &&) noexcept=default + Dummy + + Dummy && + + + + + + + + + + + + Dummy::~Dummy + () noexcept=default + ~Dummy + + + + + + + + + + + Dummy::Dummy + (int const num) + Dummy + + int const + num + + + + + + + + + + + auto + auto Dummy::operator= + (Dummy const &) noexcept -> Dummy &=default + operator= + + Dummy const & + + + + + + + + + + + auto + auto Dummy::operator= + (Dummy &&) noexcept -> Dummy &=default + operator= + + Dummy && + + + + + + + + + + + + + friend auto + auto operator<< + (std::ostream &os, Dummy const &d) -> std::ostream & + operator<< + + std::ostream & + os + + + Dummy const & + d + + + + + + + + + + + + + + + + + DummyDummy + DummyDummy + DummyDummy + DummyDummy + Dummym_num + Dummyoperator<< + Dummyoperator= + Dummyoperator= + Dummy~Dummy + + + diff --git a/docs/classTestBase-members.html b/docs/classTestBase-members.html deleted file mode 100644 index 212f9f4..0000000 --- a/docs/classTestBase-members.html +++ /dev/null @@ -1,93 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- -
-
-
-
TestBase Member List
-
-
- -

This is the complete list of members for TestBase, including all inherited members.

- - - - - - - - - - - - - - -
m_file (defined in TestBase)TestBaseprotected
m_line (defined in TestBase)TestBaseprotected
m_name (defined in TestBase)TestBaseprotected
m_output (defined in TestBase)TestBaseprotected
m_testId (defined in TestBase)TestBaseprotected
operator=(TestBase const &) -> TestBase &=delete (defined in TestBase)TestBase
operator=(TestBase &&) noexcept -> TestBase &=default (defined in TestBase)TestBase
run(std::atomic< int > &successful) -> void=0 (defined in TestBase)TestBasepure virtual
TestBase()=delete (defined in TestBase)TestBase
TestBase(TestBase const &)=delete (defined in TestBase)TestBase
TestBase(TestBase &&) noexcept=default (defined in TestBase)TestBase
TestBase(std::string testName, std::string file, int const line) (defined in TestBase)TestBase
~TestBase() noexcept=default (defined in TestBase)TestBasevirtual
- - - - diff --git a/docs/classTestBase.html b/docs/classTestBase.html deleted file mode 100644 index ea1f16a..0000000 --- a/docs/classTestBase.html +++ /dev/null @@ -1,133 +0,0 @@ - - - - - - - -Skribble: TestBase Class Reference - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- -
-
- -
-
TestBase Class Referenceabstract
-
-
- - - - -

-Classes

struct  Proxy
 
- - - - - - - - - - - - - -

-Public Member Functions

TestBase (TestBase const &)=delete
 
TestBase (TestBase &&) noexcept=default
 
TestBase (std::string testName, std::string file, int const line)
 
-auto operator= (TestBase const &) -> TestBase &=delete
 
-auto operator= (TestBase &&) noexcept -> TestBase &=default
 
-virtual auto run (std::atomic< int > &successful) -> void=0
 
- - - - - - - - - - - -

-Protected Attributes

-std::ofstream m_output {}
 
-std::string m_name {}
 
-std::string m_file {}
 
-int m_line { 0 }
 
-int m_testId { 0 }
 
-

Detailed Description

-
-

Definition at line 22 of file test.hpp.

-

The documentation for this class was generated from the following file: -
- - - - diff --git a/docs/classTestBase.xml b/docs/classTestBase.xml new file mode 100644 index 0000000..8b1579b --- /dev/null +++ b/docs/classTestBase.xml @@ -0,0 +1,233 @@ + + + + TestBase + TestBase::Proxy + + + std::ofstream + std::ofstream TestBase::m_output + + m_output + {} + + + + + + + + + + std::string + std::string TestBase::m_name + + m_name + {} + + + + + + + + + + std::string + std::string TestBase::m_file + + m_file + {} + + + + + + + + + + int + int TestBase::m_line + + m_line + { 0 } + + + + + + + + + + int + int TestBase::m_testId + + m_testId + { 0 } + + + + + + + + + + + + + TestBase::TestBase + ()=delete + TestBase + + + + + + + + + + + TestBase::TestBase + (TestBase const &)=delete + TestBase + + TestBase const & + + + + + + + + + + + + TestBase::TestBase + (TestBase &&) noexcept=default + TestBase + + TestBase && + + + + + + + + + + + + virtual TestBase::~TestBase + () noexcept=default + ~TestBase + + + + + + + + + + + TestBase::TestBase + (std::string testName, std::string file, int const line) + TestBase + + std::string + testName + + + std::string + file + + + int const + line + + + + + + + + + + + auto + auto TestBase::operator= + (TestBase const &) -> TestBase &=delete + operator= + + TestBase const & + + + + + + + + + + + auto + auto TestBase::operator= + (TestBase &&) noexcept -> TestBase &=default + operator= + + TestBase && + + + + + + + + + + + auto + virtual auto TestBase::run + (std::atomic< int > &successful) -> void=0 + run + + std::atomic< int > & + successful + + + + + + + + + + + + + + + + + TestBasem_file + TestBasem_line + TestBasem_name + TestBasem_output + TestBasem_testId + TestBaseoperator= + TestBaseoperator= + TestBaserun + TestBaseTestBase + TestBaseTestBase + TestBaseTestBase + TestBaseTestBase + TestBase~TestBase + + + diff --git a/docs/classes.html b/docs/classes.html deleted file mode 100644 index f65d695..0000000 --- a/docs/classes.html +++ /dev/null @@ -1,135 +0,0 @@ - - - - - - - -Skribble: Class Index - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - -
- -
-
- - -
- -
- -
-
-
Class Index
-
-
-
a | b | c | d | f | n | p | r | s | t
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  a  
-
CachedResource (sk)   
  f  
-
  p  
-
  t  
-
Canvas (sk)   
AbstractNetwork (sk)   Client (sk)   FCachedResource (sk)   PenMode (sk)   TestBase   
  b  
-
  d  
-
FResTraits (sk)   TestBase::Proxy   Trait2   
FTrait2   
  r  
-
Traits3   
BrushMode (sk)   DrawHistory (sk)   FTraits   
  c  
-
DrawMode (sk)   FTraits3   ResourceTraits (sk)   
Dummy   
  n  
-
  s  
-
CachedLayers (sk::impl)   DummyNetwork (sk)   
NetworkFactory (sk)   Server (sk)   
-
a | b | c | d | f | n | p | r | s | t
-
- - - - diff --git a/docs/classsk_1_1AbstractNetwork-members.html b/docs/classsk_1_1AbstractNetwork-members.html deleted file mode 100644 index 51950c2..0000000 --- a/docs/classsk_1_1AbstractNetwork-members.html +++ /dev/null @@ -1,100 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::AbstractNetwork Member List
-
-
- -

This is the complete list of members for sk::AbstractNetwork, including all inherited members.

- - - - - - - - - - - - - - - - - -
AbstractNetwork(QObject *parent=nullptr) (defined in sk::AbstractNetwork)sk::AbstractNetworkexplicit
AbstractNetwork(AbstractNetwork const &)=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
AbstractNetwork(AbstractNetwork &&) noexcept=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
getSocket() -> QTcpSocket *=0 (defined in sk::AbstractNetwork)sk::AbstractNetworkpure virtual
operator=(AbstractNetwork const &) -> AbstractNetwork &=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
operator=(AbstractNetwork &&) noexcept -> AbstractNetwork &=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
receivedMessage(QString const &msg) (defined in sk::AbstractNetwork)sk::AbstractNetworksignal
sendChangeColor(QColor const &color) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendChangeWidth(int const width) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendDrawAt(QPoint const &pos) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendMouseReleased() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendRedo() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendToBrush() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendToPen() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendUndo() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
~AbstractNetwork() noexcept override=default (defined in sk::AbstractNetwork)sk::AbstractNetwork
- - - - diff --git a/docs/classsk_1_1AbstractNetwork.html b/docs/classsk_1_1AbstractNetwork.html index 2ef7d12..175bf86 100644 --- a/docs/classsk_1_1AbstractNetwork.html +++ b/docs/classsk_1_1AbstractNetwork.html @@ -1,165 +1,158 @@ - - + + - - - - -Skribble: sk::AbstractNetwork Class Reference - - - - - - - + + sk::AbstractNetwork class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ sk::AbstractNetwork class +

+

Contains all common events for a client/server.

+
+

Contents

+ +
+
+

Derived classes

+
+
+ class Client final +
+
Implements AbstractNetwork for a client.
+
+ class DummyNetwork final +
+
Implement AbstractNetwork for single-user mode.
+
+ class Server final +
+
Implements AbstractNetwork for a server.
+
+
+
+

Public functions

+
+
+ auto getSocket() -> QTcpSocket * -> auto pure virtual +
+
Helper to get current connection.
+
+
+
+

Signals

+
+
+ void receivedMessage(QString const& msg) +
+
Called when the other user does something that changes appearance on canvas.
+
+
+
+

Function documentation

+
+

+ auto sk::AbstractNetwork::getSocket() -> QTcpSocket * pure virtual +

+

Helper to get current connection.

+

If the app was started as a server, this returns the client 'connection', If the app was started as a client, this 'returns' the server, otherwise it simply returns nullptr.

+
+
+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::AbstractNetwork Class Referenceabstract
-
-
-
-Inheritance diagram for sk::AbstractNetwork:
-
-
Inheritance graph
- - - - - - - -
[legend]
-
-Collaboration diagram for sk::AbstractNetwork:
-
-
Collaboration graph
- - - - -
[legend]
- - - - -

-Signals

-void receivedMessage (QString const &msg)
 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

AbstractNetwork (QObject *parent=nullptr)
 
AbstractNetwork (AbstractNetwork const &)=delete
 
AbstractNetwork (AbstractNetwork &&) noexcept=delete
 
-auto operator= (AbstractNetwork const &) -> AbstractNetwork &=delete
 
-auto operator= (AbstractNetwork &&) noexcept -> AbstractNetwork &=delete
 
-virtual auto getSocket () -> QTcpSocket *=0
 
-auto sendDrawAt (QPoint const &pos) -> void
 
-auto sendMouseReleased () -> void
 
-auto sendUndo () -> void
 
-auto sendRedo () -> void
 
-auto sendChangeColor (QColor const &color) -> void
 
-auto sendChangeWidth (int const width) -> void
 
-auto sendToPen () -> void
 
-auto sendToBrush () -> void
 
-

Detailed Description

-
-

Definition at line 13 of file abstract_network.hpp.

-

The documentation for this class was generated from the following files: -
- - + + +
diff --git a/docs/classsk_1_1AbstractNetwork.xml b/docs/classsk_1_1AbstractNetwork.xml new file mode 100644 index 0000000..9699c89 --- /dev/null +++ b/docs/classsk_1_1AbstractNetwork.xml @@ -0,0 +1,326 @@ + + + + sk::AbstractNetwork + QObject + sk::Client + sk::DummyNetwork + sk::Server + abstract_network.hpp + + + + sk::AbstractNetwork::AbstractNetwork + (QObject *parent=nullptr) + AbstractNetwork + + QObject * + parent + nullptr + + + + + + + + + + + + sk::AbstractNetwork::AbstractNetwork + (AbstractNetwork const &)=delete + AbstractNetwork + + AbstractNetwork const & + + + + + + + + + + + + sk::AbstractNetwork::AbstractNetwork + (AbstractNetwork &&) noexcept=delete + AbstractNetwork + + AbstractNetwork && + + + + + + + + + + + + sk::AbstractNetwork::~AbstractNetwork + () noexcept override=default + ~AbstractNetwork + + + + + + + + + + auto + auto sk::AbstractNetwork::operator= + (AbstractNetwork const &) -> AbstractNetwork &=delete + operator= + + AbstractNetwork const & + + + + + + + + + + + auto + auto sk::AbstractNetwork::operator= + (AbstractNetwork &&) noexcept -> AbstractNetwork &=delete + operator= + + AbstractNetwork && + + + + + + + + + + + auto + virtual auto sk::AbstractNetwork::getSocket + () -> QTcpSocket *=0 + getSocket + getSocket + getSocket + getSocket + +Helper to get current connection. + + +If the app was started as a server, this returns the client 'connection', If the app was started as a client, this 'returns' the server, otherwise it simply returns nullptr. + + + + + + + auto + auto sk::AbstractNetwork::sendDrawAt + (QPoint const &pos) -> void + sendDrawAt + + QPoint const & + pos + + + + + + + + + + + auto + auto sk::AbstractNetwork::sendMouseReleased + () -> void + sendMouseReleased + + + + + + + + + + auto + auto sk::AbstractNetwork::sendUndo + () -> void + sendUndo + + + + + + + + + + auto + auto sk::AbstractNetwork::sendRedo + () -> void + sendRedo + + + + + + + + + + auto + auto sk::AbstractNetwork::sendChangeColor + (QColor const &color) -> void + sendChangeColor + + QColor const & + color + + + + + + + + + + + auto + auto sk::AbstractNetwork::sendChangeWidth + (int const width) -> void + sendChangeWidth + + int const + width + + + + + + + + + + + auto + auto sk::AbstractNetwork::sendToPen + () -> void + sendToPen + + + + + + + + + + auto + auto sk::AbstractNetwork::sendToBrush + () -> void + sendToBrush + + + + + + + + + + + + void + void sk::AbstractNetwork::receivedMessage + (QString const &msg) + receivedMessage + + QString const & + msg + + +Called when the other user does something that changes appearance on canvas. + + + + + + + + + +Contains all common events for a client/server. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::AbstractNetworkAbstractNetwork + sk::AbstractNetworkAbstractNetwork + sk::AbstractNetworkAbstractNetwork + sk::AbstractNetworkgetSocket + sk::AbstractNetworkoperator= + sk::AbstractNetworkoperator= + sk::AbstractNetworkreceivedMessage + sk::AbstractNetworksendChangeColor + sk::AbstractNetworksendChangeWidth + sk::AbstractNetworksendDrawAt + sk::AbstractNetworksendMouseReleased + sk::AbstractNetworksendRedo + sk::AbstractNetworksendToBrush + sk::AbstractNetworksendToPen + sk::AbstractNetworksendUndo + sk::AbstractNetwork~AbstractNetwork + + + diff --git a/docs/classsk_1_1AbstractNetwork__coll__graph.map b/docs/classsk_1_1AbstractNetwork__coll__graph.map deleted file mode 100644 index 10a6098..0000000 --- a/docs/classsk_1_1AbstractNetwork__coll__graph.map +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/docs/classsk_1_1AbstractNetwork__coll__graph.md5 b/docs/classsk_1_1AbstractNetwork__coll__graph.md5 deleted file mode 100644 index e990ddc..0000000 --- a/docs/classsk_1_1AbstractNetwork__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -d217c771e7d8aaca3c4b18b47a2a520c \ No newline at end of file diff --git a/docs/classsk_1_1AbstractNetwork__coll__graph.png b/docs/classsk_1_1AbstractNetwork__coll__graph.png deleted file mode 100644 index b4e7432..0000000 Binary files a/docs/classsk_1_1AbstractNetwork__coll__graph.png and /dev/null differ diff --git a/docs/classsk_1_1AbstractNetwork__inherit__graph.map b/docs/classsk_1_1AbstractNetwork__inherit__graph.map deleted file mode 100644 index f644e69..0000000 --- a/docs/classsk_1_1AbstractNetwork__inherit__graph.map +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/docs/classsk_1_1AbstractNetwork__inherit__graph.md5 b/docs/classsk_1_1AbstractNetwork__inherit__graph.md5 deleted file mode 100644 index 0d95766..0000000 --- a/docs/classsk_1_1AbstractNetwork__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -027e3f6871dc6b5f838afbcbaffe6f91 \ No newline at end of file diff --git a/docs/classsk_1_1AbstractNetwork__inherit__graph.png b/docs/classsk_1_1AbstractNetwork__inherit__graph.png deleted file mode 100644 index f882f52..0000000 Binary files a/docs/classsk_1_1AbstractNetwork__inherit__graph.png and /dev/null differ diff --git a/docs/classsk_1_1BrushMode-members.html b/docs/classsk_1_1BrushMode-members.html deleted file mode 100644 index ee1f0a7..0000000 --- a/docs/classsk_1_1BrushMode-members.html +++ /dev/null @@ -1,109 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::BrushMode Member List
-
-
- -

This is the complete list of members for sk::BrushMode, including all inherited members.

- - - - - - - - - - - - - - - - - - - - - - - - - - -
BrushMode() noexcept=default (defined in sk::BrushMode)sk::BrushMode
BrushMode(BrushMode const &) noexcept=default (defined in sk::BrushMode)sk::BrushMode
BrushMode(BrushMode &&)=default (defined in sk::BrushMode)sk::BrushMode
BrushMode(QBrush const &brush) (defined in sk::BrushMode)sk::BrushModeexplicit
BrushMode(QBrush &&brush) (defined in sk::BrushMode)sk::BrushModeexplicit
draw(QPainter &painter, QPoint const &pos, std::optional< QPoint > const &lastPos) -> void override (defined in sk::BrushMode)sk::BrushModevirtual
DrawMode() noexcept=default (defined in sk::DrawMode)sk::DrawMode
DrawMode(DrawMode const &) noexcept=default (defined in sk::DrawMode)sk::DrawMode
DrawMode(DrawMode &&) noexcept=default (defined in sk::DrawMode)sk::DrawMode
getColor() const noexcept -> QColor (defined in sk::DrawMode)sk::DrawModeinline
getDefaultColor() noexcept -> QColor (defined in sk::DrawMode)sk::DrawModeinlinestatic
getDefaultWidth() noexcept -> int (defined in sk::DrawMode)sk::DrawModeinlinestatic
getWidth() const noexcept -> int (defined in sk::DrawMode)sk::DrawModeinline
m_color (defined in sk::DrawMode)sk::DrawModeprotectedstatic
m_defaultColor (defined in sk::DrawMode)sk::DrawModeprotectedstatic
m_defaultWidth (defined in sk::DrawMode)sk::DrawModeprotectedstatic
m_width (defined in sk::DrawMode)sk::DrawModeprotectedstatic
operator=(BrushMode const &) noexcept -> BrushMode &=default (defined in sk::BrushMode)sk::BrushMode
operator=(BrushMode &&) noexcept -> BrushMode &=default (defined in sk::BrushMode)sk::BrushMode
operator=(DrawMode const &) noexcept -> DrawMode &=default (defined in sk::DrawMode)sk::DrawMode
operator=(DrawMode &&) noexcept -> DrawMode &=default (defined in sk::DrawMode)sk::DrawMode
setColor(QColor const &color) noexcept -> void (defined in sk::DrawMode)sk::DrawModeinline
setWidth(int const width) noexcept -> void (defined in sk::DrawMode)sk::DrawModeinline
~BrushMode() noexcept override=default (defined in sk::BrushMode)sk::BrushMode
~DrawMode() noexcept=default (defined in sk::DrawMode)sk::DrawModevirtual
- - - - diff --git a/docs/classsk_1_1BrushMode.html b/docs/classsk_1_1BrushMode.html index 3cd73ca..059de0b 100644 --- a/docs/classsk_1_1BrushMode.html +++ b/docs/classsk_1_1BrushMode.html @@ -1,182 +1,109 @@ - - + + - - - - -Skribble: sk::BrushMode Class Reference - - - - - - - + + sk::BrushMode class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ sk::BrushMode class +

+

Implements drawing with a brush.

+
+

Base classes

+
+
+ class DrawMode +
+
Defines methods for drawing with different instruments.
+
+
+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::BrushMode Class Reference
-
-
-
-Inheritance diagram for sk::BrushMode:
-
-
Inheritance graph
- - - - -
[legend]
-
-Collaboration diagram for sk::BrushMode:
-
-
Collaboration graph
- - - - -
[legend]
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

BrushMode (BrushMode const &) noexcept=default
 
BrushMode (BrushMode &&)=default
 
BrushMode (QBrush const &brush)
 
BrushMode (QBrush &&brush)
 
-auto operator= (BrushMode const &) noexcept -> BrushMode &=default
 
-auto operator= (BrushMode &&) noexcept -> BrushMode &=default
 
-auto draw (QPainter &painter, QPoint const &pos, std::optional< QPoint > const &lastPos) -> void override
 
- Public Member Functions inherited from sk::DrawMode
DrawMode (DrawMode const &) noexcept=default
 
DrawMode (DrawMode &&) noexcept=default
 
-auto operator= (DrawMode const &) noexcept -> DrawMode &=default
 
-auto operator= (DrawMode &&) noexcept -> DrawMode &=default
 
-auto getWidth () const noexcept -> int
 
-auto setWidth (int const width) noexcept -> void
 
-auto getColor () const noexcept -> QColor
 
-auto setColor (QColor const &color) noexcept -> void
 
- - - - - - - - - - - - - - - -

-Additional Inherited Members

- Static Public Member Functions inherited from sk::DrawMode
-static constexpr auto getDefaultColor () noexcept -> QColor
 
-static constexpr auto getDefaultWidth () noexcept -> int
 
- Static Protected Attributes inherited from sk::DrawMode
-static constexpr int m_defaultWidth = 5
 
-static constexpr QColor m_defaultColor { 0, 0, 0 }
 
-static int m_width = DrawMode::m_defaultWidth
 
-static QColor m_color = DrawMode::m_defaultColor
 
-

Detailed Description

-
-

Definition at line 93 of file draw_mode.hpp.

-

The documentation for this class was generated from the following files: -
- - + + +
diff --git a/docs/classsk_1_1BrushMode.xml b/docs/classsk_1_1BrushMode.xml new file mode 100644 index 0000000..afc4b30 --- /dev/null +++ b/docs/classsk_1_1BrushMode.xml @@ -0,0 +1,234 @@ + + + + sk::BrushMode + sk::DrawMode + draw_mode.hpp + + + QBrush + QBrush sk::BrushMode::m_brush + + m_brush + { QColor{ "black" }, Qt::BrushStyle::SolidPattern } + + + + + + + + + + + + + sk::BrushMode::BrushMode + () noexcept=default + BrushMode + + + + + + + + + + + sk::BrushMode::BrushMode + (BrushMode const &) noexcept=default + BrushMode + + BrushMode const & + + + + + + + + + + + + sk::BrushMode::BrushMode + (BrushMode &&)=default + BrushMode + + BrushMode && + + + + + + + + + + + + sk::BrushMode::~BrushMode + () noexcept override=default + ~BrushMode + + + + + + + + + + + sk::BrushMode::BrushMode + (QBrush const &brush) + BrushMode + + QBrush const & + brush + + + + + + + + + + + + sk::BrushMode::BrushMode + (QBrush &&brush) + BrushMode + + QBrush && + brush + + + + + + + + + + + auto + auto sk::BrushMode::operator= + (BrushMode const &) noexcept -> BrushMode &=default + operator= + + BrushMode const & + + + + + + + + + + + auto + auto sk::BrushMode::operator= + (BrushMode &&) noexcept -> BrushMode &=default + operator= + + BrushMode && + + + + + + + + + + + auto + auto sk::BrushMode::draw + (QPainter &painter, QPoint const &pos, std::optional< QPoint > const &lastPos) -> void override + draw + draw + + QPainter & + painter + + + QPoint const & + pos + + + std::optional< QPoint > const & + lastPos + + + + + + + + + + + +Implements drawing with a brush. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::BrushModeBrushMode + sk::BrushModeBrushMode + sk::BrushModeBrushMode + sk::BrushModeBrushMode + sk::BrushModeBrushMode + sk::BrushModedraw + sk::BrushModeDrawMode + sk::BrushModeDrawMode + sk::BrushModeDrawMode + sk::BrushModegetColor + sk::BrushModegetDefaultColor + sk::BrushModegetDefaultWidth + sk::BrushModegetWidth + sk::BrushModem_brush + sk::BrushModem_color + sk::BrushModem_defaultColor + sk::BrushModem_defaultWidth + sk::BrushModem_width + sk::BrushModeoperator= + sk::BrushModeoperator= + sk::BrushModeoperator= + sk::BrushModeoperator= + sk::BrushModesetColor + sk::BrushModesetWidth + sk::BrushMode~BrushMode + sk::BrushMode~DrawMode + + + diff --git a/docs/classsk_1_1BrushMode__coll__graph.map b/docs/classsk_1_1BrushMode__coll__graph.map deleted file mode 100644 index e5d9c23..0000000 --- a/docs/classsk_1_1BrushMode__coll__graph.map +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/docs/classsk_1_1BrushMode__coll__graph.md5 b/docs/classsk_1_1BrushMode__coll__graph.md5 deleted file mode 100644 index 0c12936..0000000 --- a/docs/classsk_1_1BrushMode__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -8dd0ef24cde39627c99edbda837f0b4d \ No newline at end of file diff --git a/docs/classsk_1_1BrushMode__coll__graph.png b/docs/classsk_1_1BrushMode__coll__graph.png deleted file mode 100644 index 96f9fcc..0000000 Binary files a/docs/classsk_1_1BrushMode__coll__graph.png and /dev/null differ diff --git a/docs/classsk_1_1BrushMode__inherit__graph.map b/docs/classsk_1_1BrushMode__inherit__graph.map deleted file mode 100644 index e5d9c23..0000000 --- a/docs/classsk_1_1BrushMode__inherit__graph.map +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/docs/classsk_1_1BrushMode__inherit__graph.md5 b/docs/classsk_1_1BrushMode__inherit__graph.md5 deleted file mode 100644 index 0c12936..0000000 --- a/docs/classsk_1_1BrushMode__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -8dd0ef24cde39627c99edbda837f0b4d \ No newline at end of file diff --git a/docs/classsk_1_1BrushMode__inherit__graph.png b/docs/classsk_1_1BrushMode__inherit__graph.png deleted file mode 100644 index 96f9fcc..0000000 Binary files a/docs/classsk_1_1BrushMode__inherit__graph.png and /dev/null differ diff --git a/docs/classsk_1_1CachedResource-members.html b/docs/classsk_1_1CachedResource-members.html deleted file mode 100644 index f623a0f..0000000 --- a/docs/classsk_1_1CachedResource-members.html +++ /dev/null @@ -1,102 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::CachedResource< T, Traits > Member List
-
-
- -

This is the complete list of members for sk::CachedResource< T, Traits >, including all inherited members.

- - - - - - - - - - - - - - - - - - - -
CachedResource()=default (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >
CachedResource(Function f) (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >inlineexplicit
CachedResource(CachedResource const &)=default (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >
CachedResource(CachedResource &&) noexcept=default (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >
emplaceBack(Ts &&... ts) -> T & (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >inline
getLast() noexcept -> T & (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >inline
getLast() const noexcept -> T const & (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >inline
getLastCache() noexcept -> T * (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >inline
getUnderlying() noexcept -> ContainerType & (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >inline
getUnderlying() const noexcept -> ContainerType const & (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >inline
operator=(CachedResource const &) -> CachedResource &=default (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >
operator=(CachedResource &&) noexcept -> CachedResource &=default (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >
redo() -> boolsk::CachedResource< T, Traits >inline
reduceTo(T &value) -> void (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >inline
reduceTo(F2 f) -> void (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >inline
underUndo() const noexcept -> bool (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >inline
undo() -> boolsk::CachedResource< T, Traits >inline
~CachedResource() noexcept=default (defined in sk::CachedResource< T, Traits >)sk::CachedResource< T, Traits >
- - - - diff --git a/docs/classsk_1_1CachedResource.html b/docs/classsk_1_1CachedResource.html index 76237e1..aa6646b 100644 --- a/docs/classsk_1_1CachedResource.html +++ b/docs/classsk_1_1CachedResource.html @@ -1,208 +1,221 @@ - - + + - - - - -Skribble: sk::CachedResource< T, Traits > Class Template Reference - - - - - - - + + sk::CachedResource class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+
template<typename T, typename Traits = ResourceTraits<T>>
+ sk::CachedResource class +

+

Another utility that can manage undo/redo.

+
+

Contents

+ +
+

This was actually supposed to be FCachedResource. It turned out we were overcomplicating ourselves with the store cache after n layers. It was incredibly tedious to implement(address sanitizer found some iterator invalidations) and didn't provide much benefit. This is only used when multiple users are connected to store local cache for each of them.

+
+

Public functions

+
+
+
template<typename... Ts>
+ auto emplaceBack(Ts && ... ts) -> T & -> auto +
+
+
+ auto getLastCache() noexcept -> T * -> auto +
+
Get tha last stored cache or nullptr if no cache was built yet.
+
+ auto reduceTo(T& value) -> void -> auto +
+
+
+
template<typename F2>
+ auto reduceTo(F2 f) -> void -> auto +
+
+
+ auto underUndo() const noexcept -> bool -> auto constexpr +
+
+
+ auto undo() -> bool -> auto +
+
+
+ auto redo() -> bool -> auto +
+
+
+
+
+

Function documentation

+
+

+
+ template<typename T, typename Traits> + template<typename... Ts> +
+ auto sk::CachedResource<T, Traits>::emplaceBack(Ts && ... ts) -> T & +

+

Similar to FCachedResource::emplaceBack.

+
+
+

+
+ template<typename T, typename Traits> +
+ auto sk::CachedResource<T, Traits>::reduceTo(T& value) -> void +

+

Called for the last built cache + all remaining layers.

+
+
+

+
+ template<typename T, typename Traits> + template<typename F2> +
+ auto sk::CachedResource<T, Traits>::reduceTo(F2 f) -> void +

+

Same as reduceTo but can take a callback to know what to do.

+
+
+

+
+ template<typename T, typename Traits> +
+ auto sk::CachedResource<T, Traits>::underUndo() const noexcept -> bool constexpr +

+

Similar to FCachedResource::underUndo.

+
+
+

+
+ template<typename T, typename Traits> +
+ auto sk::CachedResource<T, Traits>::undo() -> bool +

+ + + + + + + +
Returnstrue If undo was successful. false If already at oldest change.
+
+
+

+
+ template<typename T, typename Traits> +
+ auto sk::CachedResource<T, Traits>::redo() -> bool +

+ + + + + + + +
Returnstrue If redo can be done still. false If got to the newest change.
+
+
+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::CachedResource< T, Traits > Class Template Reference
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

CachedResource (Function f)
 
CachedResource (CachedResource const &)=default
 
CachedResource (CachedResource &&) noexcept=default
 
-auto operator= (CachedResource const &) -> CachedResource &=default
 
-auto operator= (CachedResource &&) noexcept -> CachedResource &=default
 
-template<typename... Ts>
auto emplaceBack (Ts &&... ts) -> T &
 
-auto getLastCache () noexcept -> T *
 
-auto reduceTo (T &value) -> void
 
-template<typename F2 >
auto reduceTo (F2 f) -> void
 
-auto getLast () noexcept -> T &
 
-auto getLast () const noexcept -> T const &
 
-constexpr auto underUndo () const noexcept -> bool
 
auto undo () -> bool
 
auto redo () -> bool
 
-auto getUnderlying () noexcept -> ContainerType &
 
-auto getUnderlying () const noexcept -> ContainerType const &
 
-

Detailed Description

-

template<typename T, typename Traits = ResourceTraits<T>>
-class sk::CachedResource< T, Traits >

- - -

Definition at line 23 of file cached_resource.hpp.

-

Member Function Documentation

- -

◆ redo()

- -
-
-
-template<typename T , typename Traits = ResourceTraits<T>>
- - - - - -
- - - - - - - -
auto sk::CachedResource< T, Traits >::redo () -> bool -
-
-inline
-
-
Returns
true If redo can be done still. false If got to the newest change.
- -

Definition at line 247 of file cached_resource.hpp.

- -
-
- -

◆ undo()

- -
-
-
-template<typename T , typename Traits = ResourceTraits<T>>
- - - - - -
- - - - - - - -
auto sk::CachedResource< T, Traits >::undo () -> bool -
-
-inline
-
-
Returns
true If undo was successful. false If already at oldest change.
- -

Definition at line 224 of file cached_resource.hpp.

- -
-
-
The documentation for this class was generated from the following file: -
- - + + +
diff --git a/docs/classsk_1_1CachedResource.xml b/docs/classsk_1_1CachedResource.xml new file mode 100644 index 0000000..851de7c --- /dev/null +++ b/docs/classsk_1_1CachedResource.xml @@ -0,0 +1,577 @@ + + + + sk::CachedResource + cached_resource.hpp + + + typename T + + + typename Traits + ResourceTraits<T> + + + + + typename Traits::ContainerType + using sk::CachedResource< T, Traits >::ContainerType = typename Traits::ContainerType + + ContainerType + + + + + + + + + + typename ContainerType::iterator + using sk::CachedResource< T, Traits >::Iterator = typename ContainerType::iterator + + Iterator + + + + + + + + + + void(*)(T &, T &) + using sk::CachedResource< T, Traits >::Function = void (*)(T&, T&) + + Function + + + + + + + + + + + + constexpr auto + constexpr auto sk::CachedResource< T, Traits >::m_cacheGap + + m_cacheGap + = Traits::cacheGap + + + + + + + + + + constexpr auto + constexpr auto sk::CachedResource< T, Traits >::m_maxCount + + m_maxCount + = Traits::maxCount + + + + + + + + + + + + ContainerType + ContainerType sk::CachedResource< T, Traits >::m_data + + m_data + {} + + + + + + + + + + ContainerType + ContainerType sk::CachedResource< T, Traits >::m_cache + + m_cache + {} + + + + + + + + + + Iterator + Iterator sk::CachedResource< T, Traits >::m_dataLimit + + m_dataLimit + {} + + + + + + + + + + Iterator + Iterator sk::CachedResource< T, Traits >::m_cacheLimit + + m_cacheLimit + {} + + + + + + + + + + bool + bool sk::CachedResource< T, Traits >::m_underUndo + + m_underUndo + { false } + + + + + + + + + + Function + Function sk::CachedResource< T, Traits >::m_function + + m_function + + + + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::plus + (Iterator it, int const count) const + plus + + Iterator + it + + + int const + count + + + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::getNumCaches + () noexcept -> int + getNumCaches + + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::noCaches + () noexcept -> bool + noCaches + + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::getIteratorPastCache + () noexcept -> Iterator + getIteratorPastCache + + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::clearUndo + () -> void + clearUndo + + + + + + + + + + + + + sk::CachedResource< T, Traits >::CachedResource + ()=default + CachedResource + + + + + + + + + + + sk::CachedResource< T, Traits >::CachedResource + (Function f) + CachedResource + + Function + f + + + + + + + + + + + + sk::CachedResource< T, Traits >::CachedResource + (CachedResource const &)=default + CachedResource + + CachedResource const & + + + + + + + + + + + + sk::CachedResource< T, Traits >::CachedResource + (CachedResource &&) noexcept=default + CachedResource + + CachedResource && + + + + + + + + + + + + sk::CachedResource< T, Traits >::~CachedResource + () noexcept=default + ~CachedResource + + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::operator= + (CachedResource const &) -> CachedResource &=default + operator= + + CachedResource const & + + + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::operator= + (CachedResource &&) noexcept -> CachedResource &=default + operator= + + CachedResource && + + + + + + + + + + + + + typename... + Ts + Ts + + + auto + auto sk::CachedResource< T, Traits >::emplaceBack + (Ts &&... ts) -> T & + emplaceBack + + Ts &&... + ts + + + + +Similar to FCachedResource::emplaceBack. + + + + + + + auto + auto sk::CachedResource< T, Traits >::getLastCache + () noexcept -> T * + getLastCache + +Get tha last stored cache or nullptr if no cache was built yet. + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::reduceTo + (T &value) -> void + reduceTo + + T & + value + + + + +Called for the last built cache + all remaining layers. + + + + + + + + + typename F2 + + + auto + auto sk::CachedResource< T, Traits >::reduceTo + (F2 f) -> void + reduceTo + + F2 + f + + + + +Same as reduceTo but can take a callback to know what to do. + + + + + + + auto + auto sk::CachedResource< T, Traits >::getLast + () noexcept -> T & + getLast + + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::getLast + () const noexcept -> T const & + getLast + + + + + + + + + + constexpr auto + constexpr auto sk::CachedResource< T, Traits >::underUndo + () const noexcept -> bool + underUndo + + + +Similar to FCachedResource::underUndo. + + + + + + + auto + auto sk::CachedResource< T, Traits >::undo + () -> bool + undo + + + +true If undo was successful. false If already at oldest change. + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::redo + () -> bool + redo + + + +true If redo can be done still. false If got to the newest change. + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::getUnderlying + () noexcept -> ContainerType & + getUnderlying + + + + + + + + + + auto + auto sk::CachedResource< T, Traits >::getUnderlying + () const noexcept -> ContainerType const & + getUnderlying + + + + + + + + + + +Another utility that can manage undo/redo. + + +This was actually supposed to be FCachedResource. It turned out we were overcomplicating ourselves with the store cache after n layers. It was incredibly tedious to implement(address sanitizer found some iterator invalidations) and didn't provide much benefit. This is only used when multiple users are connected to store local cache for each of them. + + + + sk::CachedResourceCachedResource + sk::CachedResourceCachedResource + sk::CachedResourceCachedResource + sk::CachedResourceCachedResource + sk::CachedResourceclearUndo + sk::CachedResourceContainerType + sk::CachedResourceemplaceBack + sk::CachedResourceFunction + sk::CachedResourcegetIteratorPastCache + sk::CachedResourcegetLast + sk::CachedResourcegetLast + sk::CachedResourcegetLastCache + sk::CachedResourcegetNumCaches + sk::CachedResourcegetUnderlying + sk::CachedResourcegetUnderlying + sk::CachedResourceIterator + sk::CachedResourcem_cache + sk::CachedResourcem_cacheGap + sk::CachedResourcem_cacheLimit + sk::CachedResourcem_data + sk::CachedResourcem_dataLimit + sk::CachedResourcem_function + sk::CachedResourcem_maxCount + sk::CachedResourcem_underUndo + sk::CachedResourcenoCaches + sk::CachedResourceoperator= + sk::CachedResourceoperator= + sk::CachedResourceplus + sk::CachedResourceredo + sk::CachedResourcereduceTo + sk::CachedResourcereduceTo + sk::CachedResourceunderUndo + sk::CachedResourceundo + sk::CachedResource~CachedResource + + + diff --git a/docs/classsk_1_1Canvas-members.html b/docs/classsk_1_1Canvas-members.html deleted file mode 100644 index 1a4eed7..0000000 --- a/docs/classsk_1_1Canvas-members.html +++ /dev/null @@ -1,98 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::Canvas Member List
-
-
- -

This is the complete list of members for sk::Canvas, including all inherited members.

- - - - - - - - - - - - - - - -
Canvas(QQuickPaintedItem *parent=nullptr) (defined in sk::Canvas)sk::Canvasexplicit
Canvas(Canvas const &)=delete (defined in sk::Canvas)sk::Canvas
Canvas(Canvas &&)=delete (defined in sk::Canvas)sk::Canvas
changeColor(QColor const &color) (defined in sk::Canvas)sk::Canvasslot
changeWidth(const int width) (defined in sk::Canvas)sk::Canvasslot
mousePositionChanged(QPoint const &pos) (defined in sk::Canvas)sk::Canvasslot
mouseReleased() (defined in sk::Canvas)sk::Canvasslot
onReceivedMessage(QString const &msg) (defined in sk::Canvas)sk::Canvasslot
operator=(Canvas const &)=delete (defined in sk::Canvas)sk::Canvas
operator=(Canvas &&)=delete (defined in sk::Canvas)sk::Canvas
paint(QPainter *painter) -> void override (defined in sk::Canvas)sk::Canvas
redo() (defined in sk::Canvas)sk::Canvasslot
undo() (defined in sk::Canvas)sk::Canvasslot
~Canvas() noexcept override=default (defined in sk::Canvas)sk::Canvas
- - - - diff --git a/docs/classsk_1_1Canvas.html b/docs/classsk_1_1Canvas.html index ddf0345..6bb62e6 100644 --- a/docs/classsk_1_1Canvas.html +++ b/docs/classsk_1_1Canvas.html @@ -1,156 +1,206 @@ - - + + - - - - -Skribble: sk::Canvas Class Reference - - - - - - - + + sk::Canvas class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ sk::Canvas class +

+

The class where all the magic happens.

+
+

Contents

+ +
+

This contains all behaviour related to painting itself.

All of mousePositionChanged, mouseReleased, undo, redo, changeColor, changeWidth are signals that other than modifying the local canvas accordingly, they also send the event over the network to the other user.

+
+

Public functions

+
+
+ auto paint(QPainter* painter) -> void -> auto override +
+
+
+
+
+

Public slots

+
+
+ void mousePositionChanged(QPoint const& pos) +
+
+
+ void mouseReleased() +
+
+
+ void undo() +
+
+
+ void redo() +
+
+
+ void onReceivedMessage(QString const& msg) +
+
+
+ void changeColor(QColor const& color) +
+
+
+ void changeWidth(const int width) +
+
+
+
+
+

Function documentation

+
+

+ auto sk::Canvas::paint(QPainter* painter) -> void override +

+

Draws the canvas.

+
+
+

+ void sk::Canvas::mousePositionChanged(QPoint const& pos) public slot +

+

This triggers a paint event on the canvas.

+
+
+

+ void sk::Canvas::mouseReleased() public slot +

+

This triggers 'creating a new layer' event.

+
+
+

+ void sk::Canvas::undo() public slot +

+

This goes back to the previously stored layer.

+
+
+

+ void sk::Canvas::redo() public slot +

+

Opposite of undo.

+
+
+

+ void sk::Canvas::onReceivedMessage(QString const& msg) public slot +

+

Called when a message through the network is received. Also handles the actual events that were received.

+
+
+

+ void sk::Canvas::changeColor(QColor const& color) public slot +

+

Changes the color of the pen/brush to draw with.

+
+
+

+ void sk::Canvas::changeWidth(const int width) public slot +

+

Changes the size of the brush/pen.

+
+
+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::Canvas Class Reference
-
-
-
-Inheritance diagram for sk::Canvas:
-
-
Inheritance graph
- - - - -
[legend]
-
-Collaboration diagram for sk::Canvas:
-
-
Collaboration graph
- - - - -
[legend]
- - - - - - - - - - - - - - - - -

-Public Slots

-void mousePositionChanged (QPoint const &pos)
 
-void mouseReleased ()
 
-void undo ()
 
-void redo ()
 
-void onReceivedMessage (QString const &msg)
 
-void changeColor (QColor const &color)
 
-void changeWidth (const int width)
 
- - - - - - - - - - - - - -

-Public Member Functions

Canvas (QQuickPaintedItem *parent=nullptr)
 
Canvas (Canvas const &)=delete
 
Canvas (Canvas &&)=delete
 
-auto operator= (Canvas const &)=delete
 
-auto operator= (Canvas &&)=delete
 
-auto paint (QPainter *painter) -> void override
 
-

Detailed Description

-
-

Definition at line 20 of file canvas.hpp.

-

The documentation for this class was generated from the following files: -
- - + + +
diff --git a/docs/classsk_1_1Canvas.xml b/docs/classsk_1_1Canvas.xml new file mode 100644 index 0000000..2be1d73 --- /dev/null +++ b/docs/classsk_1_1Canvas.xml @@ -0,0 +1,362 @@ + + + + sk::Canvas + QQuickPaintedItem + canvas.hpp + + + DrawHistory + DrawHistory sk::Canvas::m_history + + m_history + {} + + + + + + + + + + std::unique_ptr< DrawMode > + std::unique_ptr<DrawMode> sk::Canvas::m_drawMode + + m_drawMode + {} + + + + + + + + + + std::unique_ptr< AbstractNetwork > + std::unique_ptr<AbstractNetwork> sk::Canvas::m_network + + m_network + { nullptr } + + + + + + + + + + QColor + QColor sk::Canvas::m_foreignColor + + m_foreignColor + { DrawMode::getDefaultColor() } + + + + + + + + + + int + int sk::Canvas::m_foreignWidth + + m_foreignWidth + { DrawMode::getDefaultWidth() } + + + + + + + + + + + + + sk::Canvas::Canvas + (QQuickPaintedItem *parent=nullptr) + Canvas + + QQuickPaintedItem * + parent + nullptr + + + + + + + + + + + + sk::Canvas::Canvas + (Canvas const &)=delete + Canvas + + Canvas const & + + + + + + + + + + + + sk::Canvas::Canvas + (Canvas &&)=delete + Canvas + + Canvas && + + + + + + + + + + + + sk::Canvas::~Canvas + () noexcept override=default + ~Canvas + + + + + + + + + + auto + auto sk::Canvas::operator= + (Canvas const &)=delete + operator= + + Canvas const & + + + + + + + + + + + auto + auto sk::Canvas::operator= + (Canvas &&)=delete + operator= + + Canvas && + + + + + + + + + + + auto + auto sk::Canvas::paint + (QPainter *painter) -> void override + paint + + QPainter * + painter + + + + +Draws the canvas. + + + + + + + + + void + auto sk::Canvas::mousePositionChanged + (QPoint const &pos) + mousePositionChanged + + QPoint const & + pos + + + + +This triggers a paint event on the canvas. + + + + + + + void + auto sk::Canvas::mouseReleased + () + mouseReleased + + + +This triggers 'creating a new layer' event. + + + + + + + void + auto sk::Canvas::undo + () + undo + + + +This goes back to the previously stored layer. + + + + + + + void + auto sk::Canvas::redo + () + redo + + + +Opposite of undo. + + + + + + + void + auto sk::Canvas::onReceivedMessage + (QString const &msg) + onReceivedMessage + + QString const & + msg + + + + +Called when a message through the network is received. Also handles the actual events that were received. + + + + + + + void + auto sk::Canvas::changeColor + (QColor const &color) + changeColor + + QColor const & + color + + + + +Changes the color of the pen/brush to draw with. + + + + + + + void + auto sk::Canvas::changeWidth + (const int width) + changeWidth + + const int + width + + + + +Changes the size of the brush/pen. + + + + + + + +The class where all the magic happens. + + +This contains all behaviour related to painting itself. +All of mousePositionChanged, mouseReleased, undo, redo, changeColor, changeWidth are signals that other than modifying the local canvas accordingly, they also send the event over the network to the other user. + + + + + + + + + + + + + + + + + + + + + + + + + + sk::CanvasCanvas + sk::CanvasCanvas + sk::CanvasCanvas + sk::CanvaschangeColor + sk::CanvaschangeWidth + sk::Canvasm_drawMode + sk::Canvasm_foreignColor + sk::Canvasm_foreignWidth + sk::Canvasm_history + sk::Canvasm_network + sk::CanvasmousePositionChanged + sk::CanvasmouseReleased + sk::CanvasonReceivedMessage + sk::Canvasoperator= + sk::Canvasoperator= + sk::Canvaspaint + sk::Canvasredo + sk::Canvasundo + sk::Canvas~Canvas + + + diff --git a/docs/classsk_1_1Canvas__coll__graph.map b/docs/classsk_1_1Canvas__coll__graph.map deleted file mode 100644 index cf3141c..0000000 --- a/docs/classsk_1_1Canvas__coll__graph.map +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/docs/classsk_1_1Canvas__coll__graph.md5 b/docs/classsk_1_1Canvas__coll__graph.md5 deleted file mode 100644 index 9f4f345..0000000 --- a/docs/classsk_1_1Canvas__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -af800820789fb99d1df9b5eb74ab020f \ No newline at end of file diff --git a/docs/classsk_1_1Canvas__coll__graph.png b/docs/classsk_1_1Canvas__coll__graph.png deleted file mode 100644 index 2b11800..0000000 Binary files a/docs/classsk_1_1Canvas__coll__graph.png and /dev/null differ diff --git a/docs/classsk_1_1Canvas__inherit__graph.map b/docs/classsk_1_1Canvas__inherit__graph.map deleted file mode 100644 index cf3141c..0000000 --- a/docs/classsk_1_1Canvas__inherit__graph.map +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/docs/classsk_1_1Canvas__inherit__graph.md5 b/docs/classsk_1_1Canvas__inherit__graph.md5 deleted file mode 100644 index 9f4f345..0000000 --- a/docs/classsk_1_1Canvas__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -af800820789fb99d1df9b5eb74ab020f \ No newline at end of file diff --git a/docs/classsk_1_1Canvas__inherit__graph.png b/docs/classsk_1_1Canvas__inherit__graph.png deleted file mode 100644 index 2b11800..0000000 Binary files a/docs/classsk_1_1Canvas__inherit__graph.png and /dev/null differ diff --git a/docs/classsk_1_1Client-members.html b/docs/classsk_1_1Client-members.html deleted file mode 100644 index 6471a68..0000000 --- a/docs/classsk_1_1Client-members.html +++ /dev/null @@ -1,106 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::Client Member List
-
-
- -

This is the complete list of members for sk::Client, including all inherited members.

- - - - - - - - - - - - - - - - - - - - - - - -
AbstractNetwork(QObject *parent=nullptr) (defined in sk::AbstractNetwork)sk::AbstractNetworkexplicit
AbstractNetwork(AbstractNetwork const &)=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
AbstractNetwork(AbstractNetwork &&) noexcept=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
Client(QString const &ip) (defined in sk::Client)sk::Clientexplicit
Client(Client const &)=delete (defined in sk::Client)sk::Client
Client(Client &&)=delete (defined in sk::Client)sk::Client
getSocket() -> QTcpSocket *override (defined in sk::Client)sk::Clientvirtual
operator=(Client const &)=delete (defined in sk::Client)sk::Client
operator=(Client &&)=delete (defined in sk::Client)sk::Client
operator=(AbstractNetwork const &) -> AbstractNetwork &=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
operator=(AbstractNetwork &&) noexcept -> AbstractNetwork &=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
receivedMessage(QString const &msg) (defined in sk::AbstractNetwork)sk::AbstractNetworksignal
sendChangeColor(QColor const &color) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendChangeWidth(int const width) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendDrawAt(QPoint const &pos) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendMouseReleased() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendRedo() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendToBrush() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendToPen() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendUndo() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
~AbstractNetwork() noexcept override=default (defined in sk::AbstractNetwork)sk::AbstractNetwork
~Client() noexcept override (defined in sk::Client)sk::Client
- - - - diff --git a/docs/classsk_1_1Client.html b/docs/classsk_1_1Client.html index 31b4e3a..91bf854 100644 --- a/docs/classsk_1_1Client.html +++ b/docs/classsk_1_1Client.html @@ -1,180 +1,140 @@ - - + + - - - - -Skribble: sk::Client Class Reference - - - - - - - + + sk::Client class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ sk::Client class final +

+

Implements AbstractNetwork for a client.

+
+

Contents

+ +
+
+

Base classes

+
+
+ class AbstractNetwork +
+
Contains all common events for a client/server.
+
+
+
+

Public functions

+
+
+ auto getSocket() -> QTcpSocket * -> auto override +
+
Helper to get current connection.
+
+
+
+

Function documentation

+
+

+ auto sk::Client::getSocket() -> QTcpSocket * override +

+

Helper to get current connection.

+

If the app was started as a server, this returns the client 'connection', If the app was started as a client, this 'returns' the server, otherwise it simply returns nullptr.

+
+
+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::Client Class Referencefinal
-
-
-
-Inheritance diagram for sk::Client:
-
-
Inheritance graph
- - - - - -
[legend]
-
-Collaboration diagram for sk::Client:
-
-
Collaboration graph
- - - - - -
[legend]
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

Client (QString const &ip)
 
Client (Client const &)=delete
 
Client (Client &&)=delete
 
-auto operator= (Client const &)=delete
 
-auto operator= (Client &&)=delete
 
-auto getSocket () -> QTcpSocket *override
 
- Public Member Functions inherited from sk::AbstractNetwork
AbstractNetwork (QObject *parent=nullptr)
 
AbstractNetwork (AbstractNetwork const &)=delete
 
AbstractNetwork (AbstractNetwork &&) noexcept=delete
 
-auto operator= (AbstractNetwork const &) -> AbstractNetwork &=delete
 
-auto operator= (AbstractNetwork &&) noexcept -> AbstractNetwork &=delete
 
-auto sendDrawAt (QPoint const &pos) -> void
 
-auto sendMouseReleased () -> void
 
-auto sendUndo () -> void
 
-auto sendRedo () -> void
 
-auto sendChangeColor (QColor const &color) -> void
 
-auto sendChangeWidth (int const width) -> void
 
-auto sendToPen () -> void
 
-auto sendToBrush () -> void
 
- - - - -

-Additional Inherited Members

- Signals inherited from sk::AbstractNetwork
-void receivedMessage (QString const &msg)
 
-

Detailed Description

-
-

Definition at line 14 of file client.hpp.

-

The documentation for this class was generated from the following files: -
- - + + +
diff --git a/docs/classsk_1_1Client.xml b/docs/classsk_1_1Client.xml new file mode 100644 index 0000000..92cdf4c --- /dev/null +++ b/docs/classsk_1_1Client.xml @@ -0,0 +1,201 @@ + + + + sk::Client + sk::AbstractNetwork + client.hpp + + + std::unique_ptr< QTcpSocket > + std::unique_ptr<QTcpSocket> sk::Client::m_server + + m_server + { nullptr } + + + + + + + + + + + + + sk::Client::Client + (QString const &ip) + Client + + QString const & + ip + + + + + + + + + + + + sk::Client::Client + (Client const &)=delete + Client + + Client const & + + + + + + + + + + + + sk::Client::Client + (Client &&)=delete + Client + + Client && + + + + + + + + + + + + sk::Client::~Client + () noexcept override + ~Client + + + + + + + + + + auto + auto sk::Client::operator= + (Client const &)=delete + operator= + + Client const & + + + + + + + + + + + auto + auto sk::Client::operator= + (Client &&)=delete + operator= + + Client && + + + + + + + + + + + auto + auto sk::Client::getSocket + () -> QTcpSocket *override + getSocket + getSocket + +Helper to get current connection. + + +If the app was started as a server, this returns the client 'connection', If the app was started as a client, this 'returns' the server, otherwise it simply returns nullptr. + + + + + + + +Implements AbstractNetwork for a client. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::ClientAbstractNetwork + sk::ClientAbstractNetwork + sk::ClientAbstractNetwork + sk::ClientClient + sk::ClientClient + sk::ClientClient + sk::ClientgetSocket + sk::Clientm_server + sk::Clientoperator= + sk::Clientoperator= + sk::Clientoperator= + sk::Clientoperator= + sk::ClientreceivedMessage + sk::ClientsendChangeColor + sk::ClientsendChangeWidth + sk::ClientsendDrawAt + sk::ClientsendMouseReleased + sk::ClientsendRedo + sk::ClientsendToBrush + sk::ClientsendToPen + sk::ClientsendUndo + sk::Client~AbstractNetwork + sk::Client~Client + + + diff --git a/docs/classsk_1_1Client__coll__graph.map b/docs/classsk_1_1Client__coll__graph.map deleted file mode 100644 index ad6f5cf..0000000 --- a/docs/classsk_1_1Client__coll__graph.map +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/docs/classsk_1_1Client__coll__graph.md5 b/docs/classsk_1_1Client__coll__graph.md5 deleted file mode 100644 index 238b729..0000000 --- a/docs/classsk_1_1Client__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -9178e2242827a687c8728c3b29d0e83f \ No newline at end of file diff --git a/docs/classsk_1_1Client__coll__graph.png b/docs/classsk_1_1Client__coll__graph.png deleted file mode 100644 index 1ca0ee4..0000000 Binary files a/docs/classsk_1_1Client__coll__graph.png and /dev/null differ diff --git a/docs/classsk_1_1Client__inherit__graph.map b/docs/classsk_1_1Client__inherit__graph.map deleted file mode 100644 index ad6f5cf..0000000 --- a/docs/classsk_1_1Client__inherit__graph.map +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/docs/classsk_1_1Client__inherit__graph.md5 b/docs/classsk_1_1Client__inherit__graph.md5 deleted file mode 100644 index 238b729..0000000 --- a/docs/classsk_1_1Client__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -9178e2242827a687c8728c3b29d0e83f \ No newline at end of file diff --git a/docs/classsk_1_1Client__inherit__graph.png b/docs/classsk_1_1Client__inherit__graph.png deleted file mode 100644 index 1ca0ee4..0000000 Binary files a/docs/classsk_1_1Client__inherit__graph.png and /dev/null differ diff --git a/docs/classsk_1_1DrawHistory-members.html b/docs/classsk_1_1DrawHistory-members.html deleted file mode 100644 index 1e8c11c..0000000 --- a/docs/classsk_1_1DrawHistory-members.html +++ /dev/null @@ -1,95 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::DrawHistory Member List
-
-
- -

This is the complete list of members for sk::DrawHistory, including all inherited members.

- - - - - - - - - - - - -
drawAt(QPoint const &pos, DrawMode &mode, bool const foreign=false) -> void (defined in sk::DrawHistory)sk::DrawHistory
DrawHistory() (defined in sk::DrawHistory)sk::DrawHistory
DrawHistory(DrawHistory const &)=delete (defined in sk::DrawHistory)sk::DrawHistory
DrawHistory(DrawHistory &&)=default (defined in sk::DrawHistory)sk::DrawHistory
operator=(DrawHistory const &) -> DrawHistory &=delete (defined in sk::DrawHistory)sk::DrawHistory
operator=(DrawHistory &&) -> DrawHistory &=delete (defined in sk::DrawHistory)sk::DrawHistory
paintCanvas(QPainter *const painter) -> void (defined in sk::DrawHistory)sk::DrawHistory
pushNewLayer(bool const foreign=false) -> void (defined in sk::DrawHistory)sk::DrawHistory
redo(bool const foreign=false) -> void (defined in sk::DrawHistory)sk::DrawHistory
undo(bool const foreign=false) -> void (defined in sk::DrawHistory)sk::DrawHistory
~DrawHistory() noexcept=default (defined in sk::DrawHistory)sk::DrawHistory
- - - - diff --git a/docs/classsk_1_1DrawHistory.html b/docs/classsk_1_1DrawHistory.html index b978c2d..d03f2de 100644 --- a/docs/classsk_1_1DrawHistory.html +++ b/docs/classsk_1_1DrawHistory.html @@ -1,123 +1,147 @@ - - + + - - - - -Skribble: sk::DrawHistory Class Reference - - - - - - - + + sk::DrawHistory class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ sk::DrawHistory class +

+

A manager that correctly stores history about modifications to a canvas, even if multiple users are drawing.

+
+

Contents

+ +
+
+

Public functions

+
+
+ auto pushNewLayer(bool const foreign = false) -> void -> auto +
+
+
+ auto paintCanvas(QPainter*const painter) -> void -> auto +
+
Draws the last layer for each user.
+
+ auto drawAt(QPoint const& pos, + DrawMode& mode, + bool const foreign = false) -> void -> auto +
+
+
+
+
+

Function documentation

+
+

+ auto sk::DrawHistory::pushNewLayer(bool const foreign = false) -> void +

+

Creates a new layer that copies the image of the previous one, being able to draw over it next time. This is how history tracking works.

When multiple users are drawing, there is at most one CachedLayers for each one, limiting the history on frequent alternative drawings, but works well with many consecutive modifications made by one user. This is a tradeoff we've taken since keeping two drawings in sync over the network proved to be way out of our league.

+
+
+

+ auto sk::DrawHistory::drawAt(QPoint const& pos, + DrawMode& mode, + bool const foreign = false) -> void +

+

Just draws with current pen/brush on the canvas on given position.

+
+
+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::DrawHistory Class Reference
-
-
- - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

DrawHistory (DrawHistory const &)=delete
 
DrawHistory (DrawHistory &&)=default
 
-auto operator= (DrawHistory const &) -> DrawHistory &=delete
 
-auto operator= (DrawHistory &&) -> DrawHistory &=delete
 
-auto pushNewLayer (bool const foreign=false) -> void
 
-auto paintCanvas (QPainter *const painter) -> void
 
-auto drawAt (QPoint const &pos, DrawMode &mode, bool const foreign=false) -> void
 
-auto undo (bool const foreign=false) -> void
 
-auto redo (bool const foreign=false) -> void
 
-

Detailed Description

-
-

Definition at line 78 of file draw_history.hpp.

-

The documentation for this class was generated from the following files: -
- - + + +
diff --git a/docs/classsk_1_1DrawHistory.xml b/docs/classsk_1_1DrawHistory.xml new file mode 100644 index 0000000..e3a70d2 --- /dev/null +++ b/docs/classsk_1_1DrawHistory.xml @@ -0,0 +1,400 @@ + + + + sk::DrawHistory + draw_history.hpp + sk::DrawHistory::Traits + + + std::list< impl::CachedLayers > + std::list<impl::CachedLayers> sk::DrawHistory::m_layers + + m_layers + {} + + + + + + + + + + sk::CachedResource< impl::CachedLayers > + sk::CachedResource<impl::CachedLayers> sk::DrawHistory::m_cache + + m_cache + {} + + + + + + + + + + std::optional< QPoint > + std::optional<QPoint> sk::DrawHistory::m_lastPoint + + m_lastPoint + { std::nullopt } + + + + + + + + + + std::optional< QPoint > + std::optional<QPoint> sk::DrawHistory::m_lastExternalPoint + + m_lastExternalPoint + { std::nullopt } + + + + + + + + + + bool + bool sk::DrawHistory::m_drawingLocally + + m_drawingLocally + { false } + + + + + + + + + + bool + bool sk::DrawHistory::m_drawingExternally + + m_drawingExternally + { false } + + + + + + + + + + + + auto + auto sk::DrawHistory::CachedDrawer + (impl::CachedLayers &dest, impl::CachedLayers &src) -> void + CachedDrawer + + impl::CachedLayers & + dest + + + impl::CachedLayers & + src + + + + + + + + + + + + + auto + auto sk::DrawHistory::handleExternal + (QPoint const &pos, DrawMode &mode) -> void + handleExternal + + QPoint const & + pos + + + DrawMode & + mode + + + + + + + + + + + auto + auto sk::DrawHistory::handleLocal + (QPoint const &pos, DrawMode &mode) -> void + handleLocal + + QPoint const & + pos + + + DrawMode & + mode + + + + + + + + + + + auto + auto sk::DrawHistory::popFirst + (bool const foreign) -> void + popFirst + + bool const + foreign + + + + + + + + + + + + + + sk::DrawHistory::DrawHistory + () + DrawHistory + + + + + + + + + + + sk::DrawHistory::DrawHistory + (DrawHistory const &)=delete + DrawHistory + + DrawHistory const & + + + + + + + + + + + + sk::DrawHistory::DrawHistory + (DrawHistory &&)=default + DrawHistory + + DrawHistory && + + + + + + + + + + + + sk::DrawHistory::~DrawHistory + () noexcept=default + ~DrawHistory + + + + + + + + + + auto + auto sk::DrawHistory::operator= + (DrawHistory const &) -> DrawHistory &=delete + operator= + + DrawHistory const & + + + + + + + + + + + auto + auto sk::DrawHistory::operator= + (DrawHistory &&) -> DrawHistory &=delete + operator= + + DrawHistory && + + + + + + + + + + + auto + auto sk::DrawHistory::pushNewLayer + (bool const foreign=false) -> void + pushNewLayer + + bool const + foreign + false + + + + +Creates a new layer that copies the image of the previous one, being able to draw over it next time. This is how history tracking works. +When multiple users are drawing, there is at most one CachedLayers for each one, limiting the history on frequent alternative drawings, but works well with many consecutive modifications made by one user. This is a tradeoff we've taken since keeping two drawings in sync over the network proved to be way out of our league. + + + + + + + auto + auto sk::DrawHistory::paintCanvas + (QPainter *const painter) -> void + paintCanvas + + QPainter *const + painter + + +Draws the last layer for each user. + + + + + + + + + auto + auto sk::DrawHistory::drawAt + (QPoint const &pos, DrawMode &mode, bool const foreign=false) -> void + drawAt + + QPoint const & + pos + + + DrawMode & + mode + + + bool const + foreign + false + + + + +Just draws with current pen/brush on the canvas on given position. + + + + + + + auto + auto sk::DrawHistory::undo + (bool const foreign=false) -> void + undo + + bool const + foreign + false + + + + + + + + + + + auto + auto sk::DrawHistory::redo + (bool const foreign=false) -> void + redo + + bool const + foreign + false + + + + + + + + + + + +A manager that correctly stores history about modifications to a canvas, even if multiple users are drawing. + + + + + + sk::DrawHistoryCachedDrawer + sk::DrawHistorydrawAt + sk::DrawHistoryDrawHistory + sk::DrawHistoryDrawHistory + sk::DrawHistoryDrawHistory + sk::DrawHistoryhandleExternal + sk::DrawHistoryhandleLocal + sk::DrawHistorym_cache + sk::DrawHistorym_drawingExternally + sk::DrawHistorym_drawingLocally + sk::DrawHistorym_lastExternalPoint + sk::DrawHistorym_lastPoint + sk::DrawHistorym_layers + sk::DrawHistoryoperator= + sk::DrawHistoryoperator= + sk::DrawHistorypaintCanvas + sk::DrawHistorypopFirst + sk::DrawHistorypushNewLayer + sk::DrawHistoryredo + sk::DrawHistoryundo + sk::DrawHistory~DrawHistory + + + diff --git a/docs/classsk_1_1DrawMode-members.html b/docs/classsk_1_1DrawMode-members.html deleted file mode 100644 index 60e05e3..0000000 --- a/docs/classsk_1_1DrawMode-members.html +++ /dev/null @@ -1,101 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::DrawMode Member List
-
-
- -

This is the complete list of members for sk::DrawMode, including all inherited members.

- - - - - - - - - - - - - - - - - - -
draw(QPainter &painter, QPoint const &pos, std::optional< QPoint > const &lastPoint) -> void=0 (defined in sk::DrawMode)sk::DrawModepure virtual
DrawMode() noexcept=default (defined in sk::DrawMode)sk::DrawMode
DrawMode(DrawMode const &) noexcept=default (defined in sk::DrawMode)sk::DrawMode
DrawMode(DrawMode &&) noexcept=default (defined in sk::DrawMode)sk::DrawMode
getColor() const noexcept -> QColor (defined in sk::DrawMode)sk::DrawModeinline
getDefaultColor() noexcept -> QColor (defined in sk::DrawMode)sk::DrawModeinlinestatic
getDefaultWidth() noexcept -> int (defined in sk::DrawMode)sk::DrawModeinlinestatic
getWidth() const noexcept -> int (defined in sk::DrawMode)sk::DrawModeinline
m_color (defined in sk::DrawMode)sk::DrawModeprotectedstatic
m_defaultColor (defined in sk::DrawMode)sk::DrawModeprotectedstatic
m_defaultWidth (defined in sk::DrawMode)sk::DrawModeprotectedstatic
m_width (defined in sk::DrawMode)sk::DrawModeprotectedstatic
operator=(DrawMode const &) noexcept -> DrawMode &=default (defined in sk::DrawMode)sk::DrawMode
operator=(DrawMode &&) noexcept -> DrawMode &=default (defined in sk::DrawMode)sk::DrawMode
setColor(QColor const &color) noexcept -> void (defined in sk::DrawMode)sk::DrawModeinline
setWidth(int const width) noexcept -> void (defined in sk::DrawMode)sk::DrawModeinline
~DrawMode() noexcept=default (defined in sk::DrawMode)sk::DrawModevirtual
- - - - diff --git a/docs/classsk_1_1DrawMode.html b/docs/classsk_1_1DrawMode.html index aa9ed9c..faf6b7b 100644 --- a/docs/classsk_1_1DrawMode.html +++ b/docs/classsk_1_1DrawMode.html @@ -1,158 +1,161 @@ - - + + - - - - -Skribble: sk::DrawMode Class Reference - - - - - - - + + sk::DrawMode class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ sk::DrawMode class +

+

Defines methods for drawing with different instruments.

+
+

Contents

+ +
+

Currently: BrushMode and PenMode.

+
+

Derived classes

+
+
+ class BrushMode +
+
Implements drawing with a brush.
+
+ class PenMode +
+
Implements drawing with a pen.
+
+
+
+

Public static functions

+
+
+ static auto getDefaultColor() noexcept -> QColor -> auto constexpr +
+
Tools start out with this color.
+
+ static auto getDefaultWidth() noexcept -> int -> auto constexpr +
+
Tools start out with this size.
+
+
+
+

Public functions

+
+
+ auto getWidth() const noexcept -> int -> auto +
+
Gets size of tool.
+
+ auto setWidth(int const width) noexcept -> void -> auto +
+
Changes size of tool.
+
+ auto getColor() const noexcept -> QColor -> auto +
+
Gets color of tool.
+
+ auto setColor(QColor const& color) noexcept -> void -> auto +
+
Sets color of tool.
+
+
+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
- -
-
-Inheritance diagram for sk::DrawMode:
-
-
Inheritance graph
- - - - - -
[legend]
- - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

DrawMode (DrawMode const &) noexcept=default
 
DrawMode (DrawMode &&) noexcept=default
 
-auto operator= (DrawMode const &) noexcept -> DrawMode &=default
 
-auto operator= (DrawMode &&) noexcept -> DrawMode &=default
 
-virtual auto draw (QPainter &painter, QPoint const &pos, std::optional< QPoint > const &lastPoint) -> void=0
 
-auto getWidth () const noexcept -> int
 
-auto setWidth (int const width) noexcept -> void
 
-auto getColor () const noexcept -> QColor
 
-auto setColor (QColor const &color) noexcept -> void
 
- - - - - -

-Static Public Member Functions

-static constexpr auto getDefaultColor () noexcept -> QColor
 
-static constexpr auto getDefaultWidth () noexcept -> int
 
- - - - - - - - - -

-Static Protected Attributes

-static constexpr int m_defaultWidth = 5
 
-static constexpr QColor m_defaultColor { 0, 0, 0 }
 
-static int m_width = DrawMode::m_defaultWidth
 
-static QColor m_color = DrawMode::m_defaultColor
 
-

Detailed Description

-
-

Definition at line 17 of file draw_mode.hpp.

-

The documentation for this class was generated from the following files: -
- - + + +
diff --git a/docs/classsk_1_1DrawMode.xml b/docs/classsk_1_1DrawMode.xml new file mode 100644 index 0000000..5b9a66a --- /dev/null +++ b/docs/classsk_1_1DrawMode.xml @@ -0,0 +1,324 @@ + + + + sk::DrawMode + sk::BrushMode + sk::PenMode + draw_mode.hpp + + + constexpr int + constexpr int sk::DrawMode::m_defaultWidth + + m_defaultWidth + = 5 + + + + + + + + + + constexpr QColor + constexpr QColor sk::DrawMode::m_defaultColor + + m_defaultColor + { 0, 0, 0 } + + + + + + + + + + int + int sk::DrawMode::m_width + + m_width + = DrawMode::m_defaultWidth + + + + + + + + + + QColor + QColor sk::DrawMode::m_color + + m_color + = DrawMode::m_defaultColor + + + + + + + + + + + + + sk::DrawMode::DrawMode + () noexcept=default + DrawMode + + + + + + + + + + + sk::DrawMode::DrawMode + (DrawMode const &) noexcept=default + DrawMode + + DrawMode const & + + + + + + + + + + + + sk::DrawMode::DrawMode + (DrawMode &&) noexcept=default + DrawMode + + DrawMode && + + + + + + + + + + + + virtual sk::DrawMode::~DrawMode + () noexcept=default + ~DrawMode + + + + + + + + + + auto + auto sk::DrawMode::operator= + (DrawMode const &) noexcept -> DrawMode &=default + operator= + + DrawMode const & + + + + + + + + + + + auto + auto sk::DrawMode::operator= + (DrawMode &&) noexcept -> DrawMode &=default + operator= + + DrawMode && + + + + + + + + + + + auto + virtual auto sk::DrawMode::draw + (QPainter &painter, QPoint const &pos, std::optional< QPoint > const &lastPoint) -> void=0 + draw + draw + draw + + QPainter & + painter + + + QPoint const & + pos + + + std::optional< QPoint > const & + lastPoint + + + + + + + + + + + auto + auto sk::DrawMode::getWidth + () const noexcept -> int + getWidth + +Gets size of tool. + + + + + + + + + auto + auto sk::DrawMode::setWidth + (int const width) noexcept -> void + setWidth + + int const + width + + +Changes size of tool. + + + + + + + + + auto + auto sk::DrawMode::getColor + () const noexcept -> QColor + getColor + +Gets color of tool. + + + + + + + + + auto + auto sk::DrawMode::setColor + (QColor const &color) noexcept -> void + setColor + + QColor const & + color + + +Sets color of tool. + + + + + + + + + + + constexpr auto + static constexpr auto sk::DrawMode::getDefaultColor + () noexcept -> QColor + getDefaultColor + +Tools start out with this color. + + + + + + + + + constexpr auto + static constexpr auto sk::DrawMode::getDefaultWidth + () noexcept -> int + getDefaultWidth + +Tools start out with this size. + + + + + + + + + +Defines methods for drawing with different instruments. + + +Currently: BrushMode and PenMode. + + + + + + + + + + + + + + + + + + + + + + sk::DrawModedraw + sk::DrawModeDrawMode + sk::DrawModeDrawMode + sk::DrawModeDrawMode + sk::DrawModegetColor + sk::DrawModegetDefaultColor + sk::DrawModegetDefaultWidth + sk::DrawModegetWidth + sk::DrawModem_color + sk::DrawModem_defaultColor + sk::DrawModem_defaultWidth + sk::DrawModem_width + sk::DrawModeoperator= + sk::DrawModeoperator= + sk::DrawModesetColor + sk::DrawModesetWidth + sk::DrawMode~DrawMode + + + diff --git a/docs/classsk_1_1DrawMode__inherit__graph.map b/docs/classsk_1_1DrawMode__inherit__graph.map deleted file mode 100644 index f375b5e..0000000 --- a/docs/classsk_1_1DrawMode__inherit__graph.map +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/docs/classsk_1_1DrawMode__inherit__graph.md5 b/docs/classsk_1_1DrawMode__inherit__graph.md5 deleted file mode 100644 index 5f26af8..0000000 --- a/docs/classsk_1_1DrawMode__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -1c251045318f1f09f42ecae42051b660 \ No newline at end of file diff --git a/docs/classsk_1_1DrawMode__inherit__graph.png b/docs/classsk_1_1DrawMode__inherit__graph.png deleted file mode 100644 index a9fe0e6..0000000 Binary files a/docs/classsk_1_1DrawMode__inherit__graph.png and /dev/null differ diff --git a/docs/classsk_1_1DummyNetwork-members.html b/docs/classsk_1_1DummyNetwork-members.html deleted file mode 100644 index c35f12c..0000000 --- a/docs/classsk_1_1DummyNetwork-members.html +++ /dev/null @@ -1,106 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::DummyNetwork Member List
-
-
- -

This is the complete list of members for sk::DummyNetwork, including all inherited members.

- - - - - - - - - - - - - - - - - - - - - - - -
AbstractNetwork(QObject *parent=nullptr) (defined in sk::AbstractNetwork)sk::AbstractNetworkexplicit
AbstractNetwork(AbstractNetwork const &)=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
AbstractNetwork(AbstractNetwork &&) noexcept=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
DummyNetwork()=default (defined in sk::DummyNetwork)sk::DummyNetwork
DummyNetwork(DummyNetwork const &)=delete (defined in sk::DummyNetwork)sk::DummyNetwork
DummyNetwork(DummyNetwork &&)=delete (defined in sk::DummyNetwork)sk::DummyNetwork
getSocket() -> QTcpSocket *override (defined in sk::DummyNetwork)sk::DummyNetworkvirtual
operator=(DummyNetwork const &) -> DummyNetwork &=delete (defined in sk::DummyNetwork)sk::DummyNetwork
operator=(DummyNetwork &&) noexcept -> DummyNetwork &=delete (defined in sk::DummyNetwork)sk::DummyNetwork
operator=(AbstractNetwork const &) -> AbstractNetwork &=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
operator=(AbstractNetwork &&) noexcept -> AbstractNetwork &=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
receivedMessage(QString const &msg) (defined in sk::AbstractNetwork)sk::AbstractNetworksignal
sendChangeColor(QColor const &color) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendChangeWidth(int const width) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendDrawAt(QPoint const &pos) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendMouseReleased() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendRedo() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendToBrush() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendToPen() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendUndo() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
~AbstractNetwork() noexcept override=default (defined in sk::AbstractNetwork)sk::AbstractNetwork
~DummyNetwork() noexcept override=default (defined in sk::DummyNetwork)sk::DummyNetwork
- - - - diff --git a/docs/classsk_1_1DummyNetwork.html b/docs/classsk_1_1DummyNetwork.html index 90152d1..5a06290 100644 --- a/docs/classsk_1_1DummyNetwork.html +++ b/docs/classsk_1_1DummyNetwork.html @@ -1,177 +1,140 @@ - - + + - - - - -Skribble: sk::DummyNetwork Class Reference - - - - - - - + + sk::DummyNetwork class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ sk::DummyNetwork class final +

+

Implement AbstractNetwork for single-user mode.

+
+

Contents

+ +
+
+

Base classes

+
+
+ class AbstractNetwork +
+
Contains all common events for a client/server.
+
+
+
+

Public functions

+
+
+ auto getSocket() -> QTcpSocket * -> auto override +
+
Helper to get current connection.
+
+
+
+

Function documentation

+
+

+ auto sk::DummyNetwork::getSocket() -> QTcpSocket * override +

+

Helper to get current connection.

+

If the app was started as a server, this returns the client 'connection', If the app was started as a client, this 'returns' the server, otherwise it simply returns nullptr.

+
+
+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::DummyNetwork Class Referencefinal
-
-
-
-Inheritance diagram for sk::DummyNetwork:
-
-
Inheritance graph
- - - - - -
[legend]
-
-Collaboration diagram for sk::DummyNetwork:
-
-
Collaboration graph
- - - - - -
[legend]
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

DummyNetwork (DummyNetwork const &)=delete
 
DummyNetwork (DummyNetwork &&)=delete
 
-auto operator= (DummyNetwork const &) -> DummyNetwork &=delete
 
-auto operator= (DummyNetwork &&) noexcept -> DummyNetwork &=delete
 
-auto getSocket () -> QTcpSocket *override
 
- Public Member Functions inherited from sk::AbstractNetwork
AbstractNetwork (QObject *parent=nullptr)
 
AbstractNetwork (AbstractNetwork const &)=delete
 
AbstractNetwork (AbstractNetwork &&) noexcept=delete
 
-auto operator= (AbstractNetwork const &) -> AbstractNetwork &=delete
 
-auto operator= (AbstractNetwork &&) noexcept -> AbstractNetwork &=delete
 
-auto sendDrawAt (QPoint const &pos) -> void
 
-auto sendMouseReleased () -> void
 
-auto sendUndo () -> void
 
-auto sendRedo () -> void
 
-auto sendChangeColor (QColor const &color) -> void
 
-auto sendChangeWidth (int const width) -> void
 
-auto sendToPen () -> void
 
-auto sendToBrush () -> void
 
- - - - -

-Additional Inherited Members

- Signals inherited from sk::AbstractNetwork
-void receivedMessage (QString const &msg)
 
-

Detailed Description

-
-

Definition at line 11 of file dummy_network.hpp.

-

The documentation for this class was generated from the following files: -
- - + + +
diff --git a/docs/classsk_1_1DummyNetwork.xml b/docs/classsk_1_1DummyNetwork.xml new file mode 100644 index 0000000..2150a28 --- /dev/null +++ b/docs/classsk_1_1DummyNetwork.xml @@ -0,0 +1,180 @@ + + + + sk::DummyNetwork + sk::AbstractNetwork + dummy_network.hpp + + + + sk::DummyNetwork::DummyNetwork + ()=default + DummyNetwork + + + + + + + + + + + sk::DummyNetwork::DummyNetwork + (DummyNetwork const &)=delete + DummyNetwork + + DummyNetwork const & + + + + + + + + + + + + sk::DummyNetwork::DummyNetwork + (DummyNetwork &&)=delete + DummyNetwork + + DummyNetwork && + + + + + + + + + + + + sk::DummyNetwork::~DummyNetwork + () noexcept override=default + ~DummyNetwork + + + + + + + + + + auto + auto sk::DummyNetwork::operator= + (DummyNetwork const &) -> DummyNetwork &=delete + operator= + + DummyNetwork const & + + + + + + + + + + + auto + auto sk::DummyNetwork::operator= + (DummyNetwork &&) noexcept -> DummyNetwork &=delete + operator= + + DummyNetwork && + + + + + + + + + + + auto + auto sk::DummyNetwork::getSocket + () -> QTcpSocket *override + getSocket + getSocket + +Helper to get current connection. + + +If the app was started as a server, this returns the client 'connection', If the app was started as a client, this 'returns' the server, otherwise it simply returns nullptr. + + + + + + + +Implement AbstractNetwork for single-user mode. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::DummyNetworkAbstractNetwork + sk::DummyNetworkAbstractNetwork + sk::DummyNetworkAbstractNetwork + sk::DummyNetworkDummyNetwork + sk::DummyNetworkDummyNetwork + sk::DummyNetworkDummyNetwork + sk::DummyNetworkgetSocket + sk::DummyNetworkoperator= + sk::DummyNetworkoperator= + sk::DummyNetworkoperator= + sk::DummyNetworkoperator= + sk::DummyNetworkreceivedMessage + sk::DummyNetworksendChangeColor + sk::DummyNetworksendChangeWidth + sk::DummyNetworksendDrawAt + sk::DummyNetworksendMouseReleased + sk::DummyNetworksendRedo + sk::DummyNetworksendToBrush + sk::DummyNetworksendToPen + sk::DummyNetworksendUndo + sk::DummyNetwork~AbstractNetwork + sk::DummyNetwork~DummyNetwork + + + diff --git a/docs/classsk_1_1DummyNetwork__coll__graph.map b/docs/classsk_1_1DummyNetwork__coll__graph.map deleted file mode 100644 index ee5e4e0..0000000 --- a/docs/classsk_1_1DummyNetwork__coll__graph.map +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/docs/classsk_1_1DummyNetwork__coll__graph.md5 b/docs/classsk_1_1DummyNetwork__coll__graph.md5 deleted file mode 100644 index a9b108e..0000000 --- a/docs/classsk_1_1DummyNetwork__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -3a7f2e5c30aa6bcbebc2b2ae21734a4a \ No newline at end of file diff --git a/docs/classsk_1_1DummyNetwork__coll__graph.png b/docs/classsk_1_1DummyNetwork__coll__graph.png deleted file mode 100644 index aee2e69..0000000 Binary files a/docs/classsk_1_1DummyNetwork__coll__graph.png and /dev/null differ diff --git a/docs/classsk_1_1DummyNetwork__inherit__graph.map b/docs/classsk_1_1DummyNetwork__inherit__graph.map deleted file mode 100644 index ee5e4e0..0000000 --- a/docs/classsk_1_1DummyNetwork__inherit__graph.map +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/docs/classsk_1_1DummyNetwork__inherit__graph.md5 b/docs/classsk_1_1DummyNetwork__inherit__graph.md5 deleted file mode 100644 index a9b108e..0000000 --- a/docs/classsk_1_1DummyNetwork__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -3a7f2e5c30aa6bcbebc2b2ae21734a4a \ No newline at end of file diff --git a/docs/classsk_1_1DummyNetwork__inherit__graph.png b/docs/classsk_1_1DummyNetwork__inherit__graph.png deleted file mode 100644 index aee2e69..0000000 Binary files a/docs/classsk_1_1DummyNetwork__inherit__graph.png and /dev/null differ diff --git a/docs/classsk_1_1FCachedResource-members.html b/docs/classsk_1_1FCachedResource-members.html deleted file mode 100644 index a28a457..0000000 --- a/docs/classsk_1_1FCachedResource-members.html +++ /dev/null @@ -1,99 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::FCachedResource< T, Traits > Member List
-
-
- -

This is the complete list of members for sk::FCachedResource< T, Traits >, including all inherited members.

- - - - - - - - - - - - - - - - -
emplaceBack(Ts &&... args) -> T & (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >inline
FCachedResource()=delete (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >
FCachedResource(FCachedResource const &)=default (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >
FCachedResource(FCachedResource &&) noexcept=default (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >
FCachedResource(Function f, InitFunction init) (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >inlineexplicit
get() noexcept -> T & (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >inline
get() const noexcept -> T const & (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >inline
getUnderlying() noexcept -> ContainerType & (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >inline
getUnderlying() const noexcept -> ContainerType const & (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >inline
operator=(FCachedResource const &) -> FCachedResource &=default (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >
operator=(FCachedResource &&) noexcept -> FCachedResource &=default (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >
redo() -> bool (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >inline
underUndo() const noexcept -> bool (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >inline
undo() -> bool (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >inline
~FCachedResource() noexcept=default (defined in sk::FCachedResource< T, Traits >)sk::FCachedResource< T, Traits >
- - - - diff --git a/docs/classsk_1_1FCachedResource.html b/docs/classsk_1_1FCachedResource.html index 9638953..91361ba 100644 --- a/docs/classsk_1_1FCachedResource.html +++ b/docs/classsk_1_1FCachedResource.html @@ -1,137 +1,205 @@ - - + + - - - - -Skribble: sk::FCachedResource< T, Traits > Class Template Reference - - - - - - - + + sk::FCachedResource class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+
template<typename T, typename Traits = FResTraits<T>>
+ sk::FCachedResource class +

+

Class that manages undo/redo.

+
+

Contents

+ +
+
+

Public functions

+
+
+
template<typename... Ts>
+ auto emplaceBack(Ts && ... args) -> T & -> auto +
+
+
+ auto underUndo() const noexcept -> bool -> auto +
+
+
+ auto get() noexcept -> T & -> auto +
+
Gets the current layer.
+
+ auto get() const noexcept -> T const & -> auto +
+
Gets the current layer as constant.
+
+ auto undo() -> bool -> auto +
+
+
+ auto redo() -> bool -> auto +
+
+
+
+
+

Function documentation

+
+

+
+ template<typename T, typename Traits> + template<typename... Ts> +
+ auto sk::FCachedResource<T, Traits>::emplaceBack(Ts && ... args) -> T & +

+

Pushes a new layer in the list of layers, deleting layers at the front if history limit has been reached.

+
+
+

+
+ template<typename T, typename Traits> +
+ auto sk::FCachedResource<T, Traits>::underUndo() const noexcept -> bool +

+ + + + + + + +
Returnstrue If undo was called more times than redo.
+
+
+

+
+ template<typename T, typename Traits> +
+ auto sk::FCachedResource<T, Traits>::undo() -> bool +

+ + + + + + + +
Returnsfalse If undo is no longer possible.
+

Current layer becomes std::prev(current_layer_iterator).

+
+
+

+
+ template<typename T, typename Traits> +
+ auto sk::FCachedResource<T, Traits>::redo() -> bool +

+ + + + + + + +
Returnsfalse If redo is no longer possible.
+

Current layer becomes std::next(current_layer_iterator).

+
+
+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::FCachedResource< T, Traits > Class Template Reference
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

FCachedResource (FCachedResource const &)=default
 
FCachedResource (FCachedResource &&) noexcept=default
 
FCachedResource (Function f, InitFunction init)
 
-auto operator= (FCachedResource const &) -> FCachedResource &=default
 
-auto operator= (FCachedResource &&) noexcept -> FCachedResource &=default
 
-template<typename... Ts>
auto emplaceBack (Ts &&... args) -> T &
 
-auto underUndo () const noexcept -> bool
 
-auto get () noexcept -> T &
 
-auto get () const noexcept -> T const &
 
-auto undo () -> bool
 
-auto redo () -> bool
 
-auto getUnderlying () noexcept -> ContainerType &
 
-auto getUnderlying () const noexcept -> ContainerType const &
 
-

Detailed Description

-

template<typename T, typename Traits = FResTraits<T>>
-class sk::FCachedResource< T, Traits >

- - -

Definition at line 22 of file fixed_cached_resource.hpp.

-

The documentation for this class was generated from the following file: -
- - + + +
diff --git a/docs/classsk_1_1FCachedResource.xml b/docs/classsk_1_1FCachedResource.xml new file mode 100644 index 0000000..e4d67ed --- /dev/null +++ b/docs/classsk_1_1FCachedResource.xml @@ -0,0 +1,433 @@ + + + + sk::FCachedResource + fixed_cached_resource.hpp + + + typename T + + + typename Traits + FResTraits<T> + + + + + typename Traits::ContainerType + using sk::FCachedResource< T, Traits >::ContainerType = typename Traits::ContainerType + + ContainerType + + + + + + + + + + typename ContainerType::iterator + using sk::FCachedResource< T, Traits >::Iterator = typename ContainerType::iterator + + Iterator + + + + + + + + + + void(*)(T &, T &) + using sk::FCachedResource< T, Traits >::Function = void (*)(T&, T&) + + Function + + + + + + + + + + void(*)(T &) + using sk::FCachedResource< T, Traits >::InitFunction = void (*)(T&) + + InitFunction + + + + + + + + + + + + constexpr int + constexpr int sk::FCachedResource< T, Traits >::m_maxCount + + m_maxCount + = Traits::maxCount + + + + + + + + + + + + ContainerType + ContainerType sk::FCachedResource< T, Traits >::m_data + + m_data + {} + + + + + + + + + + Iterator + Iterator sk::FCachedResource< T, Traits >::m_iterator + + m_iterator + {} + + + + + + + + + + Function + Function sk::FCachedResource< T, Traits >::m_function + + m_function + {} + + + + + + + + + + InitFunction + InitFunction sk::FCachedResource< T, Traits >::m_initFunction + + m_initFunction + {} + + + + + + + + + + bool + bool sk::FCachedResource< T, Traits >::m_underUndo + + m_underUndo + { false } + + + + + + + + + + + + + sk::FCachedResource< T, Traits >::FCachedResource + ()=delete + FCachedResource + + + + + + + + + + + sk::FCachedResource< T, Traits >::FCachedResource + (FCachedResource const &)=default + FCachedResource + + FCachedResource const & + + + + + + + + + + + + sk::FCachedResource< T, Traits >::FCachedResource + (FCachedResource &&) noexcept=default + FCachedResource + + FCachedResource && + + + + + + + + + + + + sk::FCachedResource< T, Traits >::~FCachedResource + () noexcept=default + ~FCachedResource + + + + + + + + + + + sk::FCachedResource< T, Traits >::FCachedResource + (Function f, InitFunction init) + FCachedResource + + Function + f + + + InitFunction + init + + + + + + + + + + + auto + auto sk::FCachedResource< T, Traits >::operator= + (FCachedResource const &) -> FCachedResource &=default + operator= + + FCachedResource const & + + + + + + + + + + + auto + auto sk::FCachedResource< T, Traits >::operator= + (FCachedResource &&) noexcept -> FCachedResource &=default + operator= + + FCachedResource && + + + + + + + + + + + + + typename... + Ts + Ts + + + auto + auto sk::FCachedResource< T, Traits >::emplaceBack + (Ts &&... args) -> T & + emplaceBack + + Ts &&... + args + + + + +Pushes a new layer in the list of layers, deleting layers at the front if history limit has been reached. + + + + + + + auto + auto sk::FCachedResource< T, Traits >::underUndo + () const noexcept -> bool + underUndo + + + +true If undo was called more times than redo. + + + + + + + + + auto + auto sk::FCachedResource< T, Traits >::get + () noexcept -> T & + get + +Gets the current layer. + + + + + + + + + auto + auto sk::FCachedResource< T, Traits >::get + () const noexcept -> T const & + get + +Gets the current layer as constant. + + + + + + + + + auto + auto sk::FCachedResource< T, Traits >::undo + () -> bool + undo + + + +Current layer becomes std::prev(current_layer_iterator). +false If undo is no longer possible. + + + + + + + + + auto + auto sk::FCachedResource< T, Traits >::redo + () -> bool + redo + + + +Current layer becomes std::next(current_layer_iterator). +false If redo is no longer possible. + + + + + + + + + auto + auto sk::FCachedResource< T, Traits >::getUnderlying + () noexcept -> ContainerType & + getUnderlying + + + + + + + + + + auto + auto sk::FCachedResource< T, Traits >::getUnderlying + () const noexcept -> ContainerType const & + getUnderlying + + + + + + + + + + +Class that manages undo/redo. + + + + + + sk::FCachedResourceContainerType + sk::FCachedResourceemplaceBack + sk::FCachedResourceFCachedResource + sk::FCachedResourceFCachedResource + sk::FCachedResourceFCachedResource + sk::FCachedResourceFCachedResource + sk::FCachedResourceFunction + sk::FCachedResourceget + sk::FCachedResourceget + sk::FCachedResourcegetUnderlying + sk::FCachedResourcegetUnderlying + sk::FCachedResourceInitFunction + sk::FCachedResourceIterator + sk::FCachedResourcem_data + sk::FCachedResourcem_function + sk::FCachedResourcem_initFunction + sk::FCachedResourcem_iterator + sk::FCachedResourcem_maxCount + sk::FCachedResourcem_underUndo + sk::FCachedResourceoperator= + sk::FCachedResourceoperator= + sk::FCachedResourceredo + sk::FCachedResourceunderUndo + sk::FCachedResourceundo + sk::FCachedResource~FCachedResource + + + diff --git a/docs/classsk_1_1NetworkFactory-members.html b/docs/classsk_1_1NetworkFactory-members.html deleted file mode 100644 index 86e9ed6..0000000 --- a/docs/classsk_1_1NetworkFactory-members.html +++ /dev/null @@ -1,85 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::NetworkFactory Member List
-
-
- -

This is the complete list of members for sk::NetworkFactory, including all inherited members.

- - -
create(sk::NetworkModes const mode) -> std::unique_ptr< AbstractNetwork > (defined in sk::NetworkFactory)sk::NetworkFactorystatic
- - - - diff --git a/docs/classsk_1_1NetworkFactory.html b/docs/classsk_1_1NetworkFactory.html index a0b54ec..0f38955 100644 --- a/docs/classsk_1_1NetworkFactory.html +++ b/docs/classsk_1_1NetworkFactory.html @@ -1,98 +1,100 @@ - - + + - - - - -Skribble: sk::NetworkFactory Class Reference - - - - - - - + + sk::NetworkFactory class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ sk::NetworkFactory class +

+

Helper implementing Factory design pattern.

+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::NetworkFactory Class Reference
-
-
- - - - -

-Static Public Member Functions

-static auto create (sk::NetworkModes const mode) -> std::unique_ptr< AbstractNetwork >
 
-

Detailed Description

-
-

Definition at line 14 of file network_factory.hpp.

-

The documentation for this class was generated from the following files: -
- - + + +
diff --git a/docs/classsk_1_1NetworkFactory.xml b/docs/classsk_1_1NetworkFactory.xml new file mode 100644 index 0000000..bd4c118 --- /dev/null +++ b/docs/classsk_1_1NetworkFactory.xml @@ -0,0 +1,35 @@ + + + + sk::NetworkFactory + network_factory.hpp + + + auto + auto sk::NetworkFactory::create + (sk::NetworkModes const mode) -> std::unique_ptr< AbstractNetwork > + create + + sk::NetworkModes const + mode + + + + + + + + + + + +Helper implementing Factory design pattern. + + + + + + sk::NetworkFactorycreate + + + diff --git a/docs/classsk_1_1PenMode-members.html b/docs/classsk_1_1PenMode-members.html deleted file mode 100644 index 32aced1..0000000 --- a/docs/classsk_1_1PenMode-members.html +++ /dev/null @@ -1,109 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::PenMode Member List
-
-
- -

This is the complete list of members for sk::PenMode, including all inherited members.

- - - - - - - - - - - - - - - - - - - - - - - - - - -
draw(QPainter &painter, QPoint const &pos, std::optional< QPoint > const &lastPoint) -> void override (defined in sk::PenMode)sk::PenModevirtual
DrawMode() noexcept=default (defined in sk::DrawMode)sk::DrawMode
DrawMode(DrawMode const &) noexcept=default (defined in sk::DrawMode)sk::DrawMode
DrawMode(DrawMode &&) noexcept=default (defined in sk::DrawMode)sk::DrawMode
getColor() const noexcept -> QColor (defined in sk::DrawMode)sk::DrawModeinline
getDefaultColor() noexcept -> QColor (defined in sk::DrawMode)sk::DrawModeinlinestatic
getDefaultWidth() noexcept -> int (defined in sk::DrawMode)sk::DrawModeinlinestatic
getWidth() const noexcept -> int (defined in sk::DrawMode)sk::DrawModeinline
m_color (defined in sk::DrawMode)sk::DrawModeprotectedstatic
m_defaultColor (defined in sk::DrawMode)sk::DrawModeprotectedstatic
m_defaultWidth (defined in sk::DrawMode)sk::DrawModeprotectedstatic
m_width (defined in sk::DrawMode)sk::DrawModeprotectedstatic
operator=(PenMode const &) noexcept -> PenMode &=default (defined in sk::PenMode)sk::PenMode
operator=(PenMode &&) noexcept -> PenMode &=default (defined in sk::PenMode)sk::PenMode
operator=(DrawMode const &) noexcept -> DrawMode &=default (defined in sk::DrawMode)sk::DrawMode
operator=(DrawMode &&) noexcept -> DrawMode &=default (defined in sk::DrawMode)sk::DrawMode
PenMode()=default (defined in sk::PenMode)sk::PenMode
PenMode(PenMode const &) noexcept=default (defined in sk::PenMode)sk::PenMode
PenMode(PenMode &&) noexcept=default (defined in sk::PenMode)sk::PenMode
PenMode(QPen const &pen) (defined in sk::PenMode)sk::PenModeexplicit
PenMode(QPen &&pen) (defined in sk::PenMode)sk::PenModeexplicit
setColor(QColor const &color) noexcept -> void (defined in sk::DrawMode)sk::DrawModeinline
setWidth(int const width) noexcept -> void (defined in sk::DrawMode)sk::DrawModeinline
~DrawMode() noexcept=default (defined in sk::DrawMode)sk::DrawModevirtual
~PenMode() noexcept override=default (defined in sk::PenMode)sk::PenMode
- - - - diff --git a/docs/classsk_1_1PenMode.html b/docs/classsk_1_1PenMode.html index b24ccb7..0d87a51 100644 --- a/docs/classsk_1_1PenMode.html +++ b/docs/classsk_1_1PenMode.html @@ -1,182 +1,109 @@ - - + + - - - - -Skribble: sk::PenMode Class Reference - - - - - - - + + sk::PenMode class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ sk::PenMode class +

+

Implements drawing with a pen.

+
+

Base classes

+
+
+ class DrawMode +
+
Defines methods for drawing with different instruments.
+
+
+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::PenMode Class Reference
-
-
-
-Inheritance diagram for sk::PenMode:
-
-
Inheritance graph
- - - - -
[legend]
-
-Collaboration diagram for sk::PenMode:
-
-
Collaboration graph
- - - - -
[legend]
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

PenMode (PenMode const &) noexcept=default
 
PenMode (PenMode &&) noexcept=default
 
PenMode (QPen const &pen)
 
PenMode (QPen &&pen)
 
-auto operator= (PenMode const &) noexcept -> PenMode &=default
 
-auto operator= (PenMode &&) noexcept -> PenMode &=default
 
-auto draw (QPainter &painter, QPoint const &pos, std::optional< QPoint > const &lastPoint) -> void override
 
- Public Member Functions inherited from sk::DrawMode
DrawMode (DrawMode const &) noexcept=default
 
DrawMode (DrawMode &&) noexcept=default
 
-auto operator= (DrawMode const &) noexcept -> DrawMode &=default
 
-auto operator= (DrawMode &&) noexcept -> DrawMode &=default
 
-auto getWidth () const noexcept -> int
 
-auto setWidth (int const width) noexcept -> void
 
-auto getColor () const noexcept -> QColor
 
-auto setColor (QColor const &color) noexcept -> void
 
- - - - - - - - - - - - - - - -

-Additional Inherited Members

- Static Public Member Functions inherited from sk::DrawMode
-static constexpr auto getDefaultColor () noexcept -> QColor
 
-static constexpr auto getDefaultWidth () noexcept -> int
 
- Static Protected Attributes inherited from sk::DrawMode
-static constexpr int m_defaultWidth = 5
 
-static constexpr QColor m_defaultColor { 0, 0, 0 }
 
-static int m_width = DrawMode::m_defaultWidth
 
-static QColor m_color = DrawMode::m_defaultColor
 
-

Detailed Description

-
-

Definition at line 67 of file draw_mode.hpp.

-

The documentation for this class was generated from the following files: -
- - + + +
diff --git a/docs/classsk_1_1PenMode.xml b/docs/classsk_1_1PenMode.xml new file mode 100644 index 0000000..973270f --- /dev/null +++ b/docs/classsk_1_1PenMode.xml @@ -0,0 +1,238 @@ + + + + sk::PenMode + sk::DrawMode + draw_mode.hpp + + + QPen + QPen sk::PenMode::m_pen + + m_pen + { QColor{ "black" }, + m_defaultWidth, + Qt::SolidLine, + Qt::RoundCap, + Qt::RoundJoin } + + + + + + + + + + + + + sk::PenMode::PenMode + ()=default + PenMode + + + + + + + + + + + sk::PenMode::PenMode + (PenMode const &) noexcept=default + PenMode + + PenMode const & + + + + + + + + + + + + sk::PenMode::PenMode + (PenMode &&) noexcept=default + PenMode + + PenMode && + + + + + + + + + + + + sk::PenMode::~PenMode + () noexcept override=default + ~PenMode + + + + + + + + + + + sk::PenMode::PenMode + (QPen const &pen) + PenMode + + QPen const & + pen + + + + + + + + + + + + sk::PenMode::PenMode + (QPen &&pen) + PenMode + + QPen && + pen + + + + + + + + + + + auto + auto sk::PenMode::operator= + (PenMode const &) noexcept -> PenMode &=default + operator= + + PenMode const & + + + + + + + + + + + auto + auto sk::PenMode::operator= + (PenMode &&) noexcept -> PenMode &=default + operator= + + PenMode && + + + + + + + + + + + auto + auto sk::PenMode::draw + (QPainter &painter, QPoint const &pos, std::optional< QPoint > const &lastPoint) -> void override + draw + draw + + QPainter & + painter + + + QPoint const & + pos + + + std::optional< QPoint > const & + lastPoint + + + + + + + + + + + +Implements drawing with a pen. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::PenModedraw + sk::PenModeDrawMode + sk::PenModeDrawMode + sk::PenModeDrawMode + sk::PenModegetColor + sk::PenModegetDefaultColor + sk::PenModegetDefaultWidth + sk::PenModegetWidth + sk::PenModem_color + sk::PenModem_defaultColor + sk::PenModem_defaultWidth + sk::PenModem_pen + sk::PenModem_width + sk::PenModeoperator= + sk::PenModeoperator= + sk::PenModeoperator= + sk::PenModeoperator= + sk::PenModePenMode + sk::PenModePenMode + sk::PenModePenMode + sk::PenModePenMode + sk::PenModePenMode + sk::PenModesetColor + sk::PenModesetWidth + sk::PenMode~DrawMode + sk::PenMode~PenMode + + + diff --git a/docs/classsk_1_1PenMode__coll__graph.map b/docs/classsk_1_1PenMode__coll__graph.map deleted file mode 100644 index 0934bf0..0000000 --- a/docs/classsk_1_1PenMode__coll__graph.map +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/docs/classsk_1_1PenMode__coll__graph.md5 b/docs/classsk_1_1PenMode__coll__graph.md5 deleted file mode 100644 index 86a264f..0000000 --- a/docs/classsk_1_1PenMode__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -94add1233bfd8ce7a14e3101cee5a03b \ No newline at end of file diff --git a/docs/classsk_1_1PenMode__coll__graph.png b/docs/classsk_1_1PenMode__coll__graph.png deleted file mode 100644 index 89207da..0000000 Binary files a/docs/classsk_1_1PenMode__coll__graph.png and /dev/null differ diff --git a/docs/classsk_1_1PenMode__inherit__graph.map b/docs/classsk_1_1PenMode__inherit__graph.map deleted file mode 100644 index 0934bf0..0000000 --- a/docs/classsk_1_1PenMode__inherit__graph.map +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/docs/classsk_1_1PenMode__inherit__graph.md5 b/docs/classsk_1_1PenMode__inherit__graph.md5 deleted file mode 100644 index 86a264f..0000000 --- a/docs/classsk_1_1PenMode__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -94add1233bfd8ce7a14e3101cee5a03b \ No newline at end of file diff --git a/docs/classsk_1_1PenMode__inherit__graph.png b/docs/classsk_1_1PenMode__inherit__graph.png deleted file mode 100644 index 89207da..0000000 Binary files a/docs/classsk_1_1PenMode__inherit__graph.png and /dev/null differ diff --git a/docs/classsk_1_1Server-members.html b/docs/classsk_1_1Server-members.html deleted file mode 100644 index e343dca..0000000 --- a/docs/classsk_1_1Server-members.html +++ /dev/null @@ -1,106 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::Server Member List
-
-
- -

This is the complete list of members for sk::Server, including all inherited members.

- - - - - - - - - - - - - - - - - - - - - - - -
AbstractNetwork(QObject *parent=nullptr) (defined in sk::AbstractNetwork)sk::AbstractNetworkexplicit
AbstractNetwork(AbstractNetwork const &)=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
AbstractNetwork(AbstractNetwork &&) noexcept=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
getSocket() -> QTcpSocket *override (defined in sk::Server)sk::Servervirtual
operator=(Server const &) -> Server &=delete (defined in sk::Server)sk::Server
operator=(Server &&) -> Server &=delete (defined in sk::Server)sk::Server
operator=(AbstractNetwork const &) -> AbstractNetwork &=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
operator=(AbstractNetwork &&) noexcept -> AbstractNetwork &=delete (defined in sk::AbstractNetwork)sk::AbstractNetwork
receivedMessage(QString const &msg) (defined in sk::AbstractNetwork)sk::AbstractNetworksignal
sendChangeColor(QColor const &color) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendChangeWidth(int const width) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendDrawAt(QPoint const &pos) -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendMouseReleased() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendRedo() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendToBrush() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendToPen() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
sendUndo() -> void (defined in sk::AbstractNetwork)sk::AbstractNetwork
Server() (defined in sk::Server)sk::Serverexplicit
Server(Server const &)=delete (defined in sk::Server)sk::Server
Server(Server &&)=delete (defined in sk::Server)sk::Server
~AbstractNetwork() noexcept override=default (defined in sk::AbstractNetwork)sk::AbstractNetwork
~Server() noexcept override (defined in sk::Server)sk::Server
- - - - diff --git a/docs/classsk_1_1Server.html b/docs/classsk_1_1Server.html index 22385a6..4717000 100644 --- a/docs/classsk_1_1Server.html +++ b/docs/classsk_1_1Server.html @@ -1,177 +1,140 @@ - - + + - - - - -Skribble: sk::Server Class Reference - - - - - - - + + sk::Server class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ sk::Server class final +

+

Implements AbstractNetwork for a server.

+
+

Contents

+ +
+
+

Base classes

+
+
+ class AbstractNetwork +
+
Contains all common events for a client/server.
+
+
+
+

Public functions

+
+
+ auto getSocket() -> QTcpSocket * -> auto override +
+
Helper to get current connection.
+
+
+
+

Function documentation

+
+

+ auto sk::Server::getSocket() -> QTcpSocket * override +

+

Helper to get current connection.

+

If the app was started as a server, this returns the client 'connection', If the app was started as a client, this 'returns' the server, otherwise it simply returns nullptr.

+
+
+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::Server Class Referencefinal
-
-
-
-Inheritance diagram for sk::Server:
-
-
Inheritance graph
- - - - - -
[legend]
-
-Collaboration diagram for sk::Server:
-
-
Collaboration graph
- - - - - -
[legend]
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

Server (Server const &)=delete
 
Server (Server &&)=delete
 
-auto operator= (Server const &) -> Server &=delete
 
-auto operator= (Server &&) -> Server &=delete
 
-auto getSocket () -> QTcpSocket *override
 
- Public Member Functions inherited from sk::AbstractNetwork
AbstractNetwork (QObject *parent=nullptr)
 
AbstractNetwork (AbstractNetwork const &)=delete
 
AbstractNetwork (AbstractNetwork &&) noexcept=delete
 
-auto operator= (AbstractNetwork const &) -> AbstractNetwork &=delete
 
-auto operator= (AbstractNetwork &&) noexcept -> AbstractNetwork &=delete
 
-auto sendDrawAt (QPoint const &pos) -> void
 
-auto sendMouseReleased () -> void
 
-auto sendUndo () -> void
 
-auto sendRedo () -> void
 
-auto sendChangeColor (QColor const &color) -> void
 
-auto sendChangeWidth (int const width) -> void
 
-auto sendToPen () -> void
 
-auto sendToBrush () -> void
 
- - - - -

-Additional Inherited Members

- Signals inherited from sk::AbstractNetwork
-void receivedMessage (QString const &msg)
 
-

Detailed Description

-
-

Definition at line 14 of file server.hpp.

-

The documentation for this class was generated from the following files: -
- - + + +
diff --git a/docs/classsk_1_1Server.xml b/docs/classsk_1_1Server.xml new file mode 100644 index 0000000..dda59ee --- /dev/null +++ b/docs/classsk_1_1Server.xml @@ -0,0 +1,212 @@ + + + + sk::Server + sk::AbstractNetwork + server.hpp + + + std::unique_ptr< QTcpServer > + std::unique_ptr<QTcpServer> sk::Server::m_server + + m_server + { nullptr } + + + + + + + + + + QTcpSocket * + QTcpSocket* sk::Server::m_socket + + m_socket + { nullptr } + + + + + + + + + + + + + sk::Server::Server + () + Server + + + + + + + + + + + sk::Server::Server + (Server const &)=delete + Server + + Server const & + + + + + + + + + + + + sk::Server::Server + (Server &&)=delete + Server + + Server && + + + + + + + + + + + + sk::Server::~Server + () noexcept override + ~Server + + + + + + + + + + auto + auto sk::Server::operator= + (Server const &) -> Server &=delete + operator= + + Server const & + + + + + + + + + + + auto + auto sk::Server::operator= + (Server &&) -> Server &=delete + operator= + + Server && + + + + + + + + + + + auto + auto sk::Server::getSocket + () -> QTcpSocket *override + getSocket + getSocket + +Helper to get current connection. + + +If the app was started as a server, this returns the client 'connection', If the app was started as a client, this 'returns' the server, otherwise it simply returns nullptr. + + + + + + + +Implements AbstractNetwork for a server. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::ServerAbstractNetwork + sk::ServerAbstractNetwork + sk::ServerAbstractNetwork + sk::ServergetSocket + sk::Serverm_server + sk::Serverm_socket + sk::Serveroperator= + sk::Serveroperator= + sk::Serveroperator= + sk::Serveroperator= + sk::ServerreceivedMessage + sk::ServersendChangeColor + sk::ServersendChangeWidth + sk::ServersendDrawAt + sk::ServersendMouseReleased + sk::ServersendRedo + sk::ServersendToBrush + sk::ServersendToPen + sk::ServersendUndo + sk::ServerServer + sk::ServerServer + sk::ServerServer + sk::Server~AbstractNetwork + sk::Server~Server + + + diff --git a/docs/classsk_1_1Server__coll__graph.map b/docs/classsk_1_1Server__coll__graph.map deleted file mode 100644 index b3ee6b5..0000000 --- a/docs/classsk_1_1Server__coll__graph.map +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/docs/classsk_1_1Server__coll__graph.md5 b/docs/classsk_1_1Server__coll__graph.md5 deleted file mode 100644 index 9668040..0000000 --- a/docs/classsk_1_1Server__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -5a47c190e737bf51dfbe8e210891e077 \ No newline at end of file diff --git a/docs/classsk_1_1Server__coll__graph.png b/docs/classsk_1_1Server__coll__graph.png deleted file mode 100644 index 72c4e16..0000000 Binary files a/docs/classsk_1_1Server__coll__graph.png and /dev/null differ diff --git a/docs/classsk_1_1Server__inherit__graph.map b/docs/classsk_1_1Server__inherit__graph.map deleted file mode 100644 index b3ee6b5..0000000 --- a/docs/classsk_1_1Server__inherit__graph.map +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/docs/classsk_1_1Server__inherit__graph.md5 b/docs/classsk_1_1Server__inherit__graph.md5 deleted file mode 100644 index 9668040..0000000 --- a/docs/classsk_1_1Server__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -5a47c190e737bf51dfbe8e210891e077 \ No newline at end of file diff --git a/docs/classsk_1_1Server__inherit__graph.png b/docs/classsk_1_1Server__inherit__graph.png deleted file mode 100644 index 72c4e16..0000000 Binary files a/docs/classsk_1_1Server__inherit__graph.png and /dev/null differ diff --git a/docs/classsk_1_1impl_1_1CachedLayers-members.html b/docs/classsk_1_1impl_1_1CachedLayers-members.html deleted file mode 100644 index 508fb68..0000000 --- a/docs/classsk_1_1impl_1_1CachedLayers-members.html +++ /dev/null @@ -1,99 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
sk::impl::CachedLayers Member List
-
-
- -

This is the complete list of members for sk::impl::CachedLayers, including all inherited members.

- - - - - - - - - - - - - - - - -
CachedLayers(bool const foreign=false) (defined in sk::impl::CachedLayers)sk::impl::CachedLayersexplicit
CachedLayers(CachedLayers const &)=default (defined in sk::impl::CachedLayers)sk::impl::CachedLayers
CachedLayers(CachedLayers &&)=default (defined in sk::impl::CachedLayers)sk::impl::CachedLayers
foreign() const noexcept -> bool (defined in sk::impl::CachedLayers)sk::impl::CachedLayersinline
getCanvasRect() -> QRect (defined in sk::impl::CachedLayers)sk::impl::CachedLayersinlinestatic
getLastLayer() noexcept -> QPixmap & (defined in sk::impl::CachedLayers)sk::impl::CachedLayers
getLastLayer() const noexcept -> QPixmap const & (defined in sk::impl::CachedLayers)sk::impl::CachedLayers
operator=(CachedLayers const &) -> CachedLayers &=delete (defined in sk::impl::CachedLayers)sk::impl::CachedLayers
operator=(CachedLayers &&) -> CachedLayers &=delete (defined in sk::impl::CachedLayers)sk::impl::CachedLayers
paintBlock(QPainter &painter) -> void (defined in sk::impl::CachedLayers)sk::impl::CachedLayers
pushNewLayer() -> void (defined in sk::impl::CachedLayers)sk::impl::CachedLayers
redo() -> bool (defined in sk::impl::CachedLayers)sk::impl::CachedLayers
underUndo() const noexcept -> bool (defined in sk::impl::CachedLayers)sk::impl::CachedLayersinline
undo() -> boolsk::impl::CachedLayers
~CachedLayers() noexcept=default (defined in sk::impl::CachedLayers)sk::impl::CachedLayers
- - - - diff --git a/docs/classsk_1_1impl_1_1CachedLayers.html b/docs/classsk_1_1impl_1_1CachedLayers.html index e1cd840..182dbd6 100644 --- a/docs/classsk_1_1impl_1_1CachedLayers.html +++ b/docs/classsk_1_1impl_1_1CachedLayers.html @@ -1,161 +1,101 @@ - - + + - - - - -Skribble: sk::impl::CachedLayers Class Reference - - - - - - - + + sk::impl::CachedLayers class | Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ sk::impl::CachedLayers class +

+

A helper class that wraps FCachedResource and represents modifications to a batch of layers.

+

It also stores a bool that remembers whether or not the layer batch is local or 'foreign'.

+
+
+
+
+ - - - - - - - - -
-
- - -
- -
- - -
-
- -
-
sk::impl::CachedLayers Class Reference
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

CachedLayers (bool const foreign=false)
 
CachedLayers (CachedLayers const &)=default
 
CachedLayers (CachedLayers &&)=default
 
-auto operator= (CachedLayers const &) -> CachedLayers &=delete
 
-auto operator= (CachedLayers &&) -> CachedLayers &=delete
 
-auto pushNewLayer () -> void
 
-auto paintBlock (QPainter &painter) -> void
 
-auto getLastLayer () noexcept -> QPixmap &
 
-auto getLastLayer () const noexcept -> QPixmap const &
 
-constexpr auto foreign () const noexcept -> bool
 
-auto underUndo () const noexcept -> bool
 
auto undo () -> bool
 
-auto redo () -> bool
 
- - - -

-Static Public Member Functions

-static constexpr auto getCanvasRect () -> QRect
 
-

Detailed Description

-
-

Definition at line 22 of file draw_history.hpp.

-

Member Function Documentation

- -

◆ undo()

- -
-
- - - - - - - -
auto sk::impl::CachedLayers::undo () -> bool
-
-
Returns
true If undo was successful. false If already at oldest change
- -

Definition at line 50 of file draw_history.cpp.

- -
-
-
The documentation for this class was generated from the following files: -
- - + + +
diff --git a/docs/classsk_1_1impl_1_1CachedLayers.xml b/docs/classsk_1_1impl_1_1CachedLayers.xml new file mode 100644 index 0000000..f3d8d10 --- /dev/null +++ b/docs/classsk_1_1impl_1_1CachedLayers.xml @@ -0,0 +1,359 @@ + + + + sk::impl::CachedLayers + draw_history.hpp + + + const bool + const bool sk::impl::CachedLayers::m_foreign + + m_foreign + { false } + + + + + + + + + + sk::FCachedResource< QPixmap > + sk::FCachedResource<QPixmap> sk::impl::CachedLayers::m_layers + + m_layers + { &PixmapDrawer, &PixmapInit } + + + + + + + + + + + + constexpr QColor + constexpr QColor sk::impl::CachedLayers::m_transparent + + m_transparent + { 0, 0, 0, 0 } + + + + + + + + + + constexpr QRect + constexpr QRect sk::impl::CachedLayers::m_canvasRect + + m_canvasRect + { + 0, 0, sk::config::width, sk::config::height + } + + + + + + + + + + + + auto + auto sk::impl::CachedLayers::PixmapDrawer + (QPixmap &dest, QPixmap &src) -> void + PixmapDrawer + + QPixmap & + dest + + + QPixmap & + src + + + + + + + + + + + auto + auto sk::impl::CachedLayers::PixmapInit + (QPixmap &pixmap) noexcept -> void + PixmapInit + + QPixmap & + pixmap + + + + + + + + + + + + + + sk::impl::CachedLayers::CachedLayers + (bool const foreign=false) + CachedLayers + + bool const + foreign + false + + + + + + + + + + + + sk::impl::CachedLayers::CachedLayers + (CachedLayers const &)=default + CachedLayers + + CachedLayers const & + + + + + + + + + + + + sk::impl::CachedLayers::CachedLayers + (CachedLayers &&)=default + CachedLayers + + CachedLayers && + + + + + + + + + + + + sk::impl::CachedLayers::~CachedLayers + () noexcept=default + ~CachedLayers + + + + + + + + + + auto + auto sk::impl::CachedLayers::operator= + (CachedLayers const &) -> CachedLayers &=delete + operator= + + CachedLayers const & + + + + + + + + + + + auto + auto sk::impl::CachedLayers::operator= + (CachedLayers &&) -> CachedLayers &=delete + operator= + + CachedLayers && + + + + + + + + + + + auto + auto sk::impl::CachedLayers::pushNewLayer + () -> void + pushNewLayer + + + + + + + + + + auto + auto sk::impl::CachedLayers::paintBlock + (QPainter &painter) -> void + paintBlock + + QPainter & + painter + + + + + + + + + + + auto + auto sk::impl::CachedLayers::getLastLayer + () noexcept -> QPixmap & + getLastLayer + + + + + + + + + + auto + auto sk::impl::CachedLayers::getLastLayer + () const noexcept -> QPixmap const & + getLastLayer + + + + + + + + + + constexpr auto + constexpr auto sk::impl::CachedLayers::foreign + () const noexcept -> bool + foreign + + + + + + + + + + auto + auto sk::impl::CachedLayers::underUndo + () const noexcept -> bool + underUndo + + + + + + + + + + auto + auto sk::impl::CachedLayers::undo + () -> bool + undo + + + + + + + + + + auto + auto sk::impl::CachedLayers::redo + () -> bool + redo + + + + + + + + + + + + constexpr auto + static constexpr auto sk::impl::CachedLayers::getCanvasRect + () -> QRect + getCanvasRect + + + + + + + + + + +A helper class that wraps FCachedResource and represents modifications to a batch of layers. + + +It also stores a bool that remembers whether or not the layer batch is local or 'foreign'. + + + + sk::impl::CachedLayersCachedLayers + sk::impl::CachedLayersCachedLayers + sk::impl::CachedLayersCachedLayers + sk::impl::CachedLayersforeign + sk::impl::CachedLayersgetCanvasRect + sk::impl::CachedLayersgetLastLayer + sk::impl::CachedLayersgetLastLayer + sk::impl::CachedLayersm_canvasRect + sk::impl::CachedLayersm_foreign + sk::impl::CachedLayersm_layers + sk::impl::CachedLayersm_transparent + sk::impl::CachedLayersoperator= + sk::impl::CachedLayersoperator= + sk::impl::CachedLayerspaintBlock + sk::impl::CachedLayersPixmapDrawer + sk::impl::CachedLayersPixmapInit + sk::impl::CachedLayerspushNewLayer + sk::impl::CachedLayersredo + sk::impl::CachedLayersunderUndo + sk::impl::CachedLayersundo + sk::impl::CachedLayers~CachedLayers + + + diff --git a/docs/client_8cpp.xml b/docs/client_8cpp.xml new file mode 100644 index 0000000..4e2197b --- /dev/null +++ b/docs/client_8cpp.xml @@ -0,0 +1,92 @@ + + + + client.cpp + client.hpp + network_config.hpp + QDebug + QGuiApplication + iostream + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + + + + + + + diff --git a/docs/client_8cpp_source.html b/docs/client_8cpp_source.html deleted file mode 100644 index 7dadced..0000000 --- a/docs/client_8cpp_source.html +++ /dev/null @@ -1,125 +0,0 @@ - - - - - - - -Skribble: src/client.cpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
client.cpp
-
-
-
1 #include "client.hpp"
-
2 #include "network_config.hpp"
-
3 
-
4 #include <QDebug>
-
5 #include <QGuiApplication>
-
6 
-
7 #include <iostream>
-
8 
-
9 namespace sk {
-
10 
-
11 Client::Client(QString const& ip)
-
12 {
-
13  qDebug() << "Port to connect to: " << ip;
-
14  m_server = std::make_unique<QTcpSocket>(this);
-
15  m_server->connectToHost(ip, sk::port);
-
16 
-
17  if(!m_server->waitForConnected()) {
-
18  qDebug() << "Could't establish connection to the server!";
-
19  }
-
20 
-
21  connect(m_server.get(), &QTcpSocket::readyRead, [this] {
-
22  QString str{ m_server->readAll() };
-
23  qDebug() << "Client received: " << str;
-
24  emit receivedMessage(str);
-
25  });
-
26  connect(m_server.get(), &QTcpSocket::disconnected, [] {
-
27  qDebug() << "Quitting from client!";
-
28  QGuiApplication::quit();
-
29  });
-
30 
-
31  m_server->write("Hello");
-
32 }
-
33 
-
34 Client::~Client() noexcept
-
35 {
-
36  m_server->disconnectFromHost();
-
37 }
-
38 
-
39 auto Client::getSocket() -> QTcpSocket*
-
40 {
-
41  return m_server.get();
-
42 }
-
43 
-
44 } // namespace sk
-
- - - - diff --git a/docs/client_8hpp.xml b/docs/client_8hpp.xml new file mode 100644 index 0000000..0d12c5f --- /dev/null +++ b/docs/client_8hpp.xml @@ -0,0 +1,98 @@ + + + + client.hpp + abstract_network.hpp + QString + QTcpSocket + memory + src/canvas.cpp + src/network_factory.hpp + src/client.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::Client + sk + + + + + + + diff --git a/docs/client_8hpp_source.html b/docs/client_8hpp_source.html deleted file mode 100644 index 7c9d045..0000000 --- a/docs/client_8hpp_source.html +++ /dev/null @@ -1,116 +0,0 @@ - - - - - - - -Skribble: src/client.hpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
client.hpp
-
-
-
1 #ifndef CLIENT_HPP
-
2 #define CLIENT_HPP
-
3 #pragma once
-
4 
-
5 #include "abstract_network.hpp"
-
6 
-
7 #include <QString>
-
8 #include <QTcpSocket>
-
9 
-
10 #include <memory>
-
11 
-
12 namespace sk {
-
13 
-
14 class Client final : public AbstractNetwork
-
15 {
-
16 private:
-
17  std::unique_ptr<QTcpSocket> m_server{ nullptr };
-
18 
-
19 public:
-
20  explicit Client(QString const& ip);
-
21  Client(Client const&) = delete;
-
22  Client(Client&&) = delete;
-
23  ~Client() noexcept override;
-
24 
-
25  auto operator=(Client const&) = delete;
-
26  auto operator=(Client&&) = delete;
-
27 
-
28  auto getSocket() -> QTcpSocket* override;
-
29 };
-
30 
-
31 } // namespace sk
-
32 
-
33 #endif // !CLIENT_HPP
-
- - - - - - diff --git a/docs/closed.png b/docs/closed.png deleted file mode 100644 index 98cc2c9..0000000 Binary files a/docs/closed.png and /dev/null differ diff --git a/docs/combine.xslt b/docs/combine.xslt new file mode 100644 index 0000000..f0ee1fd --- /dev/null +++ b/docs/combine.xslt @@ -0,0 +1,15 @@ + + + + + + + + + + + + diff --git a/docs/compound.xsd b/docs/compound.xsd new file mode 100644 index 0000000..083df15 --- /dev/null +++ b/docs/compound.xsd @@ -0,0 +1,1187 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/docs/dir_59425e443f801f1f2fd8bbe4959a3ccf.html b/docs/dir_59425e443f801f1f2fd8bbe4959a3ccf.html deleted file mode 100644 index fcd0cc8..0000000 --- a/docs/dir_59425e443f801f1f2fd8bbe4959a3ccf.html +++ /dev/null @@ -1,85 +0,0 @@ - - - - - - - -Skribble: tests Directory Reference - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
tests Directory Reference
-
-
- - -

-Directories

-
- - - - diff --git a/docs/dir_59425e443f801f1f2fd8bbe4959a3ccf.xml b/docs/dir_59425e443f801f1f2fd8bbe4959a3ccf.xml new file mode 100644 index 0000000..1bef5d1 --- /dev/null +++ b/docs/dir_59425e443f801f1f2fd8bbe4959a3ccf.xml @@ -0,0 +1,16 @@ + + + + tests + tests/helper + cached_resource_test.cpp + fcached_resource_test.cpp + format_test.cpp + message_parser_test.cpp + + + + + + + diff --git a/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.html b/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.html deleted file mode 100644 index d2a629f..0000000 --- a/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.html +++ /dev/null @@ -1,81 +0,0 @@ - - - - - - - -Skribble: src Directory Reference - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
src Directory Reference
-
-
-
- - - - diff --git a/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.xml b/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.xml new file mode 100644 index 0000000..89923ff --- /dev/null +++ b/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.xml @@ -0,0 +1,35 @@ + + + + src + abstract_network.cpp + abstract_network.hpp + cached_resource.hpp + canvas.cpp + canvas.hpp + canvas_config.hpp + client.cpp + client.hpp + draw_history.cpp + draw_history.hpp + draw_mode.cpp + draw_mode.hpp + dummy_network.cpp + dummy_network.hpp + fixed_cached_resource.hpp + format.hpp + main.cpp + message_parser.cpp + message_parser.hpp + network_config.hpp + network_factory.cpp + network_factory.hpp + server.cpp + server.hpp + + + + + + + diff --git a/docs/dir_6f4ad88cf3a75e9ee319fbb585935c9c.html b/docs/dir_6f4ad88cf3a75e9ee319fbb585935c9c.html deleted file mode 100644 index df8a5d7..0000000 --- a/docs/dir_6f4ad88cf3a75e9ee319fbb585935c9c.html +++ /dev/null @@ -1,81 +0,0 @@ - - - - - - - -Skribble: tests/helper Directory Reference - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
helper Directory Reference
-
-
-
- - - - diff --git a/docs/dir_6f4ad88cf3a75e9ee319fbb585935c9c.xml b/docs/dir_6f4ad88cf3a75e9ee319fbb585935c9c.xml new file mode 100644 index 0000000..0a4787a --- /dev/null +++ b/docs/dir_6f4ad88cf3a75e9ee319fbb585935c9c.xml @@ -0,0 +1,12 @@ + + + + tests/helper + test.hpp + + + + + + + diff --git a/docs/doc.png b/docs/doc.png deleted file mode 100644 index 17edabf..0000000 Binary files a/docs/doc.png and /dev/null differ diff --git a/docs/doxygen.css b/docs/doxygen.css deleted file mode 100644 index 73ecbb2..0000000 --- a/docs/doxygen.css +++ /dev/null @@ -1,1771 +0,0 @@ -/* The standard CSS for doxygen 1.8.17 */ - -body, table, div, p, dl { - font: 400 14px/22px Roboto,sans-serif; -} - -p.reference, p.definition { - font: 400 14px/22px Roboto,sans-serif; -} - -/* @group Heading Levels */ - -h1.groupheader { - font-size: 150%; -} - -.title { - font: 400 14px/28px Roboto,sans-serif; - font-size: 150%; - font-weight: bold; - margin: 10px 2px; -} - -h2.groupheader { - border-bottom: 1px solid #879ECB; - color: #354C7B; - font-size: 150%; - font-weight: normal; - margin-top: 1.75em; - padding-top: 8px; - padding-bottom: 4px; - width: 100%; -} - -h3.groupheader { - font-size: 100%; -} - -h1, h2, h3, h4, h5, h6 { - -webkit-transition: text-shadow 0.5s linear; - -moz-transition: text-shadow 0.5s linear; - -ms-transition: text-shadow 0.5s linear; - -o-transition: text-shadow 0.5s linear; - transition: text-shadow 0.5s linear; - margin-right: 15px; -} - -h1.glow, h2.glow, h3.glow, h4.glow, h5.glow, h6.glow { - text-shadow: 0 0 15px cyan; -} - -dt { - font-weight: bold; -} - -ul.multicol { - -moz-column-gap: 1em; - -webkit-column-gap: 1em; - column-gap: 1em; - -moz-column-count: 3; - -webkit-column-count: 3; - column-count: 3; -} - -p.startli, p.startdd { - margin-top: 2px; -} - -th p.starttd, p.intertd, p.endtd { - font-size: 100%; - font-weight: 700; -} - -p.starttd { - margin-top: 0px; -} - -p.endli { - margin-bottom: 0px; -} - -p.enddd { - margin-bottom: 4px; -} - -p.endtd { - margin-bottom: 2px; -} - -p.interli { -} - -p.interdd { -} - -p.intertd { -} - -/* @end */ - -caption { - font-weight: bold; -} - -span.legend { - font-size: 70%; - text-align: center; -} - -h3.version { - font-size: 90%; - text-align: center; -} - -div.qindex, div.navtab{ - background-color: #EBEFF6; - border: 1px solid #A3B4D7; - text-align: center; -} - -div.qindex, div.navpath { - width: 100%; - line-height: 140%; -} - -div.navtab { - margin-right: 15px; -} - -/* @group Link Styling */ - -a { - color: #3D578C; - font-weight: normal; - text-decoration: none; -} - -.contents a:visited { - color: #4665A2; -} - -a:hover { - text-decoration: underline; -} - -a.qindex { - font-weight: bold; -} - -a.qindexHL { - font-weight: bold; - background-color: #9CAFD4; - color: #FFFFFF; - border: 1px double #869DCA; -} - -.contents a.qindexHL:visited { - color: #FFFFFF; -} - -a.el { - font-weight: bold; -} - -a.elRef { -} - -a.code, a.code:visited, a.line, a.line:visited { - color: #4665A2; -} - -a.codeRef, a.codeRef:visited, a.lineRef, a.lineRef:visited { - color: #4665A2; -} - -/* @end */ - -dl.el { - margin-left: -1cm; -} - -ul { - overflow: hidden; /*Fixed: list item bullets overlap floating elements*/ -} - -#side-nav ul { - overflow: visible; /* reset ul rule for scroll bar in GENERATE_TREEVIEW window */ -} - -#main-nav ul { - overflow: visible; /* reset ul rule for the navigation bar drop down lists */ -} - -.fragment { - text-align: left; - direction: ltr; - overflow-x: auto; /*Fixed: fragment lines overlap floating elements*/ - overflow-y: hidden; -} - -pre.fragment { - border: 1px solid #C4CFE5; - background-color: #FBFCFD; - padding: 4px 6px; - margin: 4px 8px 4px 2px; - overflow: auto; - word-wrap: break-word; - font-size: 9pt; - line-height: 125%; - font-family: monospace, fixed; - font-size: 105%; -} - -div.fragment { - padding: 0 0 1px 0; /*Fixed: last line underline overlap border*/ - margin: 4px 8px 4px 2px; - background-color: #FBFCFD; - border: 1px solid #C4CFE5; -} - -div.line { - font-family: monospace, fixed; - font-size: 13px; - min-height: 13px; - line-height: 1.0; - text-wrap: unrestricted; - white-space: -moz-pre-wrap; /* Moz */ - white-space: -pre-wrap; /* Opera 4-6 */ - white-space: -o-pre-wrap; /* Opera 7 */ - white-space: pre-wrap; /* CSS3 */ - word-wrap: break-word; /* IE 5.5+ */ - text-indent: -53px; - padding-left: 53px; - padding-bottom: 0px; - margin: 0px; - -webkit-transition-property: background-color, box-shadow; - -webkit-transition-duration: 0.5s; - -moz-transition-property: background-color, box-shadow; - -moz-transition-duration: 0.5s; - -ms-transition-property: background-color, box-shadow; - -ms-transition-duration: 0.5s; - -o-transition-property: background-color, box-shadow; - -o-transition-duration: 0.5s; - transition-property: background-color, box-shadow; - transition-duration: 0.5s; -} - -div.line:after { - content:"\000A"; - white-space: pre; -} - -div.line.glow { - background-color: cyan; - box-shadow: 0 0 10px cyan; -} - - -span.lineno { - padding-right: 4px; - text-align: right; - border-right: 2px solid #0F0; - background-color: #E8E8E8; - white-space: pre; -} -span.lineno a { - background-color: #D8D8D8; -} - -span.lineno a:hover { - background-color: #C8C8C8; -} - -.lineno { - -webkit-touch-callout: none; - -webkit-user-select: none; - -khtml-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; -} - -div.ah, span.ah { - background-color: black; - font-weight: bold; - color: #FFFFFF; - margin-bottom: 3px; - margin-top: 3px; - padding: 0.2em; - border: solid thin #333; - border-radius: 0.5em; - -webkit-border-radius: .5em; - -moz-border-radius: .5em; - box-shadow: 2px 2px 3px #999; - -webkit-box-shadow: 2px 2px 3px #999; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; - background-image: -webkit-gradient(linear, left top, left bottom, from(#eee), to(#000),color-stop(0.3, #444)); - background-image: -moz-linear-gradient(center top, #eee 0%, #444 40%, #000 110%); -} - -div.classindex ul { - list-style: none; - padding-left: 0; -} - -div.classindex span.ai { - display: inline-block; -} - -div.groupHeader { - margin-left: 16px; - margin-top: 12px; - font-weight: bold; -} - -div.groupText { - margin-left: 16px; - font-style: italic; -} - -body { - background-color: white; - color: black; - margin: 0; -} - -div.contents { - margin-top: 10px; - margin-left: 12px; - margin-right: 8px; -} - -td.indexkey { - background-color: #EBEFF6; - font-weight: bold; - border: 1px solid #C4CFE5; - margin: 2px 0px 2px 0; - padding: 2px 10px; - white-space: nowrap; - vertical-align: top; -} - -td.indexvalue { - background-color: #EBEFF6; - border: 1px solid #C4CFE5; - padding: 2px 10px; - margin: 2px 0px; -} - -tr.memlist { - background-color: #EEF1F7; -} - -p.formulaDsp { - text-align: center; -} - -img.formulaDsp { - -} - -img.formulaInl, img.inline { - vertical-align: middle; -} - -div.center { - text-align: center; - margin-top: 0px; - margin-bottom: 0px; - padding: 0px; -} - -div.center img { - border: 0px; -} - -address.footer { - text-align: right; - padding-right: 12px; -} - -img.footer { - border: 0px; - vertical-align: middle; -} - -/* @group Code Colorization */ - -span.keyword { - color: #008000 -} - -span.keywordtype { - color: #604020 -} - -span.keywordflow { - color: #e08000 -} - -span.comment { - color: #800000 -} - -span.preprocessor { - color: #806020 -} - -span.stringliteral { - color: #002080 -} - -span.charliteral { - color: #008080 -} - -span.vhdldigit { - color: #ff00ff -} - -span.vhdlchar { - color: #000000 -} - -span.vhdlkeyword { - color: #700070 -} - -span.vhdllogic { - color: #ff0000 -} - -blockquote { - background-color: #F7F8FB; - border-left: 2px solid #9CAFD4; - margin: 0 24px 0 4px; - padding: 0 12px 0 16px; -} - -blockquote.DocNodeRTL { - border-left: 0; - border-right: 2px solid #9CAFD4; - margin: 0 4px 0 24px; - padding: 0 16px 0 12px; -} - -/* @end */ - -/* -.search { - color: #003399; - font-weight: bold; -} - -form.search { - margin-bottom: 0px; - margin-top: 0px; -} - -input.search { - font-size: 75%; - color: #000080; - font-weight: normal; - background-color: #e8eef2; -} -*/ - -td.tiny { - font-size: 75%; -} - -.dirtab { - padding: 4px; - border-collapse: collapse; - border: 1px solid #A3B4D7; -} - -th.dirtab { - background: #EBEFF6; - font-weight: bold; -} - -hr { - height: 0px; - border: none; - border-top: 1px solid #4A6AAA; -} - -hr.footer { - height: 1px; -} - -/* @group Member Descriptions */ - -table.memberdecls { - border-spacing: 0px; - padding: 0px; -} - -.memberdecls td, .fieldtable tr { - -webkit-transition-property: background-color, box-shadow; - -webkit-transition-duration: 0.5s; - -moz-transition-property: background-color, box-shadow; - -moz-transition-duration: 0.5s; - -ms-transition-property: background-color, box-shadow; - -ms-transition-duration: 0.5s; - -o-transition-property: background-color, box-shadow; - -o-transition-duration: 0.5s; - transition-property: background-color, box-shadow; - transition-duration: 0.5s; -} - -.memberdecls td.glow, .fieldtable tr.glow { - background-color: cyan; - box-shadow: 0 0 15px cyan; -} - -.mdescLeft, .mdescRight, -.memItemLeft, .memItemRight, -.memTemplItemLeft, .memTemplItemRight, .memTemplParams { - background-color: #F9FAFC; - border: none; - margin: 4px; - padding: 1px 0 0 8px; -} - -.mdescLeft, .mdescRight { - padding: 0px 8px 4px 8px; - color: #555; -} - -.memSeparator { - border-bottom: 1px solid #DEE4F0; - line-height: 1px; - margin: 0px; - padding: 0px; -} - -.memItemLeft, .memTemplItemLeft { - white-space: nowrap; -} - -.memItemRight, .memTemplItemRight { - width: 100%; -} - -.memTemplParams { - color: #4665A2; - white-space: nowrap; - font-size: 80%; -} - -/* @end */ - -/* @group Member Details */ - -/* Styles for detailed member documentation */ - -.memtitle { - padding: 8px; - border-top: 1px solid #A8B8D9; - border-left: 1px solid #A8B8D9; - border-right: 1px solid #A8B8D9; - border-top-right-radius: 4px; - border-top-left-radius: 4px; - margin-bottom: -1px; - background-image: url('nav_f.png'); - background-repeat: repeat-x; - background-color: #E2E8F2; - line-height: 1.25; - font-weight: 300; - float:left; -} - -.permalink -{ - font-size: 65%; - display: inline-block; - vertical-align: middle; -} - -.memtemplate { - font-size: 80%; - color: #4665A2; - font-weight: normal; - margin-left: 9px; -} - -.memnav { - background-color: #EBEFF6; - border: 1px solid #A3B4D7; - text-align: center; - margin: 2px; - margin-right: 15px; - padding: 2px; -} - -.mempage { - width: 100%; -} - -.memitem { - padding: 0; - margin-bottom: 10px; - margin-right: 5px; - -webkit-transition: box-shadow 0.5s linear; - -moz-transition: box-shadow 0.5s linear; - -ms-transition: box-shadow 0.5s linear; - -o-transition: box-shadow 0.5s linear; - transition: box-shadow 0.5s linear; - display: table !important; - width: 100%; -} - -.memitem.glow { - box-shadow: 0 0 15px cyan; -} - -.memname { - font-weight: 400; - margin-left: 6px; -} - -.memname td { - vertical-align: bottom; -} - -.memproto, dl.reflist dt { - border-top: 1px solid #A8B8D9; - border-left: 1px solid #A8B8D9; - border-right: 1px solid #A8B8D9; - padding: 6px 0px 6px 0px; - color: #253555; - font-weight: bold; - text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); - background-color: #DFE5F1; - /* opera specific markup */ - box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - border-top-right-radius: 4px; - /* firefox specific markup */ - -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; - -moz-border-radius-topright: 4px; - /* webkit specific markup */ - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - -webkit-border-top-right-radius: 4px; - -} - -.overload { - font-family: "courier new",courier,monospace; - font-size: 65%; -} - -.memdoc, dl.reflist dd { - border-bottom: 1px solid #A8B8D9; - border-left: 1px solid #A8B8D9; - border-right: 1px solid #A8B8D9; - padding: 6px 10px 2px 10px; - background-color: #FBFCFD; - border-top-width: 0; - background-image:url('nav_g.png'); - background-repeat:repeat-x; - background-color: #FFFFFF; - /* opera specific markup */ - border-bottom-left-radius: 4px; - border-bottom-right-radius: 4px; - box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - /* firefox specific markup */ - -moz-border-radius-bottomleft: 4px; - -moz-border-radius-bottomright: 4px; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; - /* webkit specific markup */ - -webkit-border-bottom-left-radius: 4px; - -webkit-border-bottom-right-radius: 4px; - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); -} - -dl.reflist dt { - padding: 5px; -} - -dl.reflist dd { - margin: 0px 0px 10px 0px; - padding: 5px; -} - -.paramkey { - text-align: right; -} - -.paramtype { - white-space: nowrap; -} - -.paramname { - color: #602020; - white-space: nowrap; -} -.paramname em { - font-style: normal; -} -.paramname code { - line-height: 14px; -} - -.params, .retval, .exception, .tparams { - margin-left: 0px; - padding-left: 0px; -} - -.params .paramname, .retval .paramname, .tparams .paramname, .exception .paramname { - font-weight: bold; - vertical-align: top; -} - -.params .paramtype, .tparams .paramtype { - font-style: italic; - vertical-align: top; -} - -.params .paramdir, .tparams .paramdir { - font-family: "courier new",courier,monospace; - vertical-align: top; -} - -table.mlabels { - border-spacing: 0px; -} - -td.mlabels-left { - width: 100%; - padding: 0px; -} - -td.mlabels-right { - vertical-align: bottom; - padding: 0px; - white-space: nowrap; -} - -span.mlabels { - margin-left: 8px; -} - -span.mlabel { - background-color: #728DC1; - border-top:1px solid #5373B4; - border-left:1px solid #5373B4; - border-right:1px solid #C4CFE5; - border-bottom:1px solid #C4CFE5; - text-shadow: none; - color: white; - margin-right: 4px; - padding: 2px 3px; - border-radius: 3px; - font-size: 7pt; - white-space: nowrap; - vertical-align: middle; -} - - - -/* @end */ - -/* these are for tree view inside a (index) page */ - -div.directory { - margin: 10px 0px; - border-top: 1px solid #9CAFD4; - border-bottom: 1px solid #9CAFD4; - width: 100%; -} - -.directory table { - border-collapse:collapse; -} - -.directory td { - margin: 0px; - padding: 0px; - vertical-align: top; -} - -.directory td.entry { - white-space: nowrap; - padding-right: 6px; - padding-top: 3px; -} - -.directory td.entry a { - outline:none; -} - -.directory td.entry a img { - border: none; -} - -.directory td.desc { - width: 100%; - padding-left: 6px; - padding-right: 6px; - padding-top: 3px; - border-left: 1px solid rgba(0,0,0,0.05); -} - -.directory tr.even { - padding-left: 6px; - background-color: #F7F8FB; -} - -.directory img { - vertical-align: -30%; -} - -.directory .levels { - white-space: nowrap; - width: 100%; - text-align: right; - font-size: 9pt; -} - -.directory .levels span { - cursor: pointer; - padding-left: 2px; - padding-right: 2px; - color: #3D578C; -} - -.arrow { - color: #9CAFD4; - -webkit-user-select: none; - -khtml-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; - cursor: pointer; - font-size: 80%; - display: inline-block; - width: 16px; - height: 22px; -} - -.icon { - font-family: Arial, Helvetica; - font-weight: bold; - font-size: 12px; - height: 14px; - width: 16px; - display: inline-block; - background-color: #728DC1; - color: white; - text-align: center; - border-radius: 4px; - margin-left: 2px; - margin-right: 2px; -} - -.icona { - width: 24px; - height: 22px; - display: inline-block; -} - -.iconfopen { - width: 24px; - height: 18px; - margin-bottom: 4px; - background-image:url('folderopen.png'); - background-position: 0px -4px; - background-repeat: repeat-y; - vertical-align:top; - display: inline-block; -} - -.iconfclosed { - width: 24px; - height: 18px; - margin-bottom: 4px; - background-image:url('folderclosed.png'); - background-position: 0px -4px; - background-repeat: repeat-y; - vertical-align:top; - display: inline-block; -} - -.icondoc { - width: 24px; - height: 18px; - margin-bottom: 4px; - background-image:url('doc.png'); - background-position: 0px -4px; - background-repeat: repeat-y; - vertical-align:top; - display: inline-block; -} - -table.directory { - font: 400 14px Roboto,sans-serif; -} - -/* @end */ - -div.dynheader { - margin-top: 8px; - -webkit-touch-callout: none; - -webkit-user-select: none; - -khtml-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; -} - -address { - font-style: normal; - color: #2A3D61; -} - -table.doxtable caption { - caption-side: top; -} - -table.doxtable { - border-collapse:collapse; - margin-top: 4px; - margin-bottom: 4px; -} - -table.doxtable td, table.doxtable th { - border: 1px solid #2D4068; - padding: 3px 7px 2px; -} - -table.doxtable th { - background-color: #374F7F; - color: #FFFFFF; - font-size: 110%; - padding-bottom: 4px; - padding-top: 5px; -} - -table.fieldtable { - /*width: 100%;*/ - margin-bottom: 10px; - border: 1px solid #A8B8D9; - border-spacing: 0px; - -moz-border-radius: 4px; - -webkit-border-radius: 4px; - border-radius: 4px; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; - -webkit-box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); - box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); -} - -.fieldtable td, .fieldtable th { - padding: 3px 7px 2px; -} - -.fieldtable td.fieldtype, .fieldtable td.fieldname { - white-space: nowrap; - border-right: 1px solid #A8B8D9; - border-bottom: 1px solid #A8B8D9; - vertical-align: top; -} - -.fieldtable td.fieldname { - padding-top: 3px; -} - -.fieldtable td.fielddoc { - border-bottom: 1px solid #A8B8D9; - /*width: 100%;*/ -} - -.fieldtable td.fielddoc p:first-child { - margin-top: 0px; -} - -.fieldtable td.fielddoc p:last-child { - margin-bottom: 2px; -} - -.fieldtable tr:last-child td { - border-bottom: none; -} - -.fieldtable th { - background-image:url('nav_f.png'); - background-repeat:repeat-x; - background-color: #E2E8F2; - font-size: 90%; - color: #253555; - padding-bottom: 4px; - padding-top: 5px; - text-align:left; - font-weight: 400; - -moz-border-radius-topleft: 4px; - -moz-border-radius-topright: 4px; - -webkit-border-top-left-radius: 4px; - -webkit-border-top-right-radius: 4px; - border-top-left-radius: 4px; - border-top-right-radius: 4px; - border-bottom: 1px solid #A8B8D9; -} - - -.tabsearch { - top: 0px; - left: 10px; - height: 36px; - background-image: url('tab_b.png'); - z-index: 101; - overflow: hidden; - font-size: 13px; -} - -.navpath ul -{ - font-size: 11px; - background-image:url('tab_b.png'); - background-repeat:repeat-x; - background-position: 0 -5px; - height:30px; - line-height:30px; - color:#8AA0CC; - border:solid 1px #C2CDE4; - overflow:hidden; - margin:0px; - padding:0px; -} - -.navpath li -{ - list-style-type:none; - float:left; - padding-left:10px; - padding-right:15px; - background-image:url('bc_s.png'); - background-repeat:no-repeat; - background-position:right; - color:#364D7C; -} - -.navpath li.navelem a -{ - height:32px; - display:block; - text-decoration: none; - outline: none; - color: #283A5D; - font-family: 'Lucida Grande',Geneva,Helvetica,Arial,sans-serif; - text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); - text-decoration: none; -} - -.navpath li.navelem a:hover -{ - color:#6884BD; -} - -.navpath li.footer -{ - list-style-type:none; - float:right; - padding-left:10px; - padding-right:15px; - background-image:none; - background-repeat:no-repeat; - background-position:right; - color:#364D7C; - font-size: 8pt; -} - - -div.summary -{ - float: right; - font-size: 8pt; - padding-right: 5px; - width: 50%; - text-align: right; -} - -div.summary a -{ - white-space: nowrap; -} - -table.classindex -{ - margin: 10px; - white-space: nowrap; - margin-left: 3%; - margin-right: 3%; - width: 94%; - border: 0; - border-spacing: 0; - padding: 0; -} - -div.ingroups -{ - font-size: 8pt; - width: 50%; - text-align: left; -} - -div.ingroups a -{ - white-space: nowrap; -} - -div.header -{ - background-image:url('nav_h.png'); - background-repeat:repeat-x; - background-color: #F9FAFC; - margin: 0px; - border-bottom: 1px solid #C4CFE5; -} - -div.headertitle -{ - padding: 5px 5px 5px 10px; -} - -.PageDocRTL-title div.headertitle { - text-align: right; - direction: rtl; -} - -dl { - padding: 0 0 0 0; -} - -/* dl.note, dl.warning, dl.attention, dl.pre, dl.post, dl.invariant, dl.deprecated, dl.todo, dl.test, dl.bug, dl.examples */ -dl.section { - margin-left: 0px; - padding-left: 0px; -} - -dl.section.DocNodeRTL { - margin-right: 0px; - padding-right: 0px; -} - -dl.note { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #D0C000; -} - -dl.note.DocNodeRTL { - margin-left: 0; - padding-left: 0; - border-left: 0; - margin-right: -7px; - padding-right: 3px; - border-right: 4px solid; - border-color: #D0C000; -} - -dl.warning, dl.attention { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #FF0000; -} - -dl.warning.DocNodeRTL, dl.attention.DocNodeRTL { - margin-left: 0; - padding-left: 0; - border-left: 0; - margin-right: -7px; - padding-right: 3px; - border-right: 4px solid; - border-color: #FF0000; -} - -dl.pre, dl.post, dl.invariant { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #00D000; -} - -dl.pre.DocNodeRTL, dl.post.DocNodeRTL, dl.invariant.DocNodeRTL { - margin-left: 0; - padding-left: 0; - border-left: 0; - margin-right: -7px; - padding-right: 3px; - border-right: 4px solid; - border-color: #00D000; -} - -dl.deprecated { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #505050; -} - -dl.deprecated.DocNodeRTL { - margin-left: 0; - padding-left: 0; - border-left: 0; - margin-right: -7px; - padding-right: 3px; - border-right: 4px solid; - border-color: #505050; -} - -dl.todo { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #00C0E0; -} - -dl.todo.DocNodeRTL { - margin-left: 0; - padding-left: 0; - border-left: 0; - margin-right: -7px; - padding-right: 3px; - border-right: 4px solid; - border-color: #00C0E0; -} - -dl.test { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #3030E0; -} - -dl.test.DocNodeRTL { - margin-left: 0; - padding-left: 0; - border-left: 0; - margin-right: -7px; - padding-right: 3px; - border-right: 4px solid; - border-color: #3030E0; -} - -dl.bug { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #C08050; -} - -dl.bug.DocNodeRTL { - margin-left: 0; - padding-left: 0; - border-left: 0; - margin-right: -7px; - padding-right: 3px; - border-right: 4px solid; - border-color: #C08050; -} - -dl.section dd { - margin-bottom: 6px; -} - - -#projectlogo -{ - text-align: center; - vertical-align: bottom; - border-collapse: separate; -} - -#projectlogo img -{ - border: 0px none; -} - -#projectalign -{ - vertical-align: middle; -} - -#projectname -{ - font: 300% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 2px 0px; -} - -#projectbrief -{ - font: 120% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 0px; -} - -#projectnumber -{ - font: 50% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 0px; -} - -#titlearea -{ - padding: 0px; - margin: 0px; - width: 100%; - border-bottom: 1px solid #5373B4; -} - -.image -{ - text-align: center; -} - -.dotgraph -{ - text-align: center; -} - -.mscgraph -{ - text-align: center; -} - -.plantumlgraph -{ - text-align: center; -} - -.diagraph -{ - text-align: center; -} - -.caption -{ - font-weight: bold; -} - -div.zoom -{ - border: 1px solid #90A5CE; -} - -dl.citelist { - margin-bottom:50px; -} - -dl.citelist dt { - color:#334975; - float:left; - font-weight:bold; - margin-right:10px; - padding:5px; -} - -dl.citelist dd { - margin:2px 0; - padding:5px 0; -} - -div.toc { - padding: 14px 25px; - background-color: #F4F6FA; - border: 1px solid #D8DFEE; - border-radius: 7px 7px 7px 7px; - float: right; - height: auto; - margin: 0 8px 10px 10px; - width: 200px; -} - -.PageDocRTL-title div.toc { - float: left !important; - text-align: right; -} - -div.toc li { - background: url("bdwn.png") no-repeat scroll 0 5px transparent; - font: 10px/1.2 Verdana,DejaVu Sans,Geneva,sans-serif; - margin-top: 5px; - padding-left: 10px; - padding-top: 2px; -} - -.PageDocRTL-title div.toc li { - background-position-x: right !important; - padding-left: 0 !important; - padding-right: 10px; -} - -div.toc h3 { - font: bold 12px/1.2 Arial,FreeSans,sans-serif; - color: #4665A2; - border-bottom: 0 none; - margin: 0; -} - -div.toc ul { - list-style: none outside none; - border: medium none; - padding: 0px; -} - -div.toc li.level1 { - margin-left: 0px; -} - -div.toc li.level2 { - margin-left: 15px; -} - -div.toc li.level3 { - margin-left: 30px; -} - -div.toc li.level4 { - margin-left: 45px; -} - -.PageDocRTL-title div.toc li.level1 { - margin-left: 0 !important; - margin-right: 0; -} - -.PageDocRTL-title div.toc li.level2 { - margin-left: 0 !important; - margin-right: 15px; -} - -.PageDocRTL-title div.toc li.level3 { - margin-left: 0 !important; - margin-right: 30px; -} - -.PageDocRTL-title div.toc li.level4 { - margin-left: 0 !important; - margin-right: 45px; -} - -.inherit_header { - font-weight: bold; - color: gray; - cursor: pointer; - -webkit-touch-callout: none; - -webkit-user-select: none; - -khtml-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; -} - -.inherit_header td { - padding: 6px 0px 2px 5px; -} - -.inherit { - display: none; -} - -tr.heading h2 { - margin-top: 12px; - margin-bottom: 4px; -} - -/* tooltip related style info */ - -.ttc { - position: absolute; - display: none; -} - -#powerTip { - cursor: default; - white-space: nowrap; - background-color: white; - border: 1px solid gray; - border-radius: 4px 4px 4px 4px; - box-shadow: 1px 1px 7px gray; - display: none; - font-size: smaller; - max-width: 80%; - opacity: 0.9; - padding: 1ex 1em 1em; - position: absolute; - z-index: 2147483647; -} - -#powerTip div.ttdoc { - color: grey; - font-style: italic; -} - -#powerTip div.ttname a { - font-weight: bold; -} - -#powerTip div.ttname { - font-weight: bold; -} - -#powerTip div.ttdeci { - color: #006318; -} - -#powerTip div { - margin: 0px; - padding: 0px; - font: 12px/16px Roboto,sans-serif; -} - -#powerTip:before, #powerTip:after { - content: ""; - position: absolute; - margin: 0px; -} - -#powerTip.n:after, #powerTip.n:before, -#powerTip.s:after, #powerTip.s:before, -#powerTip.w:after, #powerTip.w:before, -#powerTip.e:after, #powerTip.e:before, -#powerTip.ne:after, #powerTip.ne:before, -#powerTip.se:after, #powerTip.se:before, -#powerTip.nw:after, #powerTip.nw:before, -#powerTip.sw:after, #powerTip.sw:before { - border: solid transparent; - content: " "; - height: 0; - width: 0; - position: absolute; -} - -#powerTip.n:after, #powerTip.s:after, -#powerTip.w:after, #powerTip.e:after, -#powerTip.nw:after, #powerTip.ne:after, -#powerTip.sw:after, #powerTip.se:after { - border-color: rgba(255, 255, 255, 0); -} - -#powerTip.n:before, #powerTip.s:before, -#powerTip.w:before, #powerTip.e:before, -#powerTip.nw:before, #powerTip.ne:before, -#powerTip.sw:before, #powerTip.se:before { - border-color: rgba(128, 128, 128, 0); -} - -#powerTip.n:after, #powerTip.n:before, -#powerTip.ne:after, #powerTip.ne:before, -#powerTip.nw:after, #powerTip.nw:before { - top: 100%; -} - -#powerTip.n:after, #powerTip.ne:after, #powerTip.nw:after { - border-top-color: #FFFFFF; - border-width: 10px; - margin: 0px -10px; -} -#powerTip.n:before { - border-top-color: #808080; - border-width: 11px; - margin: 0px -11px; -} -#powerTip.n:after, #powerTip.n:before { - left: 50%; -} - -#powerTip.nw:after, #powerTip.nw:before { - right: 14px; -} - -#powerTip.ne:after, #powerTip.ne:before { - left: 14px; -} - -#powerTip.s:after, #powerTip.s:before, -#powerTip.se:after, #powerTip.se:before, -#powerTip.sw:after, #powerTip.sw:before { - bottom: 100%; -} - -#powerTip.s:after, #powerTip.se:after, #powerTip.sw:after { - border-bottom-color: #FFFFFF; - border-width: 10px; - margin: 0px -10px; -} - -#powerTip.s:before, #powerTip.se:before, #powerTip.sw:before { - border-bottom-color: #808080; - border-width: 11px; - margin: 0px -11px; -} - -#powerTip.s:after, #powerTip.s:before { - left: 50%; -} - -#powerTip.sw:after, #powerTip.sw:before { - right: 14px; -} - -#powerTip.se:after, #powerTip.se:before { - left: 14px; -} - -#powerTip.e:after, #powerTip.e:before { - left: 100%; -} -#powerTip.e:after { - border-left-color: #FFFFFF; - border-width: 10px; - top: 50%; - margin-top: -10px; -} -#powerTip.e:before { - border-left-color: #808080; - border-width: 11px; - top: 50%; - margin-top: -11px; -} - -#powerTip.w:after, #powerTip.w:before { - right: 100%; -} -#powerTip.w:after { - border-right-color: #FFFFFF; - border-width: 10px; - top: 50%; - margin-top: -10px; -} -#powerTip.w:before { - border-right-color: #808080; - border-width: 11px; - top: 50%; - margin-top: -11px; -} - -@media print -{ - #top { display: none; } - #side-nav { display: none; } - #nav-path { display: none; } - body { overflow:visible; } - h1, h2, h3, h4, h5, h6 { page-break-after: avoid; } - .summary { display: none; } - .memitem { page-break-inside: avoid; } - #doc-content - { - margin-left:0 !important; - height:auto !important; - width:auto !important; - overflow:inherit; - display:inline; - } -} - -/* @group Markdown */ - -/* -table.markdownTable { - border-collapse:collapse; - margin-top: 4px; - margin-bottom: 4px; -} - -table.markdownTable td, table.markdownTable th { - border: 1px solid #2D4068; - padding: 3px 7px 2px; -} - -table.markdownTableHead tr { -} - -table.markdownTableBodyLeft td, table.markdownTable th { - border: 1px solid #2D4068; - padding: 3px 7px 2px; -} - -th.markdownTableHeadLeft th.markdownTableHeadRight th.markdownTableHeadCenter th.markdownTableHeadNone { - background-color: #374F7F; - color: #FFFFFF; - font-size: 110%; - padding-bottom: 4px; - padding-top: 5px; -} - -th.markdownTableHeadLeft { - text-align: left -} - -th.markdownTableHeadRight { - text-align: right -} - -th.markdownTableHeadCenter { - text-align: center -} -*/ - -table.markdownTable { - border-collapse:collapse; - margin-top: 4px; - margin-bottom: 4px; -} - -table.markdownTable td, table.markdownTable th { - border: 1px solid #2D4068; - padding: 3px 7px 2px; -} - -table.markdownTable tr { -} - -th.markdownTableHeadLeft, th.markdownTableHeadRight, th.markdownTableHeadCenter, th.markdownTableHeadNone { - background-color: #374F7F; - color: #FFFFFF; - font-size: 110%; - padding-bottom: 4px; - padding-top: 5px; -} - -th.markdownTableHeadLeft, td.markdownTableBodyLeft { - text-align: left -} - -th.markdownTableHeadRight, td.markdownTableBodyRight { - text-align: right -} - -th.markdownTableHeadCenter, td.markdownTableBodyCenter { - text-align: center -} - -.DocNodeRTL { - text-align: right; - direction: rtl; -} - -.DocNodeLTR { - text-align: left; - direction: ltr; -} - -table.DocNodeRTL { - width: auto; - margin-right: 0; - margin-left: auto; -} - -table.DocNodeLTR { - width: auto; - margin-right: auto; - margin-left: 0; -} - -tt, code, kbd, samp -{ - display: inline-block; - direction:ltr; -} -/* @end */ - -u { - text-decoration: underline; -} - diff --git a/docs/doxygen.png b/docs/doxygen.png deleted file mode 100644 index 3ff17d8..0000000 Binary files a/docs/doxygen.png and /dev/null differ diff --git a/docs/draw__history_8cpp.xml b/docs/draw__history_8cpp.xml new file mode 100644 index 0000000..3fa2fa4 --- /dev/null +++ b/docs/draw__history_8cpp.xml @@ -0,0 +1,202 @@ + + + + draw_history.cpp + draw_history.hpp + QDebug + algorithm + cstddef + deque + iterator + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + sk::impl + + + + + + + diff --git a/docs/draw__history_8cpp_source.html b/docs/draw__history_8cpp_source.html deleted file mode 100644 index c116a8c..0000000 --- a/docs/draw__history_8cpp_source.html +++ /dev/null @@ -1,300 +0,0 @@ - - - - - - - -Skribble: src/draw_history.cpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
draw_history.cpp
-
-
-
1 #include "draw_history.hpp"
-
2 
-
3 #include <QDebug>
-
4 
-
5 #include <algorithm>
-
6 #include <cstddef>
-
7 #include <deque>
-
8 #include <iterator>
-
9 
-
10 namespace sk::impl {
-
11 
-
12 auto CachedLayers::PixmapDrawer(QPixmap& dest, QPixmap& src) -> void
-
13 {
-
14  QPainter painter{ &dest };
-
15  painter.drawPixmap(
-
16  CachedLayers::m_canvasRect, src, CachedLayers::m_canvasRect);
-
17 }
-
18 
-
19 auto CachedLayers::PixmapInit(QPixmap& pixmap) noexcept -> void
-
20 {
-
21  pixmap.fill(m_transparent);
-
22 }
-
23 
-
24 CachedLayers::CachedLayers(bool const foreign)
-
25  : m_foreign{ foreign }
-
26 {
-
27  m_layers.emplaceBack(sk::config::width, sk::config::height);
-
28 }
-
29 
-
30 auto CachedLayers::pushNewLayer() -> void
-
31 {
-
32  m_layers.emplaceBack(sk::config::width, sk::config::height);
-
33 }
-
34 
-
35 auto CachedLayers::paintBlock(QPainter& painter) -> void
-
36 {
-
37  painter.drawPixmap(m_canvasRect, m_layers.get(), m_canvasRect);
-
38 }
-
39 
-
40 [[nodiscard]] auto CachedLayers::getLastLayer() noexcept -> QPixmap&
-
41 {
-
42  return m_layers.get();
-
43 }
-
44 
-
45 [[nodiscard]] auto CachedLayers::getLastLayer() const noexcept -> QPixmap const&
-
46 {
-
47  return m_layers.get();
-
48 }
-
49 
-
50 [[nodiscard]] auto CachedLayers::undo() -> bool
-
51 {
-
52  return m_layers.undo();
-
53 }
-
54 
-
55 auto CachedLayers::redo() -> bool
-
56 {
-
57  return m_layers.redo();
-
58 }
-
59 
-
60 } // namespace sk::impl
-
61 
-
62 namespace sk {
-
63 
-
64 auto DrawHistory::CachedDrawer(impl::CachedLayers& dest,
-
65  impl::CachedLayers& src) -> void
-
66 {
-
67  QPainter painter{ &dest.getLastLayer() };
-
68  src.paintBlock(painter);
-
69 }
-
70 
-
71 DrawHistory::DrawHistory()
-
72 {
-
73  m_layers.emplace_back();
-
74  m_cache.emplaceBack();
-
75 }
-
76 
-
77 auto DrawHistory::pushNewLayer(bool const foreign) -> void
-
78 {
-
79  if(foreign) {
-
80  m_drawingExternally = false;
-
81  m_lastExternalPoint = std::nullopt;
-
82  }
-
83  else {
-
84  m_drawingLocally = false;
-
85  m_lastPoint = std::nullopt;
-
86  }
-
87 
-
88  for(auto& layer : m_layers) {
-
89  if(layer.foreign() == foreign) {
-
90  layer.pushNewLayer();
-
91  }
-
92  }
-
93 }
-
94 
-
95 auto DrawHistory::paintCanvas(QPainter* const painter) -> void
-
96 {
-
97  painter->drawPixmap(impl::CachedLayers::getCanvasRect(),
-
98  m_cache.getLast().getLastLayer(),
-
99  impl::CachedLayers::getCanvasRect());
-
100  for(auto& layer : m_layers) {
-
101  layer.paintBlock(*painter);
-
102  }
-
103 }
-
104 
-
105 auto DrawHistory::popFirst(bool const foreign) -> void
-
106 {
-
107  if(m_layers.empty()) {
-
108  return;
-
109  }
-
110  if(m_layers.front().foreign() != foreign) {
-
111  return;
-
112  }
-
113 
-
114  QPainter painter{ &(m_cache.getLast().getLastLayer()) };
-
115  painter.drawPixmap(impl::CachedLayers::getCanvasRect(),
-
116  m_layers.front().getLastLayer(),
-
117  impl::CachedLayers::getCanvasRect());
-
118 
-
119  m_layers.pop_front();
-
120 }
-
121 
-
122 auto DrawHistory::handleExternal(QPoint const& pos, DrawMode& mode) -> void
-
123 {
-
124  if(auto& last = m_layers.back(); last.foreign()) {
-
125  if(last.underUndo()) {
-
126  last.pushNewLayer();
-
127  }
-
128 
-
129  QPainter painter{ &last.getLastLayer() };
-
130  mode.draw(painter, pos, m_lastExternalPoint);
-
131  }
-
132  else {
-
133  if(!m_drawingExternally) {
-
134  this->popFirst(true);
-
135 
-
136  QPainter painter{ &m_layers.emplace_back(true).getLastLayer() };
-
137  mode.draw(painter, pos, m_lastExternalPoint);
-
138  }
-
139  else {
-
140  for(auto& layer : m_layers) {
-
141  if(layer.foreign()) {
-
142  QPainter painter{ &layer.getLastLayer() };
-
143  mode.draw(painter, pos, m_lastExternalPoint);
-
144  break;
-
145  }
-
146  }
-
147  }
-
148  }
-
149 
-
150  m_drawingExternally = true;
-
151  m_lastExternalPoint = pos;
-
152 }
-
153 
-
154 auto DrawHistory::handleLocal(QPoint const& pos, DrawMode& mode) -> void
-
155 {
-
156  if(auto& last = m_layers.back(); !last.foreign()) {
-
157  if(last.underUndo()) {
-
158  last.pushNewLayer();
-
159  }
-
160 
-
161  QPainter painter{ &last.getLastLayer() };
-
162  mode.draw(painter, pos, m_lastPoint);
-
163  m_drawingLocally = true;
-
164  }
-
165  else {
-
166  if(!m_drawingLocally) {
-
167  this->popFirst(false);
-
168  m_layers.emplace_back(false);
-
169  m_drawingLocally = true;
-
170 
-
171  QPainter painter{ &m_layers.back().getLastLayer() };
-
172  mode.draw(painter, pos, m_lastPoint);
-
173  }
-
174  else {
-
175  for(auto& layer : m_layers) {
-
176  if(!layer.foreign()) {
-
177  QPainter painter{ &layer.getLastLayer() };
-
178  mode.draw(painter, pos, m_lastPoint);
-
179  break;
-
180  }
-
181  }
-
182  }
-
183  }
-
184 
-
185  m_lastPoint = pos;
-
186 }
-
187 
-
188 auto DrawHistory::drawAt(QPoint const& pos, DrawMode& mode, bool const foreign)
-
189  -> void
-
190 {
-
191  if(foreign) {
-
192  this->handleExternal(pos, mode);
-
193  }
-
194  else {
-
195  this->handleLocal(pos, mode);
-
196  }
-
197 }
-
198 
-
199 auto DrawHistory::undo(bool const foreign) -> void
-
200 {
-
201  for(auto& layer : m_layers) {
-
202  if(layer.foreign() == foreign) {
-
203  static_cast<void>(layer.undo());
-
204  break;
-
205  }
-
206  }
-
207 }
-
208 
-
209 auto DrawHistory::redo(bool const foreign) -> void
-
210 {
-
211  for(auto& layer : m_layers) {
-
212  if(layer.foreign() == foreign) {
-
213  static_cast<void>(layer.redo());
-
214  break;
-
215  }
-
216  }
-
217 }
-
218 
-
219 } // namespace sk
-
- - - - diff --git a/docs/draw__history_8hpp.xml b/docs/draw__history_8hpp.xml new file mode 100644 index 0000000..c700b2c --- /dev/null +++ b/docs/draw__history_8hpp.xml @@ -0,0 +1,224 @@ + + + + draw_history.hpp + cached_resource.hpp + canvas_config.hpp + draw_mode.hpp + fixed_cached_resource.hpp + QColor + QPainter + QPixmap + QPoint + deque + memory + optional + vector + src/canvas.hpp + src/draw_history.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::impl::CachedLayers + sk::DrawHistory + sk::DrawHistory::Traits + sk + sk::impl + + + + + + + diff --git a/docs/draw__history_8hpp_source.html b/docs/draw__history_8hpp_source.html deleted file mode 100644 index b8eafd5..0000000 --- a/docs/draw__history_8hpp_source.html +++ /dev/null @@ -1,207 +0,0 @@ - - - - - - - -Skribble: src/draw_history.hpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
draw_history.hpp
-
-
-
1 #ifndef DRAW_HISTORY_HPP
-
2 #define DRAW_HISTORY_HPP
-
3 #pragma once
-
4 
-
5 #include "cached_resource.hpp"
-
6 #include "canvas_config.hpp"
-
7 #include "draw_mode.hpp"
-
8 #include "fixed_cached_resource.hpp"
-
9 
-
10 #include <QColor>
-
11 #include <QPainter>
-
12 #include <QPixmap>
-
13 #include <QPoint>
-
14 
-
15 #include <deque>
-
16 #include <memory>
-
17 #include <optional>
-
18 #include <vector>
-
19 
-
20 namespace sk::impl {
-
21 
- -
23 {
-
24 private:
-
25  bool const m_foreign{ false };
-
26 
-
27  static auto PixmapDrawer(QPixmap& dest, QPixmap& src) -> void;
-
28  static auto PixmapInit(QPixmap& pixmap) noexcept -> void;
-
29 
-
30  sk::FCachedResource<QPixmap> m_layers{ &PixmapDrawer, &PixmapInit };
-
31 
-
32  static constexpr QColor m_transparent{ 0, 0, 0, 0 };
-
33  static constexpr QRect m_canvasRect{
-
34  0, 0, sk::config::width, sk::config::height
-
35  };
-
36 
-
37 public:
-
38  explicit CachedLayers(bool const foreign = false);
-
39  CachedLayers(CachedLayers const&) = default;
-
40  CachedLayers(CachedLayers&&) = default;
-
41  ~CachedLayers() noexcept = default;
-
42 
-
43  auto operator=(CachedLayers const&) -> CachedLayers& = delete;
-
44  auto operator=(CachedLayers &&) -> CachedLayers& = delete;
-
45 
-
46  static constexpr auto getCanvasRect() -> QRect
-
47  {
-
48  return m_canvasRect;
-
49  }
-
50 
-
51  auto pushNewLayer() -> void;
-
52  auto paintBlock(QPainter& painter) -> void;
-
53  [[nodiscard]] auto getLastLayer() noexcept -> QPixmap&;
-
54  [[nodiscard]] auto getLastLayer() const noexcept -> QPixmap const&;
-
55 
-
56  [[nodiscard]] constexpr auto foreign() const noexcept -> bool
-
57  {
-
58  return m_foreign;
-
59  }
-
60 
-
61  [[nodiscard]] inline auto underUndo() const noexcept -> bool
-
62  {
-
63  return m_layers.underUndo();
-
64  }
-
65 
-
70  [[nodiscard]] auto undo() -> bool;
-
71  auto redo() -> bool;
-
72 };
-
73 
-
74 } // namespace sk::impl
-
75 
-
76 namespace sk {
-
77 
- -
79 {
-
80 private:
-
81  static auto CachedDrawer(impl::CachedLayers& dest, impl::CachedLayers& src)
-
82  -> void;
-
83 
-
84  struct Traits
-
85  {
-
86  using ContainerType = std::deque<impl::CachedLayers>;
-
87  static constexpr int cacheGap = 3;
-
88  static constexpr int maxCount = 10;
-
89  };
-
90 
-
91  std::list<impl::CachedLayers> m_layers{};
- -
93 
-
94  std::optional<QPoint> m_lastPoint{ std::nullopt };
-
95  std::optional<QPoint> m_lastExternalPoint{ std::nullopt };
-
96 
-
97  bool m_drawingLocally{ false };
-
98  bool m_drawingExternally{ false };
-
99 
-
100  auto handleExternal(QPoint const& pos, DrawMode& mode) -> void;
-
101  auto handleLocal(QPoint const& pos, DrawMode& mode) -> void;
-
102  auto popFirst(bool const foreign) -> void;
-
103 
-
104 public:
-
105  DrawHistory();
-
106  DrawHistory(DrawHistory const&) = delete;
-
107  DrawHistory(DrawHistory&&) = default;
-
108  ~DrawHistory() noexcept = default;
-
109 
-
110  auto operator=(DrawHistory const&) -> DrawHistory& = delete;
-
111  auto operator=(DrawHistory &&) -> DrawHistory& = delete;
-
112 
-
113  auto pushNewLayer(bool const foreign = false) -> void;
-
114  auto paintCanvas(QPainter* const painter) -> void;
-
115 
-
116  auto drawAt(QPoint const& pos, DrawMode& mode, bool const foreign = false)
-
117  -> void;
-
118  auto undo(bool const foreign = false) -> void;
-
119  auto redo(bool const foreign = false) -> void;
-
120 };
-
121 
-
122 } // namespace sk
-
123 
-
124 #endif // !DRAW_HISTORY_HPP
-
- - - - - - - - - - diff --git a/docs/draw__mode_8cpp.xml b/docs/draw__mode_8cpp.xml new file mode 100644 index 0000000..dc8dda5 --- /dev/null +++ b/docs/draw__mode_8cpp.xml @@ -0,0 +1,60 @@ + + + + draw_mode.cpp + draw_mode.hpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + + + + + + + diff --git a/docs/draw__mode_8cpp_source.html b/docs/draw__mode_8cpp_source.html deleted file mode 100644 index 52f96ff..0000000 --- a/docs/draw__mode_8cpp_source.html +++ /dev/null @@ -1,135 +0,0 @@ - - - - - - - -Skribble: src/draw_mode.cpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
draw_mode.cpp
-
-
-
1 #include "draw_mode.hpp"
-
2 
-
3 namespace sk {
-
4 
-
5 int DrawMode::m_width = DrawMode::m_defaultWidth;
-
6 QColor DrawMode::m_color = DrawMode::m_defaultColor;
-
7 
-
8 PenMode::PenMode(QPen const& pen)
-
9  : m_pen{ pen }
-
10 {
-
11 }
-
12 
-
13 PenMode::PenMode(QPen&& pen)
-
14  : m_pen{ std::move(pen) }
-
15 {
-
16 }
-
17 
-
18 auto PenMode::draw(QPainter& painter,
-
19  QPoint const& pos,
-
20  std::optional<QPoint> const& lastPoint) -> void
-
21 {
-
22  m_pen.setColor(m_color);
-
23  m_pen.setWidth(m_width);
-
24  painter.setPen(m_pen);
-
25 
-
26  if(lastPoint.has_value()) {
-
27  painter.drawLine(pos, lastPoint.value());
-
28  }
-
29  else {
-
30  painter.drawPoint(pos);
-
31  }
-
32 }
-
33 
-
34 BrushMode::BrushMode(QBrush const& brush)
-
35  : m_brush{ brush }
-
36 {
-
37 }
-
38 
-
39 BrushMode::BrushMode(QBrush&& brush)
-
40  : m_brush{ std::move(brush) }
-
41 {
-
42 }
-
43 
-
44 auto BrushMode::draw(QPainter& painter,
-
45  QPoint const& pos,
-
46  std::optional<QPoint> const&) -> void
-
47 {
-
48  m_brush.setColor(m_color);
-
49  painter.setBrush(m_brush);
-
50  painter.setPen(Qt::NoPen);
-
51  painter.drawEllipse(pos, m_width / 2, m_width / 2);
-
52 }
-
53 
-
54 } // namespace sk
-
- - - - diff --git a/docs/draw__mode_8hpp.xml b/docs/draw__mode_8hpp.xml new file mode 100644 index 0000000..7b6a5b6 --- /dev/null +++ b/docs/draw__mode_8hpp.xml @@ -0,0 +1,110 @@ + + + + draw_mode.hpp + QBrush + QColor + QPainter + QPen + optional + utility + QToolBar + src/draw_history.hpp + src/canvas.hpp + src/draw_mode.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::DrawMode + sk::PenMode + sk::BrushMode + sk + + + + + + + diff --git a/docs/draw__mode_8hpp_source.html b/docs/draw__mode_8hpp_source.html deleted file mode 100644 index c022014..0000000 --- a/docs/draw__mode_8hpp_source.html +++ /dev/null @@ -1,224 +0,0 @@ - - - - - - - -Skribble: src/draw_mode.hpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
draw_mode.hpp
-
-
-
1 #ifndef DRAW_MODE_HPP
-
2 #define DRAW_MODE_HPP
-
3 #pragma once
-
4 
-
5 #include <QBrush>
-
6 #include <QColor>
-
7 #include <QPainter>
-
8 #include <QPen>
-
9 
-
10 #include <optional>
-
11 #include <utility>
-
12 
-
13 #include <QToolBar>
-
14 
-
15 namespace sk {
-
16 
-
17 class DrawMode
-
18 {
-
19 protected:
-
20  static constexpr int m_defaultWidth = 5;
-
21  static constexpr QColor m_defaultColor{ 0, 0, 0 };
-
22 
-
23  static int m_width;
-
24  static QColor m_color;
-
25 
-
26 public:
-
27  DrawMode() noexcept = default;
-
28  DrawMode(DrawMode const&) noexcept = default;
-
29  DrawMode(DrawMode&&) noexcept = default;
-
30  virtual ~DrawMode() noexcept = default;
-
31 
-
32  auto operator=(DrawMode const&) noexcept -> DrawMode& = default;
-
33  auto operator=(DrawMode&&) noexcept -> DrawMode& = default;
-
34 
-
35  virtual auto draw(QPainter& painter,
-
36  QPoint const& pos,
-
37  std::optional<QPoint> const& lastPoint) -> void = 0;
-
38 
-
39  [[nodiscard]] inline auto getWidth() const noexcept -> int
-
40  {
-
41  return m_width;
-
42  }
-
43  inline auto setWidth(int const width) noexcept -> void
-
44  {
-
45  m_width = width;
-
46  }
-
47 
-
48  [[nodiscard]] inline auto getColor() const noexcept -> QColor
-
49  {
-
50  return m_color;
-
51  }
-
52  inline auto setColor(QColor const& color) noexcept -> void
-
53  {
-
54  m_color = color;
-
55  }
-
56 
-
57  [[nodiscard]] static constexpr auto getDefaultColor() noexcept -> QColor
-
58  {
-
59  return m_defaultColor;
-
60  }
-
61  [[nodiscard]] static constexpr auto getDefaultWidth() noexcept -> int
-
62  {
-
63  return m_defaultWidth;
-
64  }
-
65 };
-
66 
-
67 class PenMode : public DrawMode
-
68 {
-
69 private:
-
70  QPen m_pen{ QColor{ "black" },
-
71  m_defaultWidth,
-
72  Qt::SolidLine,
-
73  Qt::RoundCap,
-
74  Qt::RoundJoin };
-
75 
-
76 public:
-
77  PenMode() = default;
-
78  PenMode(PenMode const&) noexcept = default;
-
79  PenMode(PenMode&&) noexcept = default;
-
80  ~PenMode() noexcept override = default;
-
81 
-
82  explicit PenMode(QPen const& pen);
-
83  explicit PenMode(QPen&& pen);
-
84 
-
85  auto operator=(PenMode const&) noexcept -> PenMode& = default;
-
86  auto operator=(PenMode&&) noexcept -> PenMode& = default;
-
87 
-
88  auto draw(QPainter& painter,
-
89  QPoint const& pos,
-
90  std::optional<QPoint> const& lastPoint) -> void override;
-
91 };
-
92 
-
93 class BrushMode : public DrawMode
-
94 {
-
95 private:
-
96  QBrush m_brush{ QColor{ "black" }, Qt::BrushStyle::SolidPattern };
-
97 
-
98 public:
-
99  BrushMode() noexcept = default;
-
100  BrushMode(BrushMode const&) noexcept = default;
-
101  BrushMode(BrushMode&&) = default;
-
102  ~BrushMode() noexcept override = default;
-
103 
-
104  explicit BrushMode(QBrush const& brush);
-
105  explicit BrushMode(QBrush&& brush);
-
106 
-
107  auto operator=(BrushMode const&) noexcept -> BrushMode& = default;
-
108  auto operator=(BrushMode&&) noexcept -> BrushMode& = default;
-
109 
-
110  auto draw(QPainter& painter,
-
111  QPoint const& pos,
-
112  std::optional<QPoint> const& lastPos) -> void override;
-
113 };
-
114 
-
115 [[nodiscard]] inline auto makeDrawMode(QPen&& pen) -> std::unique_ptr<PenMode>
-
116 {
-
117  return std::make_unique<PenMode>(std::forward<QPen>(pen));
-
118 }
-
119 
-
120 [[nodiscard]] inline auto makeDrawMode(QBrush&& brush)
-
121  -> std::unique_ptr<BrushMode>
-
122 {
-
123  return std::make_unique<BrushMode>(std::forward<QBrush>(brush));
-
124 }
-
125 
-
126 [[nodiscard]] inline auto makeDrawMode(PenMode&& pen)
-
127  -> std::unique_ptr<PenMode>
-
128 {
-
129  return std::make_unique<PenMode>(std::forward<PenMode>(pen));
-
130 }
-
131 
-
132 [[nodiscard]] inline auto makeDrawMode(BrushMode&& brush)
-
133  -> std::unique_ptr<BrushMode>
-
134 {
-
135  return std::make_unique<BrushMode>(std::forward<BrushMode>(brush));
-
136 }
-
137 
-
138 } // namespace sk
-
139 
-
140 #endif // !DRAW_MODE_HPP
-
- - - - - - - diff --git a/docs/dummy__network_8cpp.xml b/docs/dummy__network_8cpp.xml new file mode 100644 index 0000000..d996fe3 --- /dev/null +++ b/docs/dummy__network_8cpp.xml @@ -0,0 +1,64 @@ + + + + dummy_network.cpp + dummy_network.hpp + QDebug + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + + + + + + + diff --git a/docs/dummy__network_8cpp_source.html b/docs/dummy__network_8cpp_source.html deleted file mode 100644 index 37b8b80..0000000 --- a/docs/dummy__network_8cpp_source.html +++ /dev/null @@ -1,93 +0,0 @@ - - - - - - - -Skribble: src/dummy_network.cpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
dummy_network.cpp
-
-
-
1 #include "dummy_network.hpp"
-
2 
-
3 #include <QDebug>
-
4 
-
5 namespace sk {
-
6 
-
7 auto DummyNetwork::getSocket() -> QTcpSocket*
-
8 {
-
9  return nullptr;
-
10 }
-
11 
-
12 } // namespace sk
-
- - - - diff --git a/docs/dummy__network_8hpp.xml b/docs/dummy__network_8hpp.xml new file mode 100644 index 0000000..30c175c --- /dev/null +++ b/docs/dummy__network_8hpp.xml @@ -0,0 +1,89 @@ + + + + dummy_network.hpp + abstract_network.hpp + QTcpSocket + src/canvas.cpp + src/network_factory.hpp + src/dummy_network.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::DummyNetwork + sk + + + + + + + diff --git a/docs/dummy__network_8hpp_source.html b/docs/dummy__network_8hpp_source.html deleted file mode 100644 index 0e4a6e5..0000000 --- a/docs/dummy__network_8hpp_source.html +++ /dev/null @@ -1,111 +0,0 @@ - - - - - - - -Skribble: src/dummy_network.hpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
dummy_network.hpp
-
-
-
1 #ifndef DUMMY_NETWORK_HPP
-
2 #define DUMMY_NETWORK_HPP
-
3 #pragma once
-
4 
-
5 #include "abstract_network.hpp"
-
6 
-
7 #include <QTcpSocket>
-
8 
-
9 namespace sk {
-
10 
-
11 class DummyNetwork final : public AbstractNetwork
-
12 {
-
13 private:
-
14 public:
-
15  DummyNetwork() = default;
-
16  DummyNetwork(DummyNetwork const&) = delete;
-
17  DummyNetwork(DummyNetwork&&) = delete;
-
18  ~DummyNetwork() noexcept override = default;
-
19 
-
20  auto operator=(DummyNetwork const&) -> DummyNetwork& = delete;
-
21  auto operator=(DummyNetwork&&) noexcept -> DummyNetwork& = delete;
-
22 
-
23  auto getSocket() -> QTcpSocket* override;
-
24 };
-
25 
-
26 } // namespace sk
-
27 
-
28 #endif // !DUMMY_NETWORK_HPP
-
- - - - - - diff --git a/docs/dynsections.js b/docs/dynsections.js deleted file mode 100644 index c8e84aa..0000000 --- a/docs/dynsections.js +++ /dev/null @@ -1,127 +0,0 @@ -/* - @licstart The following is the entire license notice for the - JavaScript code in this file. - - Copyright (C) 1997-2017 by Dimitri van Heesch - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License along - with this program; if not, write to the Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - - @licend The above is the entire license notice - for the JavaScript code in this file - */ -function toggleVisibility(linkObj) -{ - var base = $(linkObj).attr('id'); - var summary = $('#'+base+'-summary'); - var content = $('#'+base+'-content'); - var trigger = $('#'+base+'-trigger'); - var src=$(trigger).attr('src'); - if (content.is(':visible')===true) { - content.hide(); - summary.show(); - $(linkObj).addClass('closed').removeClass('opened'); - $(trigger).attr('src',src.substring(0,src.length-8)+'closed.png'); - } else { - content.show(); - summary.hide(); - $(linkObj).removeClass('closed').addClass('opened'); - $(trigger).attr('src',src.substring(0,src.length-10)+'open.png'); - } - return false; -} - -function updateStripes() -{ - $('table.directory tr'). - removeClass('even').filter(':visible:even').addClass('even'); -} - -function toggleLevel(level) -{ - $('table.directory tr').each(function() { - var l = this.id.split('_').length-1; - var i = $('#img'+this.id.substring(3)); - var a = $('#arr'+this.id.substring(3)); - if (l + + + fcached_resource_test.cpp + test.hpp + fixed_cached_resource.hpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + FTraits + FTrait2 + FTraits3 + anonymous_namespace{fcached_resource_test.cpp} + + + auto + auto add + (int &dest, int const &src) -> void + add + + int & + dest + + + int const & + src + + + + + + + + + + + + TEST + ("[FCachedResource] Undo/Redo") + TEST + + " Undo/Redo" + [FCachedResource] + + + + + + + + + + + + TEST + ("[FCachedResource] emplaceBack") + TEST + + " emplaceBack" + [FCachedResource] + + + + + + + + + + + + TEST + ("[FCachedResource] maxCount") + TEST + + " maxCount" + [FCachedResource] + + + + + + + + + + + + + + + + + diff --git a/docs/fcached__resource__test_8cpp_source.html b/docs/fcached__resource__test_8cpp_source.html deleted file mode 100644 index de02e8e..0000000 --- a/docs/fcached__resource__test_8cpp_source.html +++ /dev/null @@ -1,268 +0,0 @@ - - - - - - - -Skribble: tests/fcached_resource_test.cpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
fcached_resource_test.cpp
-
-
-
1 #include "test.hpp"
-
2 
-
3 #include "fixed_cached_resource.hpp"
-
4 
-
5 auto add(int& dest, int const& src) -> void
-
6 {
-
7  dest += src;
-
8 }
-
9 
-
10 namespace {
-
11 
-
12 auto adder = [](int& dest, int& src) -> void { dest += src; };
-
13 auto init = [](int& num) -> void { num = 0; };
-
14 
-
15 } // namespace
-
16 
-
17 template<typename T>
-
18 struct FTraits
-
19 {
-
20  using ContainerType = std::deque<T>;
-
21  static constexpr int maxCount = 10;
-
22 };
-
23 
-
24 TEST("[FCachedResource] Undo/Redo")
-
25 {
-
26  sk::FCachedResource<int, FTraits<int>> res{ adder, init };
-
27 
-
28  for(int i = 0; i < 10; ++i) {
-
29  add(res.emplaceBack(), i + 1);
-
30  }
-
31 
-
32  ASSERT(res.get() == 55);
-
33 
-
34  bool undo = res.undo();
-
35 
-
36  ASSERT(undo == true);
-
37  ASSERT(res.underUndo());
-
38 
-
39  for(int i = 0; i < 8; ++i) {
-
40  undo = res.undo();
-
41  ASSERT(undo == true);
-
42  ASSERT(res.underUndo());
-
43  }
-
44 
-
45  undo = res.undo();
-
46 
-
47  ASSERT(undo == false);
-
48  ASSERT(res.get() == 1);
-
49  ASSERT(res.underUndo());
-
50 
-
51  bool redo = res.redo();
-
52 
-
53  ASSERT(redo == true);
-
54  ASSERT(res.get() == 3);
-
55  ASSERT(res.underUndo());
-
56 
-
57  for(int i = 0; i < 7; ++i) {
-
58  redo = res.redo();
-
59  ASSERT(redo == true);
-
60  ASSERT(res.underUndo());
-
61  }
-
62 
-
63  redo = res.redo();
-
64 
-
65  ASSERT(redo == false);
-
66  ASSERT(res.underUndo() == false);
-
67 
-
68  for(int i = 0; i < 9; ++i) {
-
69  undo = res.undo();
-
70  ASSERT(undo == true);
-
71  ASSERT(res.underUndo());
-
72  }
-
73 
-
74  add(res.emplaceBack(), 10);
-
75 
-
76  ASSERT(res.get() == 11);
-
77  ASSERT(!res.underUndo());
-
78  ASSERT(res.redo() == false);
-
79 }
-
80 
-
81 template<typename T>
-
82 struct FTrait2
-
83 {
-
84  using ContainerType = std::deque<T>;
-
85  static constexpr int maxCount = 10;
-
86 };
-
87 
-
88 TEST("[FCachedResource] emplaceBack")
-
89 {
-
90  sk::FCachedResource<int, FTrait2<int>> res{ adder, init };
-
91 
-
92  for(int i = 0; i < FTrait2<int>::maxCount; ++i) {
-
93  add(res.emplaceBack(), i + 1);
-
94  ASSERT(res.underUndo() == false);
-
95  }
-
96 
-
97  ASSERT(res.get() == 55);
-
98  ASSERT(res.getUnderlying().size() == 10);
-
99 
-
100  bool undo = res.undo();
-
101 
-
102  ASSERT(undo == true);
-
103  ASSERT(res.underUndo());
-
104 
-
105  for(int i = 0; i < 3; ++i) {
-
106  undo = res.undo();
-
107  ASSERT(undo == true);
-
108  ASSERT(res.underUndo());
-
109  }
-
110 
-
111  ASSERT(res.get() == 21);
-
112 
-
113  add(res.emplaceBack(), 10);
-
114 
-
115  ASSERT(!res.underUndo());
-
116  ASSERT(res.get() == 31);
-
117  ASSERT(res.redo() == false);
-
118 
-
119  while(res.undo()) {
-
120  }
-
121 
-
122  add(res.emplaceBack(), 10);
-
123 
-
124  ASSERT(res.get() == 11);
-
125  ASSERT(!res.underUndo());
-
126 }
-
127 
-
128 template<typename T>
-
129 struct FTraits3
-
130 {
-
131  using ContainerType = std::deque<T>;
-
132  static constexpr int maxCount = 3;
-
133 };
-
134 
-
135 TEST("[FCachedResource] maxCount")
-
136 {
-
137  sk::FCachedResource<int, FTraits3<int>> res{ adder, init };
-
138 
-
139  for(int i = 0; i < 10; ++i) {
-
140  add(res.emplaceBack(), i + 1);
-
141  ASSERT(!res.underUndo());
-
142  }
-
143 
-
144  ASSERT(res.getUnderlying().size() == FTraits3<int>::maxCount);
-
145  ASSERT(res.get() == 55);
-
146 
-
147  add(res.emplaceBack(), 11);
-
148  add(res.emplaceBack(), 12);
-
149 
-
150  ASSERT(res.get() == 78);
-
151  ASSERT(res.getUnderlying().size() == FTraits3<int>::maxCount);
-
152 
-
153  add(res.emplaceBack(), 13);
-
154 
-
155  ASSERT(res.get() == 91);
-
156  ASSERT(res.getUnderlying().size() == FTraits3<int>::maxCount);
-
157 
-
158  bool undo{ true };
-
159 
-
160  for(int i = 0; i < 2; ++i) {
-
161  undo = res.undo();
-
162  ASSERT(undo == true);
-
163  ASSERT(res.underUndo());
-
164  }
-
165 
-
166  undo = res.undo();
-
167 
-
168  ASSERT(undo == false);
-
169  ASSERT(res.get() == 66);
-
170  ASSERT(res.underUndo());
-
171 
-
172  bool redo = res.redo();
-
173 
-
174  ASSERT(redo == true);
-
175  ASSERT(res.get() == 78);
-
176  ASSERT(res.underUndo());
-
177 
-
178  redo = res.redo();
-
179 
-
180  ASSERT(redo == false);
-
181  ASSERT(res.get() == 91);
-
182  ASSERT(!res.underUndo());
-
183 }
-
- - - - - - - - diff --git a/docs/files.html b/docs/files.html index d4be26f..004a3d5 100644 --- a/docs/files.html +++ b/docs/files.html @@ -1,113 +1,115 @@ - - + + - - - - -Skribble: File List - - - - - - - + + Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

Files

+
    +
+ +
+
+
+
+ - - - - - - - -
- -
-
- - -
- -
- -
-
-
File List
-
-
-
Here is a list of all documented files with brief descriptions:
-
[detail level 123]
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  src
 abstract_network.cpp
 abstract_network.hpp
 cached_resource.hpp
 canvas.cpp
 canvas.hpp
 canvas_config.hpp
 client.cpp
 client.hpp
 draw_history.cpp
 draw_history.hpp
 draw_mode.cpp
 draw_mode.hpp
 dummy_network.cpp
 dummy_network.hpp
 fixed_cached_resource.hpp
 format.hpp
 main.cpp
 message_parser.cpp
 message_parser.hpp
 network_config.hpp
 network_factory.cpp
 network_factory.hpp
 server.cpp
 server.hpp
  tests
  helper
 test.hpp
 cached_resource_test.cpp
 fcached_resource_test.cpp
 format_test.cpp
 message_parser_test.cpp
-
-
- - + + +
diff --git a/docs/fixed__cached__resource_8hpp.xml b/docs/fixed__cached__resource_8hpp.xml new file mode 100644 index 0000000..04028c4 --- /dev/null +++ b/docs/fixed__cached__resource_8hpp.xml @@ -0,0 +1,122 @@ + + + + fixed_cached_resource.hpp + format.hpp + deque + iterator + list + utility + src/draw_history.hpp + tests/fcached_resource_test.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::FResTraits + sk::FCachedResource + sk + + + + + + + diff --git a/docs/fixed__cached__resource_8hpp_source.html b/docs/fixed__cached__resource_8hpp_source.html deleted file mode 100644 index f194291..0000000 --- a/docs/fixed__cached__resource_8hpp_source.html +++ /dev/null @@ -1,219 +0,0 @@ - - - - - - - -Skribble: src/fixed_cached_resource.hpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
fixed_cached_resource.hpp
-
-
-
1 #ifndef FIXED_CACHED_RESOURCE_HPP
-
2 #define FIXED_CACHED_RESOURCE_HPP
-
3 #pragma once
-
4 
-
5 #include "format.hpp"
-
6 
-
7 #include <deque>
-
8 #include <iterator>
-
9 #include <list>
-
10 #include <utility>
-
11 
-
12 namespace sk {
-
13 
-
14 template<typename T>
-
15 struct FResTraits
-
16 {
-
17  using ContainerType = std::list<T>;
-
18  static constexpr int maxCount = 100;
-
19 };
-
20 
-
21 template<typename T, typename Traits = FResTraits<T>>
- -
23 {
-
24 private:
-
25  using ContainerType = typename Traits::ContainerType;
-
26  using Iterator = typename ContainerType::iterator;
-
27  using Function = void (*)(T&, T&);
-
28  using InitFunction = void (*)(T&);
-
29 
-
30  static constexpr int m_maxCount = Traits::maxCount;
-
31 
-
32  static_assert(m_maxCount > 2, "MaxCount should be bigger than 2");
-
33 
-
34  ContainerType m_data{};
-
35  Iterator m_iterator{};
-
36  Function m_function{};
-
37  InitFunction m_initFunction{};
-
38  bool m_underUndo{ false };
-
39 
-
40 public:
-
41  FCachedResource() = delete;
-
42  FCachedResource(FCachedResource const&) = default;
-
43  FCachedResource(FCachedResource&&) noexcept = default;
-
44  ~FCachedResource() noexcept = default;
-
45 
-
46  explicit FCachedResource(Function f, InitFunction init)
-
47  : m_function{ f }
-
48  , m_initFunction{ init }
-
49  {
-
50  }
-
51 
-
52  auto operator=(FCachedResource const&) -> FCachedResource& = default;
-
53  auto operator=(FCachedResource&&) noexcept -> FCachedResource& = default;
-
54 
-
55  template<typename... Ts>
-
56  auto emplaceBack(Ts&&... args) -> T&
-
57  {
-
58  if(m_underUndo) {
-
59  m_data.erase(std::next(m_iterator), m_data.end());
-
60  m_underUndo = false;
-
61  }
-
62  if(!m_data.empty()) {
-
63  m_data.emplace_back(*m_iterator);
-
64  ++m_iterator;
-
65  }
-
66  else {
-
67  m_initFunction(m_data.emplace_back(std::forward<Ts>(args)...));
-
68  m_iterator = m_data.begin();
-
69  }
-
70 
-
71  if(m_data.size() > m_maxCount) {
-
72  m_data.pop_front();
-
73  }
-
74 
-
75  return *m_iterator;
-
76  }
-
77 
-
78  [[nodiscard]] inline auto underUndo() const noexcept -> bool
-
79  {
-
80  return m_underUndo;
-
81  }
-
82 
-
83  [[nodiscard]] auto get() noexcept -> T&
-
84  {
-
85  return *m_iterator;
-
86  }
-
87  [[nodiscard]] auto get() const noexcept -> T const&
-
88  {
-
89  return *m_iterator;
-
90  }
-
91 
-
92  [[nodiscard]] auto undo() -> bool
-
93  {
-
94  if(m_data.size() <= 1) {
-
95  m_underUndo = false;
-
96  return false;
-
97  }
-
98  m_underUndo = true;
-
99 
-
100  if(std::distance(m_data.begin(), m_iterator) <= 0) {
-
101  return false;
-
102  }
-
103 
-
104  --m_iterator;
-
105  return true;
-
106  }
-
107 
-
108  [[nodiscard]] auto redo() -> bool
-
109  {
-
110  if(!m_underUndo) {
-
111  return false;
-
112  }
-
113 
-
114  ++m_iterator;
-
115 
-
116  if(std::distance(m_iterator, m_data.end()) <= 1) {
-
117  m_underUndo = false;
-
118  return false;
-
119  }
-
120 
-
121  return true;
-
122  }
-
123 
-
124  [[nodiscard]] auto getUnderlying() noexcept -> ContainerType&
-
125  {
-
126  return m_data;
-
127  }
-
128  [[nodiscard]] auto getUnderlying() const noexcept -> ContainerType const&
-
129  {
-
130  return m_data;
-
131  }
-
132 };
-
133 
-
134 } // namespace sk
-
135 
-
136 #endif // !FIXED_CACHED_RESOURCE_HPP
-
- - - - - - diff --git a/docs/folderclosed.png b/docs/folderclosed.png deleted file mode 100644 index bb8ab35..0000000 Binary files a/docs/folderclosed.png and /dev/null differ diff --git a/docs/folderopen.png b/docs/folderopen.png deleted file mode 100644 index d6c7f67..0000000 Binary files a/docs/folderopen.png and /dev/null differ diff --git a/docs/format_8hpp.xml b/docs/format_8hpp.xml new file mode 100644 index 0000000..67e6bb8 --- /dev/null +++ b/docs/format_8hpp.xml @@ -0,0 +1,140 @@ + + + + format.hpp + QString + cstddef + iostream + sstream + string + utility + src/abstract_network.cpp + src/fixed_cached_resource.hpp + tests/format_test.cpp + tests/helper/test.hpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + + + + + + + diff --git a/docs/format_8hpp_source.html b/docs/format_8hpp_source.html deleted file mode 100644 index 96dc673..0000000 --- a/docs/format_8hpp_source.html +++ /dev/null @@ -1,136 +0,0 @@ - - - - - - - -Skribble: src/format.hpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
format.hpp
-
-
-
1 #ifndef FORMAT_HPP
-
2 #define FORMAT_HPP
-
3 #pragma once
-
4 
-
5 #include <QString>
-
6 
-
7 #include <cstddef>
-
8 #include <iostream>
-
9 #include <sstream>
-
10 #include <string>
-
11 #include <utility>
-
12 
-
13 namespace sk {
-
14 
-
15 template<std::size_t N, typename... Ts>
-
16 auto format(char const (&fmt)[N], Ts&&... args) -> std::string
-
17 {
-
18  static thread_local std::stringstream ss;
-
19  QString result{ fmt };
-
20 
-
21  ((result = result.arg(
-
22  QString::fromStdString(((ss << std::forward<Ts>(args)), ss.str()))),
-
23  ss.str("")),
-
24  ...);
-
25 
-
26  return result.toStdString();
-
27 }
-
28 
-
29 template<std::size_t N, typename... Ts>
-
30 auto printTo(std::ostream& os, char const (&fmt)[N], Ts&&... args) -> void
-
31 {
-
32  os << format(fmt, std::forward<Ts>(args)...);
-
33 }
-
34 
-
35 template<std::size_t N, typename... Ts>
-
36 auto printlnTo(std::ostream& os, char const (&fmt)[N], Ts&&... args) -> void
-
37 {
-
38  os << format(fmt, std::forward<Ts>(args)...) << std::endl;
-
39 }
-
40 
-
41 template<std::size_t N, typename... Ts>
-
42 auto print(char const (&fmt)[N], Ts&&... args) -> void
-
43 {
-
44  printTo(std::cout, fmt, std::forward<Ts>(args)...);
-
45 }
-
46 
-
47 template<std::size_t N, typename... Ts>
-
48 auto println(char const (&fmt)[N], Ts&&... args) -> void
-
49 {
-
50  printlnTo(std::cout, fmt, std::forward<Ts>(args)...);
-
51 }
-
52 
-
53 } // namespace sk
-
54 
-
55 #endif // !FORMAT_HPP
-
- - - - diff --git a/docs/format__test_8cpp.xml b/docs/format__test_8cpp.xml new file mode 100644 index 0000000..fdfbdf7 --- /dev/null +++ b/docs/format__test_8cpp.xml @@ -0,0 +1,184 @@ + + + + format_test.cpp + format.hpp + test.hpp + thread + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Dummy + + + + TEST + ("[Format] Empty") + TEST + + " Empty" + [Format] + + + + + + + + + + + + TEST + ("[Format] No args") + TEST + + " No args" + [Format] + + + + + + + + + + + + TEST + ("[Format] Basic") + TEST + + " Basic" + [Format] + + + + + + + + + + + + TEST + ("[Format] Custom type") + TEST + + " Custom type" + [Format] + + + + + + + + + + + + TEST + ("[Format] Different threads") + TEST + + " Different threads" + [Format] + + + + + + + + + + + + + + + + + diff --git a/docs/format__test_8cpp_source.html b/docs/format__test_8cpp_source.html deleted file mode 100644 index e6ade06..0000000 --- a/docs/format__test_8cpp_source.html +++ /dev/null @@ -1,162 +0,0 @@ - - - - - - - -Skribble: tests/format_test.cpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
format_test.cpp
-
-
-
1 #include "format.hpp"
-
2 #include "test.hpp"
-
3 
-
4 #include <thread>
-
5 
-
6 TEST("[Format] Empty")
-
7 {
-
8  auto str = sk::format("");
-
9  ASSERT(str.empty());
-
10 
-
11  str = sk::format("%1", "");
-
12  ASSERT(str.empty());
-
13 
-
14  str = sk::format("%1%2%3", "", "", "");
-
15  ASSERT(str.empty());
-
16 }
-
17 
-
18 TEST("[Format] No args")
-
19 {
-
20  auto str = sk::format("Hello");
-
21  ASSERT(str == "Hello");
-
22 }
-
23 
-
24 TEST("[Format] Basic")
-
25 {
-
26  using namespace std::string_literals;
-
27 
-
28  auto str = sk::format("%1%2%3 %2 %1", 1, 2, 3);
-
29  ASSERT(str == "123 2 1");
-
30 
-
31  str = sk::format("%1 + %2 == %3", "2"s, "3", "5"s);
-
32  ASSERT(str == "2 + 3 == 5");
-
33 }
-
34 
-
35 class Dummy
-
36 {
-
37 private:
-
38  int m_num{ 0 };
-
39 
-
40 public:
-
41  Dummy() noexcept = default;
-
42  Dummy(Dummy const&) noexcept = default;
-
43  Dummy(Dummy&&) noexcept = default;
-
44  ~Dummy() noexcept = default;
-
45 
-
46  explicit Dummy(int const num)
-
47  : m_num{ num }
-
48  {
-
49  }
-
50 
-
51  auto operator=(Dummy const&) noexcept -> Dummy& = default;
-
52  auto operator=(Dummy&&) noexcept -> Dummy& = default;
-
53 
-
54  friend auto operator<<(std::ostream& os, Dummy const& d) -> std::ostream&
-
55  {
-
56  os << '(' << d.m_num << ')';
-
57  return os;
-
58  }
-
59 };
-
60 
-
61 TEST("[Format] Custom type")
-
62 {
-
63  auto str = sk::format("%1", Dummy{ 42 });
-
64  ASSERT(str == "(42)");
-
65 }
-
66 
-
67 TEST("[Format] Different threads")
-
68 {
-
69  std::string s1{};
-
70  std::string s2{};
-
71 
-
72  auto t1 = std::thread([&s1] { s1 = sk::format("%1", "Hello"); });
-
73  auto t2 = std::thread([&s2] { s2 = sk::format("%1", "World"); });
-
74 
-
75  t1.join();
-
76  t2.join();
-
77 
-
78  ASSERT(s1 == "Hello");
-
79  ASSERT(s2 == "World");
-
80 }
-
- - - - - diff --git a/docs/functions.html b/docs/functions.html deleted file mode 100644 index a34cc63..0000000 --- a/docs/functions.html +++ /dev/null @@ -1,82 +0,0 @@ - - - - - - - -Skribble: Class Members - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - -
- -
-
- - -
- -
- -
-
Here is a list of all documented class members with links to the class documentation for each member:
-
- - - - diff --git a/docs/functions_func.html b/docs/functions_func.html deleted file mode 100644 index e345c31..0000000 --- a/docs/functions_func.html +++ /dev/null @@ -1,82 +0,0 @@ - - - - - - - -Skribble: Class Members - Functions - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - -
- -
-
- - -
- -
- - - - - - diff --git a/docs/graph_legend.html b/docs/graph_legend.html deleted file mode 100644 index b6fa004..0000000 --- a/docs/graph_legend.html +++ /dev/null @@ -1,137 +0,0 @@ - - - - - - - -Skribble: Graph Legend - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - -
- -
-
- - -
- -
- -
-
-
Graph Legend
-
-
-

This page explains how to interpret the graphs that are generated by doxygen.

-

Consider the following example:

/*! Invisible class because of truncation */
-
class Invisible { };
-
-
/*! Truncated class, inheritance relation is hidden */
-
class Truncated : public Invisible { };
-
-
/* Class not documented with doxygen comments */
-
class Undocumented { };
-
-
/*! Class that is inherited using public inheritance */
-
class PublicBase : public Truncated { };
-
-
/*! A template class */
-
template<class T> class Templ { };
-
-
/*! Class that is inherited using protected inheritance */
-
class ProtectedBase { };
-
-
/*! Class that is inherited using private inheritance */
-
class PrivateBase { };
-
-
/*! Class that is used by the Inherited class */
-
class Used { };
-
-
/*! Super class that inherits a number of other classes */
-
class Inherited : public PublicBase,
-
protected ProtectedBase,
-
private PrivateBase,
-
public Undocumented,
-
public Templ<int>
-
{
-
private:
-
Used *m_usedClass;
-
};
-

This will result in the following graph:

-

The boxes in the above graph have the following meaning:

-
    -
  • -A filled gray box represents the struct or class for which the graph is generated.
  • -
  • -A box with a black border denotes a documented struct or class.
  • -
  • -A box with a gray border denotes an undocumented struct or class.
  • -
  • -A box with a red border denotes a documented struct or class forwhich not all inheritance/containment relations are shown. A graph is truncated if it does not fit within the specified boundaries.
  • -
-

The arrows have the following meaning:

-
    -
  • -A dark blue arrow is used to visualize a public inheritance relation between two classes.
  • -
  • -A dark green arrow is used for protected inheritance.
  • -
  • -A dark red arrow is used for private inheritance.
  • -
  • -A purple dashed arrow is used if a class is contained or used by another class. The arrow is labelled with the variable(s) through which the pointed class or struct is accessible.
  • -
  • -A yellow dashed arrow denotes a relation between a template instance and the template class it was instantiated from. The arrow is labelled with the template parameters of the instance.
  • -
-
- - - - diff --git a/docs/graph_legend.md5 b/docs/graph_legend.md5 deleted file mode 100644 index 8fcdccd..0000000 --- a/docs/graph_legend.md5 +++ /dev/null @@ -1 +0,0 @@ -f51bf6e9a10430aafef59831b08dcbfe \ No newline at end of file diff --git a/docs/graph_legend.png b/docs/graph_legend.png deleted file mode 100644 index 50164db..0000000 Binary files a/docs/graph_legend.png and /dev/null differ diff --git a/docs/hierarchy.html b/docs/hierarchy.html deleted file mode 100644 index 9a443c8..0000000 --- a/docs/hierarchy.html +++ /dev/null @@ -1,112 +0,0 @@ - - - - - - - -Skribble: Class Hierarchy - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - -
- -
-
- - -
- -
- -
-
-
Class Hierarchy
-
- - - - - diff --git a/docs/index.html b/docs/index.html index 48ccc02..090b534 100644 --- a/docs/index.html +++ b/docs/index.html @@ -1,77 +1,108 @@ - - + + - - - - -Skribble: Main Page - - - - - - - + + Skribble - Collaborative app made with Qt + + + + + -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
+
+
+
+
+
+

+ Skribble +

+

What is it?

Skribble tries to be a collaborative app made with Qt. At most two users can draw on the same canvas. It was made as part of an assignment at our University.

Download

There is a binary release available for Windows here.

Usage

Starting ./Skribble gives you the single user mode of the app, a normal painting app as you expect.

Starting ./Skribble -s starts the app and the server, which clients can connect to with ./Skribble -c <ip> where ip is, in theory, one's public IP. In practice, there is no way to connect over the network if the IP is dynamic or for other reasons we don't know. For sure is, to test the app in collaborative mode you can do ./Skribble -s from one terminal and ./Skribble -c 127.0.0.1 from another terminal which connects to the local host, thus emulating a two user scenario.

Build

The straightforward way:

mkdir build && cd build
+cmake -DCMAKE_PREFIX_PATH=/path/to/Qt/5.x.x/lib/cmake \
+      -DCMAKE_BUILD_TYPE=Release \
+      ..
+cmake --build .

For development:

# Other than above parameters
+cmake -DENABLE_SANITIZER_ADDRESS=ON \
+      -DENABLE_SANITIZER_UNDEFINED=ON \
+      -DBUILD_TESTS=ON \
+      ..

Obviously Qt5 needs to be installed.

To run the tests go in the build folder and run: ctest -V

+
+
+
+
+ - - - - - - - -
- -
-
- - -
- -
- -
-
-
Skribble Documentation
-
-
-
- - + + +
diff --git a/docs/index.xml b/docs/index.xml new file mode 100644 index 0000000..c55dc00 --- /dev/null +++ b/docs/index.xml @@ -0,0 +1,456 @@ + + + sk::AbstractNetwork + AbstractNetwork + AbstractNetwork + AbstractNetwork + ~AbstractNetwork + operator= + operator= + getSocket + sendDrawAt + sendMouseReleased + sendUndo + sendRedo + sendChangeColor + sendChangeWidth + sendToPen + sendToBrush + receivedMessage + + sk::BrushMode + m_brush + BrushMode + BrushMode + BrushMode + ~BrushMode + BrushMode + BrushMode + operator= + operator= + draw + + sk::impl::CachedLayers + m_foreign + m_layers + m_transparent + m_canvasRect + PixmapDrawer + PixmapInit + CachedLayers + CachedLayers + CachedLayers + ~CachedLayers + operator= + operator= + pushNewLayer + paintBlock + getLastLayer + getLastLayer + foreign + underUndo + undo + redo + getCanvasRect + + sk::CachedResource + ContainerType + Iterator + Function + m_cacheGap + m_maxCount + m_data + m_cache + m_dataLimit + m_cacheLimit + m_underUndo + m_function + plus + getNumCaches + noCaches + getIteratorPastCache + clearUndo + CachedResource + CachedResource + CachedResource + CachedResource + ~CachedResource + operator= + operator= + emplaceBack + getLastCache + reduceTo + reduceTo + getLast + getLast + underUndo + undo + redo + getUnderlying + getUnderlying + + sk::Canvas + m_history + m_drawMode + m_network + m_foreignColor + m_foreignWidth + Canvas + Canvas + Canvas + ~Canvas + operator= + operator= + paint + mousePositionChanged + mouseReleased + undo + redo + onReceivedMessage + changeColor + changeWidth + + sk::Client + m_server + Client + Client + Client + ~Client + operator= + operator= + getSocket + + sk::DrawHistory + m_layers + m_cache + m_lastPoint + m_lastExternalPoint + m_drawingLocally + m_drawingExternally + CachedDrawer + handleExternal + handleLocal + popFirst + DrawHistory + DrawHistory + DrawHistory + ~DrawHistory + operator= + operator= + pushNewLayer + paintCanvas + drawAt + undo + redo + + sk::DrawMode + m_defaultWidth + m_defaultColor + m_width + m_color + DrawMode + DrawMode + DrawMode + ~DrawMode + operator= + operator= + draw + getWidth + setWidth + getColor + setColor + getDefaultColor + getDefaultWidth + + Dummy + m_num + Dummy + Dummy + Dummy + ~Dummy + Dummy + operator= + operator= + operator<< + + sk::DummyNetwork + DummyNetwork + DummyNetwork + DummyNetwork + ~DummyNetwork + operator= + operator= + getSocket + + sk::FCachedResource + ContainerType + Iterator + Function + InitFunction + m_maxCount + m_data + m_iterator + m_function + m_initFunction + m_underUndo + FCachedResource + FCachedResource + FCachedResource + ~FCachedResource + FCachedResource + operator= + operator= + emplaceBack + underUndo + get + get + undo + redo + getUnderlying + getUnderlying + + sk::FResTraits + ContainerType + maxCount + + FTrait2 + ContainerType + maxCount + + FTraits + ContainerType + ContainerType + cacheGap + maxCount + + FTraits3 + ContainerType + maxCount + + sk::NetworkFactory + create + + sk::PenMode + m_pen + PenMode + PenMode + PenMode + ~PenMode + PenMode + PenMode + operator= + operator= + draw + + TestBase::Proxy + str + Proxy + Proxy + Proxy + ~Proxy + operator= + operator= + operator+ + operator== + operator!= + + sk::ResourceTraits + ContainerType + cacheGap + maxCount + + sk::Server + m_server + m_socket + Server + Server + Server + ~Server + operator= + operator= + getSocket + + TestBase + m_output + m_name + m_file + m_line + m_testId + TestBase + TestBase + TestBase + ~TestBase + TestBase + operator= + operator= + run + + Trait2 + ContainerType + cacheGap + maxCount + + sk::DrawHistory::Traits + ContainerType + cacheGap + maxCount + + Traits3 + ContainerType + maxCount + cacheGap + + anonymous_namespace{cached_resource_test.cpp} + adder + + anonymous_namespace{fcached_resource_test.cpp} + adder + init + + sk + Operation + UNDO + REDO + DRAW_AT + MOUSE_RELEASED + CHANGE_COLOR + CHANGE_WIDTH + TO_BRUSH + TO_PEN + NONE + NetworkModes + SINGLE_USER + CLIENT + SERVER + port + host_ip + networkMode + makeDrawMode + makeDrawMode + makeDrawMode + makeDrawMode + format + printTo + printlnTo + print + println + parse + + sk::anonymous_namespace{abstract_network.cpp} + handleWrite + + sk::anonymous_namespace{message_parser.cpp} + split + + sk::config + width + height + + sk::impl + + abstract_network.cpp + + abstract_network.hpp + + cached_resource.hpp + + canvas.cpp + + canvas.hpp + + canvas_config.hpp + + client.cpp + + client.hpp + + CMakeLists.txt + qt5_add_resources + + CMakeLists.txt + add_executable + + draw_history.cpp + + draw_history.hpp + + draw_mode.cpp + + draw_mode.hpp + + dummy_network.cpp + + dummy_network.hpp + + fixed_cached_resource.hpp + + format.hpp + + main.cpp + main + + message_parser.cpp + + message_parser.hpp + + network_config.hpp + + network_factory.cpp + + network_factory.hpp + + server.cpp + + server.hpp + + cached_resource_test.cpp + MAIN_EXECUTABLE + TEST + TEST + TEST + + fcached_resource_test.cpp + add + TEST + TEST + TEST + + format_test.cpp + TEST + TEST + TEST + TEST + TEST + + test.hpp + PASTE_2 + PASTE_1 + PASTE + RAND + RAND2 + ASSERT + TEST + getTestId + getTests + + message_parser_test.cpp + operator<< + TEST + TEST + TEST + TEST + TEST + TEST + TEST + TEST + TEST + + tests/helper + + src + + tests + + index + + diff --git a/docs/index.xsd b/docs/index.xsd new file mode 100644 index 0000000..04cb2f1 --- /dev/null +++ b/docs/index.xsd @@ -0,0 +1,67 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/docs/indexpage.xml b/docs/indexpage.xml new file mode 100644 index 0000000..8ccccc3 --- /dev/null +++ b/docs/indexpage.xml @@ -0,0 +1,42 @@ + + + + index + Skribble + + + + +What is it? +Skribble tries to be a collaborative app made with Qt. At most two users can draw on the same canvas. It was made as part of an assignment at our University. + + +Download +There is a binary release available for Windows here. + + +Usage +Starting ./Skribble gives you the single user mode of the app, a normal painting app as you expect. +Starting ./Skribble -s starts the app and the server, which clients can connect to with ./Skribble -c <ip> where ip is, in theory, one's public IP. In practice, there is no way to connect over the network if the IP is dynamic or for other reasons we don't know. For sure is, to test the app in collaborative mode you can do ./Skribble -s from one terminal and ./Skribble -c 127.0.0.1 from another terminal which connects to the local host, thus emulating a two user scenario. + + +Build +The straightforward way: mkdirbuild&&cdbuild +cmake-DCMAKE_PREFIX_PATH=/path/to/Qt/5.x.x/lib/cmake\ +-DCMAKE_BUILD_TYPE=Release\ +.. +cmake--build. + +For development: #Otherthanaboveparameters +cmake-DENABLE_SANITIZER_ADDRESS=ON\ +-DENABLE_SANITIZER_UNDEFINED=ON\ +-DBUILD_TESTS=ON\ +.. + +Obviously Qt5 needs to be installed. +To run the tests go in the build folder and run: ctest-V + + + + + diff --git a/docs/inherit_graph_0.map b/docs/inherit_graph_0.map deleted file mode 100644 index 6132c28..0000000 --- a/docs/inherit_graph_0.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_0.md5 b/docs/inherit_graph_0.md5 deleted file mode 100644 index a47315e..0000000 --- a/docs/inherit_graph_0.md5 +++ /dev/null @@ -1 +0,0 @@ -fc157c8234ae74649f72977cdb64e869 \ No newline at end of file diff --git a/docs/inherit_graph_0.png b/docs/inherit_graph_0.png deleted file mode 100644 index c3d762e..0000000 Binary files a/docs/inherit_graph_0.png and /dev/null differ diff --git a/docs/inherit_graph_1.map b/docs/inherit_graph_1.map deleted file mode 100644 index 5e50eff..0000000 --- a/docs/inherit_graph_1.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_1.md5 b/docs/inherit_graph_1.md5 deleted file mode 100644 index 717bec9..0000000 --- a/docs/inherit_graph_1.md5 +++ /dev/null @@ -1 +0,0 @@ -d57703f284c429e20b526efb6a69038d \ No newline at end of file diff --git a/docs/inherit_graph_1.png b/docs/inherit_graph_1.png deleted file mode 100644 index 889b9e0..0000000 Binary files a/docs/inherit_graph_1.png and /dev/null differ diff --git a/docs/inherit_graph_10.map b/docs/inherit_graph_10.map deleted file mode 100644 index 2d34277..0000000 --- a/docs/inherit_graph_10.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_10.md5 b/docs/inherit_graph_10.md5 deleted file mode 100644 index 20f17f9..0000000 --- a/docs/inherit_graph_10.md5 +++ /dev/null @@ -1 +0,0 @@ -f9db9611844c6c2804009aedf5bafe15 \ No newline at end of file diff --git a/docs/inherit_graph_10.png b/docs/inherit_graph_10.png deleted file mode 100644 index e821a9a..0000000 Binary files a/docs/inherit_graph_10.png and /dev/null differ diff --git a/docs/inherit_graph_11.map b/docs/inherit_graph_11.map deleted file mode 100644 index 2d34277..0000000 --- a/docs/inherit_graph_11.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_11.md5 b/docs/inherit_graph_11.md5 deleted file mode 100644 index 44ac97c..0000000 --- a/docs/inherit_graph_11.md5 +++ /dev/null @@ -1 +0,0 @@ -e747395efaf98fc771c0dc24fd818831 \ No newline at end of file diff --git a/docs/inherit_graph_11.png b/docs/inherit_graph_11.png deleted file mode 100644 index eb48ae3..0000000 Binary files a/docs/inherit_graph_11.png and /dev/null differ diff --git a/docs/inherit_graph_12.map b/docs/inherit_graph_12.map deleted file mode 100644 index af3695c..0000000 --- a/docs/inherit_graph_12.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_12.md5 b/docs/inherit_graph_12.md5 deleted file mode 100644 index abb9244..0000000 --- a/docs/inherit_graph_12.md5 +++ /dev/null @@ -1 +0,0 @@ -896e1330d14810469fa14fee9218cffa \ No newline at end of file diff --git a/docs/inherit_graph_12.png b/docs/inherit_graph_12.png deleted file mode 100644 index c96cef8..0000000 Binary files a/docs/inherit_graph_12.png and /dev/null differ diff --git a/docs/inherit_graph_13.map b/docs/inherit_graph_13.map deleted file mode 100644 index 2ed7580..0000000 --- a/docs/inherit_graph_13.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_13.md5 b/docs/inherit_graph_13.md5 deleted file mode 100644 index 220ab48..0000000 --- a/docs/inherit_graph_13.md5 +++ /dev/null @@ -1 +0,0 @@ -befca31a02a4117700cc02add5192a22 \ No newline at end of file diff --git a/docs/inherit_graph_13.png b/docs/inherit_graph_13.png deleted file mode 100644 index e3c17d1..0000000 Binary files a/docs/inherit_graph_13.png and /dev/null differ diff --git a/docs/inherit_graph_14.map b/docs/inherit_graph_14.map deleted file mode 100644 index cbf65a0..0000000 --- a/docs/inherit_graph_14.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_14.md5 b/docs/inherit_graph_14.md5 deleted file mode 100644 index e4b7b61..0000000 --- a/docs/inherit_graph_14.md5 +++ /dev/null @@ -1 +0,0 @@ -3562491130e01f4a9db7893bf6c6b064 \ No newline at end of file diff --git a/docs/inherit_graph_14.png b/docs/inherit_graph_14.png deleted file mode 100644 index 273bca0..0000000 Binary files a/docs/inherit_graph_14.png and /dev/null differ diff --git a/docs/inherit_graph_15.map b/docs/inherit_graph_15.map deleted file mode 100644 index 01c6042..0000000 --- a/docs/inherit_graph_15.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_15.md5 b/docs/inherit_graph_15.md5 deleted file mode 100644 index 8d87993..0000000 --- a/docs/inherit_graph_15.md5 +++ /dev/null @@ -1 +0,0 @@ -fab5dc1767db8e591c8f274188c37d01 \ No newline at end of file diff --git a/docs/inherit_graph_15.png b/docs/inherit_graph_15.png deleted file mode 100644 index d0df454..0000000 Binary files a/docs/inherit_graph_15.png and /dev/null differ diff --git a/docs/inherit_graph_16.map b/docs/inherit_graph_16.map deleted file mode 100644 index 906417e..0000000 --- a/docs/inherit_graph_16.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_16.md5 b/docs/inherit_graph_16.md5 deleted file mode 100644 index 4ce70fe..0000000 --- a/docs/inherit_graph_16.md5 +++ /dev/null @@ -1 +0,0 @@ -d0c1e0a40fb42346fe0f6b7b47dfb07b \ No newline at end of file diff --git a/docs/inherit_graph_16.png b/docs/inherit_graph_16.png deleted file mode 100644 index 102aa25..0000000 Binary files a/docs/inherit_graph_16.png and /dev/null differ diff --git a/docs/inherit_graph_17.map b/docs/inherit_graph_17.map deleted file mode 100644 index 9f3dbf6..0000000 --- a/docs/inherit_graph_17.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_17.md5 b/docs/inherit_graph_17.md5 deleted file mode 100644 index 1ddc4d7..0000000 --- a/docs/inherit_graph_17.md5 +++ /dev/null @@ -1 +0,0 @@ -5bbab1d93ed0e69780a25fa5265a9c6f \ No newline at end of file diff --git a/docs/inherit_graph_17.png b/docs/inherit_graph_17.png deleted file mode 100644 index cc77e2b..0000000 Binary files a/docs/inherit_graph_17.png and /dev/null differ diff --git a/docs/inherit_graph_18.map b/docs/inherit_graph_18.map deleted file mode 100644 index df2616f..0000000 --- a/docs/inherit_graph_18.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_18.md5 b/docs/inherit_graph_18.md5 deleted file mode 100644 index 0b71bfb..0000000 --- a/docs/inherit_graph_18.md5 +++ /dev/null @@ -1 +0,0 @@ -39bae2b66bcf02d6ed31993f54621ec8 \ No newline at end of file diff --git a/docs/inherit_graph_18.png b/docs/inherit_graph_18.png deleted file mode 100644 index acce124..0000000 Binary files a/docs/inherit_graph_18.png and /dev/null differ diff --git a/docs/inherit_graph_19.map b/docs/inherit_graph_19.map deleted file mode 100644 index 72d959e..0000000 --- a/docs/inherit_graph_19.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_19.md5 b/docs/inherit_graph_19.md5 deleted file mode 100644 index 8e43c65..0000000 --- a/docs/inherit_graph_19.md5 +++ /dev/null @@ -1 +0,0 @@ -1d8d7058b865c223183360ad7e2e2c76 \ No newline at end of file diff --git a/docs/inherit_graph_19.png b/docs/inherit_graph_19.png deleted file mode 100644 index 9e85c7a..0000000 Binary files a/docs/inherit_graph_19.png and /dev/null differ diff --git a/docs/inherit_graph_2.map b/docs/inherit_graph_2.map deleted file mode 100644 index f4e4950..0000000 --- a/docs/inherit_graph_2.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_2.md5 b/docs/inherit_graph_2.md5 deleted file mode 100644 index 20b2209..0000000 --- a/docs/inherit_graph_2.md5 +++ /dev/null @@ -1 +0,0 @@ -fd43ff197d74d8374b115e3b712d77b1 \ No newline at end of file diff --git a/docs/inherit_graph_2.png b/docs/inherit_graph_2.png deleted file mode 100644 index da4c409..0000000 Binary files a/docs/inherit_graph_2.png and /dev/null differ diff --git a/docs/inherit_graph_20.map b/docs/inherit_graph_20.map deleted file mode 100644 index c25400f..0000000 --- a/docs/inherit_graph_20.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_20.md5 b/docs/inherit_graph_20.md5 deleted file mode 100644 index 8822df5..0000000 --- a/docs/inherit_graph_20.md5 +++ /dev/null @@ -1 +0,0 @@ -f42ebb28bcb9469a851613af3a157443 \ No newline at end of file diff --git a/docs/inherit_graph_20.png b/docs/inherit_graph_20.png deleted file mode 100644 index 4230c85..0000000 Binary files a/docs/inherit_graph_20.png and /dev/null differ diff --git a/docs/inherit_graph_21.map b/docs/inherit_graph_21.map deleted file mode 100644 index 725464c..0000000 --- a/docs/inherit_graph_21.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_21.md5 b/docs/inherit_graph_21.md5 deleted file mode 100644 index 33f6230..0000000 --- a/docs/inherit_graph_21.md5 +++ /dev/null @@ -1 +0,0 @@ -adcd8d1ca8d737d9f7ce91bc290048bc \ No newline at end of file diff --git a/docs/inherit_graph_21.png b/docs/inherit_graph_21.png deleted file mode 100644 index 7d5f016..0000000 Binary files a/docs/inherit_graph_21.png and /dev/null differ diff --git a/docs/inherit_graph_3.map b/docs/inherit_graph_3.map deleted file mode 100644 index aa3b380..0000000 --- a/docs/inherit_graph_3.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_3.md5 b/docs/inherit_graph_3.md5 deleted file mode 100644 index 09701a8..0000000 --- a/docs/inherit_graph_3.md5 +++ /dev/null @@ -1 +0,0 @@ -8a7c808d62e2071edc3e201e6bdc79c1 \ No newline at end of file diff --git a/docs/inherit_graph_3.png b/docs/inherit_graph_3.png deleted file mode 100644 index ca90151..0000000 Binary files a/docs/inherit_graph_3.png and /dev/null differ diff --git a/docs/inherit_graph_4.map b/docs/inherit_graph_4.map deleted file mode 100644 index 62612ea..0000000 --- a/docs/inherit_graph_4.map +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/docs/inherit_graph_4.md5 b/docs/inherit_graph_4.md5 deleted file mode 100644 index 72f84b7..0000000 --- a/docs/inherit_graph_4.md5 +++ /dev/null @@ -1 +0,0 @@ -9b50b95da903ed2e70500682f0da4e54 \ No newline at end of file diff --git a/docs/inherit_graph_4.png b/docs/inherit_graph_4.png deleted file mode 100644 index 22dcc89..0000000 Binary files a/docs/inherit_graph_4.png and /dev/null differ diff --git a/docs/inherit_graph_5.map b/docs/inherit_graph_5.map deleted file mode 100644 index 777455b..0000000 --- a/docs/inherit_graph_5.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_5.md5 b/docs/inherit_graph_5.md5 deleted file mode 100644 index 09d729d..0000000 --- a/docs/inherit_graph_5.md5 +++ /dev/null @@ -1 +0,0 @@ -3ee0c12b5f59fc7a7666cd0203c8f154 \ No newline at end of file diff --git a/docs/inherit_graph_5.png b/docs/inherit_graph_5.png deleted file mode 100644 index 7fa1d14..0000000 Binary files a/docs/inherit_graph_5.png and /dev/null differ diff --git a/docs/inherit_graph_6.map b/docs/inherit_graph_6.map deleted file mode 100644 index fa2b734..0000000 --- a/docs/inherit_graph_6.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_6.md5 b/docs/inherit_graph_6.md5 deleted file mode 100644 index 015bfa7..0000000 --- a/docs/inherit_graph_6.md5 +++ /dev/null @@ -1 +0,0 @@ -b68d109cc9b0532fb26d13efde867e24 \ No newline at end of file diff --git a/docs/inherit_graph_6.png b/docs/inherit_graph_6.png deleted file mode 100644 index 8ea218a..0000000 Binary files a/docs/inherit_graph_6.png and /dev/null differ diff --git a/docs/inherit_graph_7.map b/docs/inherit_graph_7.map deleted file mode 100644 index 41774af..0000000 --- a/docs/inherit_graph_7.map +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/docs/inherit_graph_7.md5 b/docs/inherit_graph_7.md5 deleted file mode 100644 index 1372d0c..0000000 --- a/docs/inherit_graph_7.md5 +++ /dev/null @@ -1 +0,0 @@ -42a6f895b14965ff86ac4ccc17e0fde2 \ No newline at end of file diff --git a/docs/inherit_graph_7.png b/docs/inherit_graph_7.png deleted file mode 100644 index d560481..0000000 Binary files a/docs/inherit_graph_7.png and /dev/null differ diff --git a/docs/inherit_graph_8.map b/docs/inherit_graph_8.map deleted file mode 100644 index cc56786..0000000 --- a/docs/inherit_graph_8.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/docs/inherit_graph_8.md5 b/docs/inherit_graph_8.md5 deleted file mode 100644 index 2dd396b..0000000 --- a/docs/inherit_graph_8.md5 +++ /dev/null @@ -1 +0,0 @@ -c0a19c3b43aac6fc37969189847988e9 \ No newline at end of file diff --git a/docs/inherit_graph_8.png b/docs/inherit_graph_8.png deleted file mode 100644 index f6d0c51..0000000 Binary files a/docs/inherit_graph_8.png and /dev/null differ diff --git a/docs/inherit_graph_9.map b/docs/inherit_graph_9.map deleted file mode 100644 index 4631686..0000000 --- a/docs/inherit_graph_9.map +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/docs/inherit_graph_9.md5 b/docs/inherit_graph_9.md5 deleted file mode 100644 index cdc1bf4..0000000 --- a/docs/inherit_graph_9.md5 +++ /dev/null @@ -1 +0,0 @@ -880a432ec860c55107d48dbb887667a4 \ No newline at end of file diff --git a/docs/inherit_graph_9.png b/docs/inherit_graph_9.png deleted file mode 100644 index 1af6c55..0000000 Binary files a/docs/inherit_graph_9.png and /dev/null differ diff --git a/docs/inherits.html b/docs/inherits.html deleted file mode 100644 index b0f17fd..0000000 --- a/docs/inherits.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - - - -Skribble: Class Hierarchy - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - -
- -
-
- - -
- -
- -
-
-
Class Hierarchy
-
-
- - - - - - - - - - - - - - - - - - - - - - - -
- - - -
- - - -
- - - -
- - - -
- - - - - - - -
- - - -
- - - -
- - - - -
- - - -
- - - - - -
- - - -
- - - -
- - - -
- - - -
- - - -
- - - -
- - - -
- - - -
- - - -
- - - -
- - - -
- - - -
-
- - - - diff --git a/docs/jquery.js b/docs/jquery.js deleted file mode 100644 index 103c32d..0000000 --- a/docs/jquery.js +++ /dev/null @@ -1,35 +0,0 @@ -/*! jQuery v3.4.1 | (c) JS Foundation and other contributors | jquery.org/license */ -!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],E=C.document,r=Object.getPrototypeOf,s=t.slice,g=t.concat,u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.4.1",k=function(e,t){return new k.fn.init(e,t)},p=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;function d(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp($),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+$),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),ne=function(e,t,n){var r="0x"+t-65536;return r!=r||n?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(m.childNodes),m.childNodes),t[m.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&((e?e.ownerDocument||e:m)!==C&&T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!A[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&U.test(t)){(s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=k),o=(l=h(t)).length;while(o--)l[o]="#"+s+" "+xe(l[o]);c=l.join(","),f=ee.test(t)&&ye(e.parentNode)||e}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){A(t,!0)}finally{s===k&&e.removeAttribute("id")}}}return g(t.replace(B,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[k]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:m;return r!==C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),m!==C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=k,!C.getElementsByName||!C.getElementsByName(k).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){a.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+k+"-]").length||v.push("~="),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+k+"+*").length||v.push(".#.+[+~]")}),ce(function(e){e.innerHTML="";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",$)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e===C||e.ownerDocument===m&&y(m,e)?-1:t===C||t.ownerDocument===m&&y(m,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e===C?-1:t===C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]===m?-1:s[r]===m?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if((e.ownerDocument||e)!==C&&T(e),d.matchesSelector&&E&&!A[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){A(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=p[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&p(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function j(e,n,r){return m(n)?k.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?k.grep(e,function(e){return e===n!==r}):"string"!=typeof n?k.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(k.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||q,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:L.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof k?t[0]:t,k.merge(this,k.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),D.test(r[1])&&k.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(k):k.makeArray(e,this)}).prototype=k.fn,q=k(E);var H=/^(?:parents|prev(?:Until|All))/,O={children:!0,contents:!0,next:!0,prev:!0};function P(e,t){while((e=e[t])&&1!==e.nodeType);return e}k.fn.extend({has:function(e){var t=k(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i,ge={option:[1,""],thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?k.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;nx",y.noCloneChecked=!!me.cloneNode(!0).lastChild.defaultValue;var Te=/^key/,Ce=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Ee=/^([^.]*)(?:\.(.+)|)/;function ke(){return!0}function Se(){return!1}function Ne(e,t){return e===function(){try{return E.activeElement}catch(e){}}()==("focus"===t)}function Ae(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)Ae(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Se;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return k().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=k.guid++)),e.each(function(){k.event.add(this,t,i,r,n)})}function De(e,i,o){o?(Q.set(e,i,!1),k.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=Q.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(k.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),Q.set(this,i,r),t=o(this,i),this[i](),r!==(n=Q.get(this,i))||t?Q.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(Q.set(this,i,{value:k.event.trigger(k.extend(r[0],k.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Q.get(e,i)&&k.event.add(e,i,ke)}k.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.get(t);if(v){n.handler&&(n=(o=n).handler,i=o.selector),i&&k.find.matchesSelector(ie,i),n.guid||(n.guid=k.guid++),(u=v.events)||(u=v.events={}),(a=v.handle)||(a=v.handle=function(e){return"undefined"!=typeof k&&k.event.triggered!==e.type?k.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||"").match(R)||[""]).length;while(l--)d=g=(s=Ee.exec(e[l])||[])[1],h=(s[2]||"").split(".").sort(),d&&(f=k.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=k.event.special[d]||{},c=k.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&k.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(d,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),k.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.hasData(e)&&Q.get(e);if(v&&(u=v.events)){l=(t=(t||"").match(R)||[""]).length;while(l--)if(d=g=(s=Ee.exec(t[l])||[])[1],h=(s[2]||"").split(".").sort(),d){f=k.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||k.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)k.event.remove(e,d+t[l],n,r,!0);k.isEmptyObject(u)&&Q.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=k.event.fix(e),u=new Array(arguments.length),l=(Q.get(this,"events")||{})[s.type]||[],c=k.event.special[s.type]||{};for(u[0]=s,t=1;t\x20\t\r\n\f]*)[^>]*)\/>/gi,qe=/\s*$/g;function Oe(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&k(e).children("tbody")[0]||e}function Pe(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function Re(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Me(e,t){var n,r,i,o,a,s,u,l;if(1===t.nodeType){if(Q.hasData(e)&&(o=Q.access(e),a=Q.set(t,o),l=o.events))for(i in delete a.handle,a.events={},l)for(n=0,r=l[i].length;n")},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=oe(e);if(!(y.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||k.isXMLDoc(e)))for(a=ve(c),r=0,i=(o=ve(e)).length;r").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Vt,Gt=[],Yt=/(=)\?(?=&|$)|\?\?/;k.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Gt.pop()||k.expando+"_"+kt++;return this[e]=!0,e}}),k.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Yt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Yt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Yt,"$1"+r):!1!==e.jsonp&&(e.url+=(St.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||k.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?k(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Gt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((Vt=E.implementation.createHTMLDocument("").body).innerHTML="
",2===Vt.childNodes.length),k.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=D.exec(e))?[t.createElement(i[1])]:(i=we([e],t,o),o&&o.length&&k(o).remove(),k.merge([],i.childNodes)));var r,i,o},k.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(k.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},k.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){k.fn[t]=function(e){return this.on(t,e)}}),k.expr.pseudos.animated=function(t){return k.grep(k.timers,function(e){return t===e.elem}).length},k.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=k.css(e,"position"),c=k(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=k.css(e,"top"),u=k.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,k.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},k.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){k.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===k.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===k.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=k(e).offset()).top+=k.css(e,"borderTopWidth",!0),i.left+=k.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-k.css(r,"marginTop",!0),left:t.left-i.left-k.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===k.css(e,"position"))e=e.offsetParent;return e||ie})}}),k.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;k.fn[t]=function(e){return _(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),k.each(["top","left"],function(e,n){k.cssHooks[n]=ze(y.pixelPosition,function(e,t){if(t)return t=_e(e,n),$e.test(t)?k(e).position()[n]+"px":t})}),k.each({Height:"height",Width:"width"},function(a,s){k.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){k.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return _(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?k.css(e,t,i):k.style(e,t,n,i)},s,n?e:void 0,n)}})}),k.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){k.fn[n]=function(e,t){return 0a;a++)for(i in o[a])n=o[a][i],o[a].hasOwnProperty(i)&&void 0!==n&&(e[i]=t.isPlainObject(n)?t.isPlainObject(e[i])?t.widget.extend({},e[i],n):t.widget.extend({},n):n);return e},t.widget.bridge=function(e,i){var n=i.prototype.widgetFullName||e;t.fn[e]=function(o){var a="string"==typeof o,r=s.call(arguments,1),h=this;return a?this.length||"instance"!==o?this.each(function(){var i,s=t.data(this,n);return"instance"===o?(h=s,!1):s?t.isFunction(s[o])&&"_"!==o.charAt(0)?(i=s[o].apply(s,r),i!==s&&void 0!==i?(h=i&&i.jquery?h.pushStack(i.get()):i,!1):void 0):t.error("no such method '"+o+"' for "+e+" widget instance"):t.error("cannot call methods on "+e+" prior to initialization; "+"attempted to call method '"+o+"'")}):h=void 0:(r.length&&(o=t.widget.extend.apply(null,[o].concat(r))),this.each(function(){var e=t.data(this,n);e?(e.option(o||{}),e._init&&e._init()):t.data(this,n,new i(o,this))})),h}},t.Widget=function(){},t.Widget._childConstructors=[],t.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"
",options:{classes:{},disabled:!1,create:null},_createWidget:function(e,s){s=t(s||this.defaultElement||this)[0],this.element=t(s),this.uuid=i++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=t(),this.hoverable=t(),this.focusable=t(),this.classesElementLookup={},s!==this&&(t.data(s,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===s&&this.destroy()}}),this.document=t(s.style?s.ownerDocument:s.document||s),this.window=t(this.document[0].defaultView||this.document[0].parentWindow)),this.options=t.widget.extend({},this.options,this._getCreateOptions(),e),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:t.noop,_create:t.noop,_init:t.noop,destroy:function(){var e=this;this._destroy(),t.each(this.classesElementLookup,function(t,i){e._removeClass(i,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:t.noop,widget:function(){return this.element},option:function(e,i){var s,n,o,a=e;if(0===arguments.length)return t.widget.extend({},this.options);if("string"==typeof e)if(a={},s=e.split("."),e=s.shift(),s.length){for(n=a[e]=t.widget.extend({},this.options[e]),o=0;s.length-1>o;o++)n[s[o]]=n[s[o]]||{},n=n[s[o]];if(e=s.pop(),1===arguments.length)return void 0===n[e]?null:n[e];n[e]=i}else{if(1===arguments.length)return void 0===this.options[e]?null:this.options[e];a[e]=i}return this._setOptions(a),this},_setOptions:function(t){var e;for(e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return"classes"===t&&this._setOptionClasses(e),this.options[t]=e,"disabled"===t&&this._setOptionDisabled(e),this},_setOptionClasses:function(e){var i,s,n;for(i in e)n=this.classesElementLookup[i],e[i]!==this.options.classes[i]&&n&&n.length&&(s=t(n.get()),this._removeClass(n,i),s.addClass(this._classes({element:s,keys:i,classes:e,add:!0})))},_setOptionDisabled:function(t){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!t),t&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(e){function i(i,o){var a,r;for(r=0;i.length>r;r++)a=n.classesElementLookup[i[r]]||t(),a=e.add?t(t.unique(a.get().concat(e.element.get()))):t(a.not(e.element).get()),n.classesElementLookup[i[r]]=a,s.push(i[r]),o&&e.classes[i[r]]&&s.push(e.classes[i[r]])}var s=[],n=this;return e=t.extend({element:this.element,classes:this.options.classes||{}},e),this._on(e.element,{remove:"_untrackClassesElement"}),e.keys&&i(e.keys.match(/\S+/g)||[],!0),e.extra&&i(e.extra.match(/\S+/g)||[]),s.join(" ")},_untrackClassesElement:function(e){var i=this;t.each(i.classesElementLookup,function(s,n){-1!==t.inArray(e.target,n)&&(i.classesElementLookup[s]=t(n.not(e.target).get()))})},_removeClass:function(t,e,i){return this._toggleClass(t,e,i,!1)},_addClass:function(t,e,i){return this._toggleClass(t,e,i,!0)},_toggleClass:function(t,e,i,s){s="boolean"==typeof s?s:i;var n="string"==typeof t||null===t,o={extra:n?e:i,keys:n?t:e,element:n?this.element:t,add:s};return o.element.toggleClass(this._classes(o),s),this},_on:function(e,i,s){var n,o=this;"boolean"!=typeof e&&(s=i,i=e,e=!1),s?(i=n=t(i),this.bindings=this.bindings.add(i)):(s=i,i=this.element,n=this.widget()),t.each(s,function(s,a){function r(){return e||o.options.disabled!==!0&&!t(this).hasClass("ui-state-disabled")?("string"==typeof a?o[a]:a).apply(o,arguments):void 0}"string"!=typeof a&&(r.guid=a.guid=a.guid||r.guid||t.guid++);var h=s.match(/^([\w:-]*)\s*(.*)$/),l=h[1]+o.eventNamespace,c=h[2];c?n.on(l,c,r):i.on(l,r)})},_off:function(e,i){i=(i||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,e.off(i).off(i),this.bindings=t(this.bindings.not(e).get()),this.focusable=t(this.focusable.not(e).get()),this.hoverable=t(this.hoverable.not(e).get())},_delay:function(t,e){function i(){return("string"==typeof t?s[t]:t).apply(s,arguments)}var s=this;return setTimeout(i,e||0)},_hoverable:function(e){this.hoverable=this.hoverable.add(e),this._on(e,{mouseenter:function(e){this._addClass(t(e.currentTarget),null,"ui-state-hover")},mouseleave:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-hover")}})},_focusable:function(e){this.focusable=this.focusable.add(e),this._on(e,{focusin:function(e){this._addClass(t(e.currentTarget),null,"ui-state-focus")},focusout:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-focus")}})},_trigger:function(e,i,s){var n,o,a=this.options[e];if(s=s||{},i=t.Event(i),i.type=(e===this.widgetEventPrefix?e:this.widgetEventPrefix+e).toLowerCase(),i.target=this.element[0],o=i.originalEvent)for(n in o)n in i||(i[n]=o[n]);return this.element.trigger(i,s),!(t.isFunction(a)&&a.apply(this.element[0],[i].concat(s))===!1||i.isDefaultPrevented())}},t.each({show:"fadeIn",hide:"fadeOut"},function(e,i){t.Widget.prototype["_"+e]=function(s,n,o){"string"==typeof n&&(n={effect:n});var a,r=n?n===!0||"number"==typeof n?i:n.effect||i:e;n=n||{},"number"==typeof n&&(n={duration:n}),a=!t.isEmptyObject(n),n.complete=o,n.delay&&s.delay(n.delay),a&&t.effects&&t.effects.effect[r]?s[e](n):r!==e&&s[r]?s[r](n.duration,n.easing,o):s.queue(function(i){t(this)[e](),o&&o.call(s[0]),i()})}}),t.widget,function(){function e(t,e,i){return[parseFloat(t[0])*(u.test(t[0])?e/100:1),parseFloat(t[1])*(u.test(t[1])?i/100:1)]}function i(e,i){return parseInt(t.css(e,i),10)||0}function s(e){var i=e[0];return 9===i.nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:t.isWindow(i)?{width:e.width(),height:e.height(),offset:{top:e.scrollTop(),left:e.scrollLeft()}}:i.preventDefault?{width:0,height:0,offset:{top:i.pageY,left:i.pageX}}:{width:e.outerWidth(),height:e.outerHeight(),offset:e.offset()}}var n,o=Math.max,a=Math.abs,r=/left|center|right/,h=/top|center|bottom/,l=/[\+\-]\d+(\.[\d]+)?%?/,c=/^\w+/,u=/%$/,d=t.fn.position;t.position={scrollbarWidth:function(){if(void 0!==n)return n;var e,i,s=t("
"),o=s.children()[0];return t("body").append(s),e=o.offsetWidth,s.css("overflow","scroll"),i=o.offsetWidth,e===i&&(i=s[0].clientWidth),s.remove(),n=e-i},getScrollInfo:function(e){var i=e.isWindow||e.isDocument?"":e.element.css("overflow-x"),s=e.isWindow||e.isDocument?"":e.element.css("overflow-y"),n="scroll"===i||"auto"===i&&e.widthi?"left":e>0?"right":"center",vertical:0>r?"top":s>0?"bottom":"middle"};l>p&&p>a(e+i)&&(u.horizontal="center"),c>f&&f>a(s+r)&&(u.vertical="middle"),u.important=o(a(e),a(i))>o(a(s),a(r))?"horizontal":"vertical",n.using.call(this,t,u)}),h.offset(t.extend(D,{using:r}))})},t.ui.position={fit:{left:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollLeft:s.offset.left,a=s.width,r=t.left-e.collisionPosition.marginLeft,h=n-r,l=r+e.collisionWidth-a-n;e.collisionWidth>a?h>0&&0>=l?(i=t.left+h+e.collisionWidth-a-n,t.left+=h-i):t.left=l>0&&0>=h?n:h>l?n+a-e.collisionWidth:n:h>0?t.left+=h:l>0?t.left-=l:t.left=o(t.left-r,t.left)},top:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollTop:s.offset.top,a=e.within.height,r=t.top-e.collisionPosition.marginTop,h=n-r,l=r+e.collisionHeight-a-n;e.collisionHeight>a?h>0&&0>=l?(i=t.top+h+e.collisionHeight-a-n,t.top+=h-i):t.top=l>0&&0>=h?n:h>l?n+a-e.collisionHeight:n:h>0?t.top+=h:l>0?t.top-=l:t.top=o(t.top-r,t.top)}},flip:{left:function(t,e){var i,s,n=e.within,o=n.offset.left+n.scrollLeft,r=n.width,h=n.isWindow?n.scrollLeft:n.offset.left,l=t.left-e.collisionPosition.marginLeft,c=l-h,u=l+e.collisionWidth-r-h,d="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,p="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,f=-2*e.offset[0];0>c?(i=t.left+d+p+f+e.collisionWidth-r-o,(0>i||a(c)>i)&&(t.left+=d+p+f)):u>0&&(s=t.left-e.collisionPosition.marginLeft+d+p+f-h,(s>0||u>a(s))&&(t.left+=d+p+f))},top:function(t,e){var i,s,n=e.within,o=n.offset.top+n.scrollTop,r=n.height,h=n.isWindow?n.scrollTop:n.offset.top,l=t.top-e.collisionPosition.marginTop,c=l-h,u=l+e.collisionHeight-r-h,d="top"===e.my[1],p=d?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,f="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,m=-2*e.offset[1];0>c?(s=t.top+p+f+m+e.collisionHeight-r-o,(0>s||a(c)>s)&&(t.top+=p+f+m)):u>0&&(i=t.top-e.collisionPosition.marginTop+p+f+m-h,(i>0||u>a(i))&&(t.top+=p+f+m))}},flipfit:{left:function(){t.ui.position.flip.left.apply(this,arguments),t.ui.position.fit.left.apply(this,arguments)},top:function(){t.ui.position.flip.top.apply(this,arguments),t.ui.position.fit.top.apply(this,arguments)}}}}(),t.ui.position,t.extend(t.expr[":"],{data:t.expr.createPseudo?t.expr.createPseudo(function(e){return function(i){return!!t.data(i,e)}}):function(e,i,s){return!!t.data(e,s[3])}}),t.fn.extend({disableSelection:function(){var t="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(t+".ui-disableSelection",function(t){t.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}}),t.ui.focusable=function(i,s){var n,o,a,r,h,l=i.nodeName.toLowerCase();return"area"===l?(n=i.parentNode,o=n.name,i.href&&o&&"map"===n.nodeName.toLowerCase()?(a=t("img[usemap='#"+o+"']"),a.length>0&&a.is(":visible")):!1):(/^(input|select|textarea|button|object)$/.test(l)?(r=!i.disabled,r&&(h=t(i).closest("fieldset")[0],h&&(r=!h.disabled))):r="a"===l?i.href||s:s,r&&t(i).is(":visible")&&e(t(i)))},t.extend(t.expr[":"],{focusable:function(e){return t.ui.focusable(e,null!=t.attr(e,"tabindex"))}}),t.ui.focusable,t.fn.form=function(){return"string"==typeof this[0].form?this.closest("form"):t(this[0].form)},t.ui.formResetMixin={_formResetHandler:function(){var e=t(this);setTimeout(function(){var i=e.data("ui-form-reset-instances");t.each(i,function(){this.refresh()})})},_bindFormResetHandler:function(){if(this.form=this.element.form(),this.form.length){var t=this.form.data("ui-form-reset-instances")||[];t.length||this.form.on("reset.ui-form-reset",this._formResetHandler),t.push(this),this.form.data("ui-form-reset-instances",t)}},_unbindFormResetHandler:function(){if(this.form.length){var e=this.form.data("ui-form-reset-instances");e.splice(t.inArray(this,e),1),e.length?this.form.data("ui-form-reset-instances",e):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}},"1.7"===t.fn.jquery.substring(0,3)&&(t.each(["Width","Height"],function(e,i){function s(e,i,s,o){return t.each(n,function(){i-=parseFloat(t.css(e,"padding"+this))||0,s&&(i-=parseFloat(t.css(e,"border"+this+"Width"))||0),o&&(i-=parseFloat(t.css(e,"margin"+this))||0)}),i}var n="Width"===i?["Left","Right"]:["Top","Bottom"],o=i.toLowerCase(),a={innerWidth:t.fn.innerWidth,innerHeight:t.fn.innerHeight,outerWidth:t.fn.outerWidth,outerHeight:t.fn.outerHeight};t.fn["inner"+i]=function(e){return void 0===e?a["inner"+i].call(this):this.each(function(){t(this).css(o,s(this,e)+"px")})},t.fn["outer"+i]=function(e,n){return"number"!=typeof e?a["outer"+i].call(this,e):this.each(function(){t(this).css(o,s(this,e,!0,n)+"px")})}}),t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},t.ui.escapeSelector=function(){var t=/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g;return function(e){return e.replace(t,"\\$1")}}(),t.fn.labels=function(){var e,i,s,n,o;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(n=this.eq(0).parents("label"),s=this.attr("id"),s&&(e=this.eq(0).parents().last(),o=e.add(e.length?e.siblings():this.siblings()),i="label[for='"+t.ui.escapeSelector(s)+"']",n=n.add(o.find(i).addBack(i))),this.pushStack(n))},t.fn.scrollParent=function(e){var i=this.css("position"),s="absolute"===i,n=e?/(auto|scroll|hidden)/:/(auto|scroll)/,o=this.parents().filter(function(){var e=t(this);return s&&"static"===e.css("position")?!1:n.test(e.css("overflow")+e.css("overflow-y")+e.css("overflow-x"))}).eq(0);return"fixed"!==i&&o.length?o:t(this[0].ownerDocument||document)},t.extend(t.expr[":"],{tabbable:function(e){var i=t.attr(e,"tabindex"),s=null!=i;return(!s||i>=0)&&t.ui.focusable(e,s)}}),t.fn.extend({uniqueId:function(){var t=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++t)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&t(this).removeAttr("id")})}}),t.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase());var n=!1;t(document).on("mouseup",function(){n=!1}),t.widget("ui.mouse",{version:"1.12.1",options:{cancel:"input, textarea, button, select, option",distance:1,delay:0},_mouseInit:function(){var e=this;this.element.on("mousedown."+this.widgetName,function(t){return e._mouseDown(t)}).on("click."+this.widgetName,function(i){return!0===t.data(i.target,e.widgetName+".preventClickEvent")?(t.removeData(i.target,e.widgetName+".preventClickEvent"),i.stopImmediatePropagation(),!1):void 0}),this.started=!1},_mouseDestroy:function(){this.element.off("."+this.widgetName),this._mouseMoveDelegate&&this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(e){if(!n){this._mouseMoved=!1,this._mouseStarted&&this._mouseUp(e),this._mouseDownEvent=e;var i=this,s=1===e.which,o="string"==typeof this.options.cancel&&e.target.nodeName?t(e.target).closest(this.options.cancel).length:!1;return s&&!o&&this._mouseCapture(e)?(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){i.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(e)!==!1,!this._mouseStarted)?(e.preventDefault(),!0):(!0===t.data(e.target,this.widgetName+".preventClickEvent")&&t.removeData(e.target,this.widgetName+".preventClickEvent"),this._mouseMoveDelegate=function(t){return i._mouseMove(t)},this._mouseUpDelegate=function(t){return i._mouseUp(t)},this.document.on("mousemove."+this.widgetName,this._mouseMoveDelegate).on("mouseup."+this.widgetName,this._mouseUpDelegate),e.preventDefault(),n=!0,!0)):!0}},_mouseMove:function(e){if(this._mouseMoved){if(t.ui.ie&&(!document.documentMode||9>document.documentMode)&&!e.button)return this._mouseUp(e);if(!e.which)if(e.originalEvent.altKey||e.originalEvent.ctrlKey||e.originalEvent.metaKey||e.originalEvent.shiftKey)this.ignoreMissingWhich=!0;else if(!this.ignoreMissingWhich)return this._mouseUp(e)}return(e.which||e.button)&&(this._mouseMoved=!0),this._mouseStarted?(this._mouseDrag(e),e.preventDefault()):(this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(this._mouseDownEvent,e)!==!1,this._mouseStarted?this._mouseDrag(e):this._mouseUp(e)),!this._mouseStarted)},_mouseUp:function(e){this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,e.target===this._mouseDownEvent.target&&t.data(e.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(e)),this._mouseDelayTimer&&(clearTimeout(this._mouseDelayTimer),delete this._mouseDelayTimer),this.ignoreMissingWhich=!1,n=!1,e.preventDefault()},_mouseDistanceMet:function(t){return Math.max(Math.abs(this._mouseDownEvent.pageX-t.pageX),Math.abs(this._mouseDownEvent.pageY-t.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}}),t.ui.plugin={add:function(e,i,s){var n,o=t.ui[e].prototype;for(n in s)o.plugins[n]=o.plugins[n]||[],o.plugins[n].push([i,s[n]])},call:function(t,e,i,s){var n,o=t.plugins[e];if(o&&(s||t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType))for(n=0;o.length>n;n++)t.options[o[n][0]]&&o[n][1].apply(t.element,i)}},t.widget("ui.resizable",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"resize",options:{alsoResize:!1,animate:!1,animateDuration:"slow",animateEasing:"swing",aspectRatio:!1,autoHide:!1,classes:{"ui-resizable-se":"ui-icon ui-icon-gripsmall-diagonal-se"},containment:!1,ghost:!1,grid:!1,handles:"e,s,se",helper:!1,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:90,resize:null,start:null,stop:null},_num:function(t){return parseFloat(t)||0},_isNumber:function(t){return!isNaN(parseFloat(t))},_hasScroll:function(e,i){if("hidden"===t(e).css("overflow"))return!1;var s=i&&"left"===i?"scrollLeft":"scrollTop",n=!1;return e[s]>0?!0:(e[s]=1,n=e[s]>0,e[s]=0,n)},_create:function(){var e,i=this.options,s=this;this._addClass("ui-resizable"),t.extend(this,{_aspectRatio:!!i.aspectRatio,aspectRatio:i.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:i.helper||i.ghost||i.animate?i.helper||"ui-resizable-helper":null}),this.element[0].nodeName.match(/^(canvas|textarea|input|select|button|img)$/i)&&(this.element.wrap(t("
").css({position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")})),this.element=this.element.parent().data("ui-resizable",this.element.resizable("instance")),this.elementIsWrapper=!0,e={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")},this.element.css(e),this.originalElement.css("margin",0),this.originalResizeStyle=this.originalElement.css("resize"),this.originalElement.css("resize","none"),this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"})),this.originalElement.css(e),this._proportionallyResize()),this._setupHandles(),i.autoHide&&t(this.element).on("mouseenter",function(){i.disabled||(s._removeClass("ui-resizable-autohide"),s._handles.show())}).on("mouseleave",function(){i.disabled||s.resizing||(s._addClass("ui-resizable-autohide"),s._handles.hide())}),this._mouseInit()},_destroy:function(){this._mouseDestroy();var e,i=function(e){t(e).removeData("resizable").removeData("ui-resizable").off(".resizable").find(".ui-resizable-handle").remove()};return this.elementIsWrapper&&(i(this.element),e=this.element,this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")}).insertAfter(e),e.remove()),this.originalElement.css("resize",this.originalResizeStyle),i(this.originalElement),this},_setOption:function(t,e){switch(this._super(t,e),t){case"handles":this._removeHandles(),this._setupHandles();break;default:}},_setupHandles:function(){var e,i,s,n,o,a=this.options,r=this;if(this.handles=a.handles||(t(".ui-resizable-handle",this.element).length?{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}:"e,s,se"),this._handles=t(),this.handles.constructor===String)for("all"===this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw"),s=this.handles.split(","),this.handles={},i=0;s.length>i;i++)e=t.trim(s[i]),n="ui-resizable-"+e,o=t("
"),this._addClass(o,"ui-resizable-handle "+n),o.css({zIndex:a.zIndex}),this.handles[e]=".ui-resizable-"+e,this.element.append(o);this._renderAxis=function(e){var i,s,n,o;e=e||this.element;for(i in this.handles)this.handles[i].constructor===String?this.handles[i]=this.element.children(this.handles[i]).first().show():(this.handles[i].jquery||this.handles[i].nodeType)&&(this.handles[i]=t(this.handles[i]),this._on(this.handles[i],{mousedown:r._mouseDown})),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)&&(s=t(this.handles[i],this.element),o=/sw|ne|nw|se|n|s/.test(i)?s.outerHeight():s.outerWidth(),n=["padding",/ne|nw|n/.test(i)?"Top":/se|sw|s/.test(i)?"Bottom":/^e$/.test(i)?"Right":"Left"].join(""),e.css(n,o),this._proportionallyResize()),this._handles=this._handles.add(this.handles[i])},this._renderAxis(this.element),this._handles=this._handles.add(this.element.find(".ui-resizable-handle")),this._handles.disableSelection(),this._handles.on("mouseover",function(){r.resizing||(this.className&&(o=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),r.axis=o&&o[1]?o[1]:"se")}),a.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._handles.remove()},_mouseCapture:function(e){var i,s,n=!1;for(i in this.handles)s=t(this.handles[i])[0],(s===e.target||t.contains(s,e.target))&&(n=!0);return!this.options.disabled&&n},_mouseStart:function(e){var i,s,n,o=this.options,a=this.element;return this.resizing=!0,this._renderProxy(),i=this._num(this.helper.css("left")),s=this._num(this.helper.css("top")),o.containment&&(i+=t(o.containment).scrollLeft()||0,s+=t(o.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:i,top:s},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:a.width(),height:a.height()},this.originalSize=this._helper?{width:a.outerWidth(),height:a.outerHeight()}:{width:a.width(),height:a.height()},this.sizeDiff={width:a.outerWidth()-a.width(),height:a.outerHeight()-a.height()},this.originalPosition={left:i,top:s},this.originalMousePosition={left:e.pageX,top:e.pageY},this.aspectRatio="number"==typeof o.aspectRatio?o.aspectRatio:this.originalSize.width/this.originalSize.height||1,n=t(".ui-resizable-"+this.axis).css("cursor"),t("body").css("cursor","auto"===n?this.axis+"-resize":n),this._addClass("ui-resizable-resizing"),this._propagate("start",e),!0},_mouseDrag:function(e){var i,s,n=this.originalMousePosition,o=this.axis,a=e.pageX-n.left||0,r=e.pageY-n.top||0,h=this._change[o];return this._updatePrevProperties(),h?(i=h.apply(this,[e,a,r]),this._updateVirtualBoundaries(e.shiftKey),(this._aspectRatio||e.shiftKey)&&(i=this._updateRatio(i,e)),i=this._respectSize(i,e),this._updateCache(i),this._propagate("resize",e),s=this._applyChanges(),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),t.isEmptyObject(s)||(this._updatePrevProperties(),this._trigger("resize",e,this.ui()),this._applyChanges()),!1):!1},_mouseStop:function(e){this.resizing=!1;var i,s,n,o,a,r,h,l=this.options,c=this;return this._helper&&(i=this._proportionallyResizeElements,s=i.length&&/textarea/i.test(i[0].nodeName),n=s&&this._hasScroll(i[0],"left")?0:c.sizeDiff.height,o=s?0:c.sizeDiff.width,a={width:c.helper.width()-o,height:c.helper.height()-n},r=parseFloat(c.element.css("left"))+(c.position.left-c.originalPosition.left)||null,h=parseFloat(c.element.css("top"))+(c.position.top-c.originalPosition.top)||null,l.animate||this.element.css(t.extend(a,{top:h,left:r})),c.helper.height(c.size.height),c.helper.width(c.size.width),this._helper&&!l.animate&&this._proportionallyResize()),t("body").css("cursor","auto"),this._removeClass("ui-resizable-resizing"),this._propagate("stop",e),this._helper&&this.helper.remove(),!1},_updatePrevProperties:function(){this.prevPosition={top:this.position.top,left:this.position.left},this.prevSize={width:this.size.width,height:this.size.height}},_applyChanges:function(){var t={};return this.position.top!==this.prevPosition.top&&(t.top=this.position.top+"px"),this.position.left!==this.prevPosition.left&&(t.left=this.position.left+"px"),this.size.width!==this.prevSize.width&&(t.width=this.size.width+"px"),this.size.height!==this.prevSize.height&&(t.height=this.size.height+"px"),this.helper.css(t),t},_updateVirtualBoundaries:function(t){var e,i,s,n,o,a=this.options;o={minWidth:this._isNumber(a.minWidth)?a.minWidth:0,maxWidth:this._isNumber(a.maxWidth)?a.maxWidth:1/0,minHeight:this._isNumber(a.minHeight)?a.minHeight:0,maxHeight:this._isNumber(a.maxHeight)?a.maxHeight:1/0},(this._aspectRatio||t)&&(e=o.minHeight*this.aspectRatio,s=o.minWidth/this.aspectRatio,i=o.maxHeight*this.aspectRatio,n=o.maxWidth/this.aspectRatio,e>o.minWidth&&(o.minWidth=e),s>o.minHeight&&(o.minHeight=s),o.maxWidth>i&&(o.maxWidth=i),o.maxHeight>n&&(o.maxHeight=n)),this._vBoundaries=o},_updateCache:function(t){this.offset=this.helper.offset(),this._isNumber(t.left)&&(this.position.left=t.left),this._isNumber(t.top)&&(this.position.top=t.top),this._isNumber(t.height)&&(this.size.height=t.height),this._isNumber(t.width)&&(this.size.width=t.width)},_updateRatio:function(t){var e=this.position,i=this.size,s=this.axis;return this._isNumber(t.height)?t.width=t.height*this.aspectRatio:this._isNumber(t.width)&&(t.height=t.width/this.aspectRatio),"sw"===s&&(t.left=e.left+(i.width-t.width),t.top=null),"nw"===s&&(t.top=e.top+(i.height-t.height),t.left=e.left+(i.width-t.width)),t},_respectSize:function(t){var e=this._vBoundaries,i=this.axis,s=this._isNumber(t.width)&&e.maxWidth&&e.maxWidtht.width,a=this._isNumber(t.height)&&e.minHeight&&e.minHeight>t.height,r=this.originalPosition.left+this.originalSize.width,h=this.originalPosition.top+this.originalSize.height,l=/sw|nw|w/.test(i),c=/nw|ne|n/.test(i);return o&&(t.width=e.minWidth),a&&(t.height=e.minHeight),s&&(t.width=e.maxWidth),n&&(t.height=e.maxHeight),o&&l&&(t.left=r-e.minWidth),s&&l&&(t.left=r-e.maxWidth),a&&c&&(t.top=h-e.minHeight),n&&c&&(t.top=h-e.maxHeight),t.width||t.height||t.left||!t.top?t.width||t.height||t.top||!t.left||(t.left=null):t.top=null,t},_getPaddingPlusBorderDimensions:function(t){for(var e=0,i=[],s=[t.css("borderTopWidth"),t.css("borderRightWidth"),t.css("borderBottomWidth"),t.css("borderLeftWidth")],n=[t.css("paddingTop"),t.css("paddingRight"),t.css("paddingBottom"),t.css("paddingLeft")];4>e;e++)i[e]=parseFloat(s[e])||0,i[e]+=parseFloat(n[e])||0;return{height:i[0]+i[2],width:i[1]+i[3]}},_proportionallyResize:function(){if(this._proportionallyResizeElements.length)for(var t,e=0,i=this.helper||this.element;this._proportionallyResizeElements.length>e;e++)t=this._proportionallyResizeElements[e],this.outerDimensions||(this.outerDimensions=this._getPaddingPlusBorderDimensions(t)),t.css({height:i.height()-this.outerDimensions.height||0,width:i.width()-this.outerDimensions.width||0})},_renderProxy:function(){var e=this.element,i=this.options;this.elementOffset=e.offset(),this._helper?(this.helper=this.helper||t("
"),this._addClass(this.helper,this._helper),this.helper.css({width:this.element.outerWidth(),height:this.element.outerHeight(),position:"absolute",left:this.elementOffset.left+"px",top:this.elementOffset.top+"px",zIndex:++i.zIndex}),this.helper.appendTo("body").disableSelection()):this.helper=this.element -},_change:{e:function(t,e){return{width:this.originalSize.width+e}},w:function(t,e){var i=this.originalSize,s=this.originalPosition;return{left:s.left+e,width:i.width-e}},n:function(t,e,i){var s=this.originalSize,n=this.originalPosition;return{top:n.top+i,height:s.height-i}},s:function(t,e,i){return{height:this.originalSize.height+i}},se:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},sw:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[e,i,s]))},ne:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},nw:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[e,i,s]))}},_propagate:function(e,i){t.ui.plugin.call(this,e,[i,this.ui()]),"resize"!==e&&this._trigger(e,i,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),t.ui.plugin.add("resizable","animate",{stop:function(e){var i=t(this).resizable("instance"),s=i.options,n=i._proportionallyResizeElements,o=n.length&&/textarea/i.test(n[0].nodeName),a=o&&i._hasScroll(n[0],"left")?0:i.sizeDiff.height,r=o?0:i.sizeDiff.width,h={width:i.size.width-r,height:i.size.height-a},l=parseFloat(i.element.css("left"))+(i.position.left-i.originalPosition.left)||null,c=parseFloat(i.element.css("top"))+(i.position.top-i.originalPosition.top)||null;i.element.animate(t.extend(h,c&&l?{top:c,left:l}:{}),{duration:s.animateDuration,easing:s.animateEasing,step:function(){var s={width:parseFloat(i.element.css("width")),height:parseFloat(i.element.css("height")),top:parseFloat(i.element.css("top")),left:parseFloat(i.element.css("left"))};n&&n.length&&t(n[0]).css({width:s.width,height:s.height}),i._updateCache(s),i._propagate("resize",e)}})}}),t.ui.plugin.add("resizable","containment",{start:function(){var e,i,s,n,o,a,r,h=t(this).resizable("instance"),l=h.options,c=h.element,u=l.containment,d=u instanceof t?u.get(0):/parent/.test(u)?c.parent().get(0):u;d&&(h.containerElement=t(d),/document/.test(u)||u===document?(h.containerOffset={left:0,top:0},h.containerPosition={left:0,top:0},h.parentData={element:t(document),left:0,top:0,width:t(document).width(),height:t(document).height()||document.body.parentNode.scrollHeight}):(e=t(d),i=[],t(["Top","Right","Left","Bottom"]).each(function(t,s){i[t]=h._num(e.css("padding"+s))}),h.containerOffset=e.offset(),h.containerPosition=e.position(),h.containerSize={height:e.innerHeight()-i[3],width:e.innerWidth()-i[1]},s=h.containerOffset,n=h.containerSize.height,o=h.containerSize.width,a=h._hasScroll(d,"left")?d.scrollWidth:o,r=h._hasScroll(d)?d.scrollHeight:n,h.parentData={element:d,left:s.left,top:s.top,width:a,height:r}))},resize:function(e){var i,s,n,o,a=t(this).resizable("instance"),r=a.options,h=a.containerOffset,l=a.position,c=a._aspectRatio||e.shiftKey,u={top:0,left:0},d=a.containerElement,p=!0;d[0]!==document&&/static/.test(d.css("position"))&&(u=h),l.left<(a._helper?h.left:0)&&(a.size.width=a.size.width+(a._helper?a.position.left-h.left:a.position.left-u.left),c&&(a.size.height=a.size.width/a.aspectRatio,p=!1),a.position.left=r.helper?h.left:0),l.top<(a._helper?h.top:0)&&(a.size.height=a.size.height+(a._helper?a.position.top-h.top:a.position.top),c&&(a.size.width=a.size.height*a.aspectRatio,p=!1),a.position.top=a._helper?h.top:0),n=a.containerElement.get(0)===a.element.parent().get(0),o=/relative|absolute/.test(a.containerElement.css("position")),n&&o?(a.offset.left=a.parentData.left+a.position.left,a.offset.top=a.parentData.top+a.position.top):(a.offset.left=a.element.offset().left,a.offset.top=a.element.offset().top),i=Math.abs(a.sizeDiff.width+(a._helper?a.offset.left-u.left:a.offset.left-h.left)),s=Math.abs(a.sizeDiff.height+(a._helper?a.offset.top-u.top:a.offset.top-h.top)),i+a.size.width>=a.parentData.width&&(a.size.width=a.parentData.width-i,c&&(a.size.height=a.size.width/a.aspectRatio,p=!1)),s+a.size.height>=a.parentData.height&&(a.size.height=a.parentData.height-s,c&&(a.size.width=a.size.height*a.aspectRatio,p=!1)),p||(a.position.left=a.prevPosition.left,a.position.top=a.prevPosition.top,a.size.width=a.prevSize.width,a.size.height=a.prevSize.height)},stop:function(){var e=t(this).resizable("instance"),i=e.options,s=e.containerOffset,n=e.containerPosition,o=e.containerElement,a=t(e.helper),r=a.offset(),h=a.outerWidth()-e.sizeDiff.width,l=a.outerHeight()-e.sizeDiff.height;e._helper&&!i.animate&&/relative/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l}),e._helper&&!i.animate&&/static/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l})}}),t.ui.plugin.add("resizable","alsoResize",{start:function(){var e=t(this).resizable("instance"),i=e.options;t(i.alsoResize).each(function(){var e=t(this);e.data("ui-resizable-alsoresize",{width:parseFloat(e.width()),height:parseFloat(e.height()),left:parseFloat(e.css("left")),top:parseFloat(e.css("top"))})})},resize:function(e,i){var s=t(this).resizable("instance"),n=s.options,o=s.originalSize,a=s.originalPosition,r={height:s.size.height-o.height||0,width:s.size.width-o.width||0,top:s.position.top-a.top||0,left:s.position.left-a.left||0};t(n.alsoResize).each(function(){var e=t(this),s=t(this).data("ui-resizable-alsoresize"),n={},o=e.parents(i.originalElement[0]).length?["width","height"]:["width","height","top","left"];t.each(o,function(t,e){var i=(s[e]||0)+(r[e]||0);i&&i>=0&&(n[e]=i||null)}),e.css(n)})},stop:function(){t(this).removeData("ui-resizable-alsoresize")}}),t.ui.plugin.add("resizable","ghost",{start:function(){var e=t(this).resizable("instance"),i=e.size;e.ghost=e.originalElement.clone(),e.ghost.css({opacity:.25,display:"block",position:"relative",height:i.height,width:i.width,margin:0,left:0,top:0}),e._addClass(e.ghost,"ui-resizable-ghost"),t.uiBackCompat!==!1&&"string"==typeof e.options.ghost&&e.ghost.addClass(this.options.ghost),e.ghost.appendTo(e.helper)},resize:function(){var e=t(this).resizable("instance");e.ghost&&e.ghost.css({position:"relative",height:e.size.height,width:e.size.width})},stop:function(){var e=t(this).resizable("instance");e.ghost&&e.helper&&e.helper.get(0).removeChild(e.ghost.get(0))}}),t.ui.plugin.add("resizable","grid",{resize:function(){var e,i=t(this).resizable("instance"),s=i.options,n=i.size,o=i.originalSize,a=i.originalPosition,r=i.axis,h="number"==typeof s.grid?[s.grid,s.grid]:s.grid,l=h[0]||1,c=h[1]||1,u=Math.round((n.width-o.width)/l)*l,d=Math.round((n.height-o.height)/c)*c,p=o.width+u,f=o.height+d,m=s.maxWidth&&p>s.maxWidth,g=s.maxHeight&&f>s.maxHeight,_=s.minWidth&&s.minWidth>p,v=s.minHeight&&s.minHeight>f;s.grid=h,_&&(p+=l),v&&(f+=c),m&&(p-=l),g&&(f-=c),/^(se|s|e)$/.test(r)?(i.size.width=p,i.size.height=f):/^(ne)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.top=a.top-d):/^(sw)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.left=a.left-u):((0>=f-c||0>=p-l)&&(e=i._getPaddingPlusBorderDimensions(this)),f-c>0?(i.size.height=f,i.position.top=a.top-d):(f=c-e.height,i.size.height=f,i.position.top=a.top+o.height-f),p-l>0?(i.size.width=p,i.position.left=a.left-u):(p=l-e.width,i.size.width=p,i.position.left=a.left+o.width-p))}}),t.ui.resizable});/** - * Copyright (c) 2007 Ariel Flesler - aflesler ○ gmail • com | https://github.com/flesler - * Licensed under MIT - * @author Ariel Flesler - * @version 2.1.2 - */ -;(function(f){"use strict";"function"===typeof define&&define.amd?define(["jquery"],f):"undefined"!==typeof module&&module.exports?module.exports=f(require("jquery")):f(jQuery)})(function($){"use strict";function n(a){return!a.nodeName||-1!==$.inArray(a.nodeName.toLowerCase(),["iframe","#document","html","body"])}function h(a){return $.isFunction(a)||$.isPlainObject(a)?a:{top:a,left:a}}var p=$.scrollTo=function(a,d,b){return $(window).scrollTo(a,d,b)};p.defaults={axis:"xy",duration:0,limit:!0};$.fn.scrollTo=function(a,d,b){"object"=== typeof d&&(b=d,d=0);"function"===typeof b&&(b={onAfter:b});"max"===a&&(a=9E9);b=$.extend({},p.defaults,b);d=d||b.duration;var u=b.queue&&1=f[g]?0:Math.min(f[g],n));!a&&1-1){targetElements.on(evt+EVENT_NAMESPACE,function elementToggle(event){$.powerTip.toggle(this,event)})}else{targetElements.on(evt+EVENT_NAMESPACE,function elementOpen(event){$.powerTip.show(this,event)})}});$.each(options.closeEvents,function(idx,evt){if($.inArray(evt,options.openEvents)<0){targetElements.on(evt+EVENT_NAMESPACE,function elementClose(event){$.powerTip.hide(this,!isMouseEvent(event))})}});targetElements.on("keydown"+EVENT_NAMESPACE,function elementKeyDown(event){if(event.keyCode===27){$.powerTip.hide(this,true)}})}return targetElements};$.fn.powerTip.defaults={fadeInTime:200,fadeOutTime:100,followMouse:false,popupId:"powerTip",popupClass:null,intentSensitivity:7,intentPollInterval:100,closeDelay:100,placement:"n",smartPlacement:false,offset:10,mouseOnToPopup:false,manual:false,openEvents:["mouseenter","focus"],closeEvents:["mouseleave","blur"]};$.fn.powerTip.smartPlacementLists={n:["n","ne","nw","s"],e:["e","ne","se","w","nw","sw","n","s","e"],s:["s","se","sw","n"],w:["w","nw","sw","e","ne","se","n","s","w"],nw:["nw","w","sw","n","s","se","nw"],ne:["ne","e","se","n","s","sw","ne"],sw:["sw","w","nw","s","n","ne","sw"],se:["se","e","ne","s","n","nw","se"],"nw-alt":["nw-alt","n","ne-alt","sw-alt","s","se-alt","w","e"],"ne-alt":["ne-alt","n","nw-alt","se-alt","s","sw-alt","e","w"],"sw-alt":["sw-alt","s","se-alt","nw-alt","n","ne-alt","w","e"],"se-alt":["se-alt","s","sw-alt","ne-alt","n","nw-alt","e","w"]};$.powerTip={show:function apiShowTip(element,event){if(isMouseEvent(event)){trackMouse(event);session.previousX=event.pageX;session.previousY=event.pageY;$(element).data(DATA_DISPLAYCONTROLLER).show()}else{$(element).first().data(DATA_DISPLAYCONTROLLER).show(true,true)}return element},reposition:function apiResetPosition(element){$(element).first().data(DATA_DISPLAYCONTROLLER).resetPosition();return element},hide:function apiCloseTip(element,immediate){var displayController;immediate=element?immediate:true;if(element){displayController=$(element).first().data(DATA_DISPLAYCONTROLLER)}else if(session.activeHover){displayController=session.activeHover.data(DATA_DISPLAYCONTROLLER)}if(displayController){displayController.hide(immediate)}return element},toggle:function apiToggle(element,event){if(session.activeHover&&session.activeHover.is(element)){$.powerTip.hide(element,!isMouseEvent(event))}else{$.powerTip.show(element,event)}return element}};$.powerTip.showTip=$.powerTip.show;$.powerTip.closeTip=$.powerTip.hide;function CSSCoordinates(){var me=this;me.top="auto";me.left="auto";me.right="auto";me.bottom="auto";me.set=function(property,value){if($.isNumeric(value)){me[property]=Math.round(value)}}}function DisplayController(element,options,tipController){var hoverTimer=null,myCloseDelay=null;function openTooltip(immediate,forceOpen){cancelTimer();if(!element.data(DATA_HASACTIVEHOVER)){if(!immediate){session.tipOpenImminent=true;hoverTimer=setTimeout(function intentDelay(){hoverTimer=null;checkForIntent()},options.intentPollInterval)}else{if(forceOpen){element.data(DATA_FORCEDOPEN,true)}closeAnyDelayed();tipController.showTip(element)}}else{cancelClose()}}function closeTooltip(disableDelay){if(myCloseDelay){myCloseDelay=session.closeDelayTimeout=clearTimeout(myCloseDelay);session.delayInProgress=false}cancelTimer();session.tipOpenImminent=false;if(element.data(DATA_HASACTIVEHOVER)){element.data(DATA_FORCEDOPEN,false);if(!disableDelay){session.delayInProgress=true;session.closeDelayTimeout=setTimeout(function closeDelay(){session.closeDelayTimeout=null;tipController.hideTip(element);session.delayInProgress=false;myCloseDelay=null},options.closeDelay);myCloseDelay=session.closeDelayTimeout}else{tipController.hideTip(element)}}}function checkForIntent(){var xDifference=Math.abs(session.previousX-session.currentX),yDifference=Math.abs(session.previousY-session.currentY),totalDifference=xDifference+yDifference;if(totalDifference",{id:options.popupId});if($body.length===0){$body=$("body")}$body.append(tipElement);session.tooltips=session.tooltips?session.tooltips.add(tipElement):tipElement}if(options.followMouse){if(!tipElement.data(DATA_HASMOUSEMOVE)){$document.on("mousemove"+EVENT_NAMESPACE,positionTipOnCursor);$window.on("scroll"+EVENT_NAMESPACE,positionTipOnCursor);tipElement.data(DATA_HASMOUSEMOVE,true)}}function beginShowTip(element){element.data(DATA_HASACTIVEHOVER,true);tipElement.queue(function queueTipInit(next){showTip(element);next()})}function showTip(element){var tipContent;if(!element.data(DATA_HASACTIVEHOVER)){return}if(session.isTipOpen){if(!session.isClosing){hideTip(session.activeHover)}tipElement.delay(100).queue(function queueTipAgain(next){showTip(element);next()});return}element.trigger("powerTipPreRender");tipContent=getTooltipContent(element);if(tipContent){tipElement.empty().append(tipContent)}else{return}element.trigger("powerTipRender");session.activeHover=element;session.isTipOpen=true;tipElement.data(DATA_MOUSEONTOTIP,options.mouseOnToPopup);tipElement.addClass(options.popupClass);if(!options.followMouse||element.data(DATA_FORCEDOPEN)){positionTipOnElement(element);session.isFixedTipOpen=true}else{positionTipOnCursor()}if(!element.data(DATA_FORCEDOPEN)&&!options.followMouse){$document.on("click"+EVENT_NAMESPACE,function documentClick(event){var target=event.target;if(target!==element[0]){if(options.mouseOnToPopup){if(target!==tipElement[0]&&!$.contains(tipElement[0],target)){$.powerTip.hide()}}else{$.powerTip.hide()}}})}if(options.mouseOnToPopup&&!options.manual){tipElement.on("mouseenter"+EVENT_NAMESPACE,function tipMouseEnter(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).cancel()}});tipElement.on("mouseleave"+EVENT_NAMESPACE,function tipMouseLeave(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).hide()}})}tipElement.fadeIn(options.fadeInTime,function fadeInCallback(){if(!session.desyncTimeout){session.desyncTimeout=setInterval(closeDesyncedTip,500)}element.trigger("powerTipOpen")})}function hideTip(element){session.isClosing=true;session.isTipOpen=false;session.desyncTimeout=clearInterval(session.desyncTimeout);element.data(DATA_HASACTIVEHOVER,false);element.data(DATA_FORCEDOPEN,false);$document.off("click"+EVENT_NAMESPACE);tipElement.off(EVENT_NAMESPACE);tipElement.fadeOut(options.fadeOutTime,function fadeOutCallback(){var coords=new CSSCoordinates;session.activeHover=null;session.isClosing=false;session.isFixedTipOpen=false;tipElement.removeClass();coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);tipElement.css(coords);element.trigger("powerTipClose")})}function positionTipOnCursor(){var tipWidth,tipHeight,coords,collisions,collisionCount;if(!session.isFixedTipOpen&&(session.isTipOpen||session.tipOpenImminent&&tipElement.data(DATA_HASMOUSEMOVE))){tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=new CSSCoordinates;coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);collisions=getViewportCollisions(coords,tipWidth,tipHeight);if(collisions!==Collision.none){collisionCount=countFlags(collisions);if(collisionCount===1){if(collisions===Collision.right){coords.set("left",session.scrollLeft+session.windowWidth-tipWidth)}else if(collisions===Collision.bottom){coords.set("top",session.scrollTop+session.windowHeight-tipHeight)}}else{coords.set("left",session.currentX-tipWidth-options.offset);coords.set("top",session.currentY-tipHeight-options.offset)}}tipElement.css(coords)}}function positionTipOnElement(element){var priorityList,finalPlacement;if(options.smartPlacement||options.followMouse&&element.data(DATA_FORCEDOPEN)){priorityList=$.fn.powerTip.smartPlacementLists[options.placement];$.each(priorityList,function(idx,pos){var collisions=getViewportCollisions(placeTooltip(element,pos),tipElement.outerWidth(),tipElement.outerHeight());finalPlacement=pos;return collisions!==Collision.none})}else{placeTooltip(element,options.placement);finalPlacement=options.placement}tipElement.removeClass("w nw sw e ne se n s w se-alt sw-alt ne-alt nw-alt");tipElement.addClass(finalPlacement)}function placeTooltip(element,placement){var iterationCount=0,tipWidth,tipHeight,coords=new CSSCoordinates;coords.set("top",0);coords.set("left",0);tipElement.css(coords);do{tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=placementCalculator.compute(element,placement,tipWidth,tipHeight,options.offset);tipElement.css(coords)}while(++iterationCount<=5&&(tipWidth!==tipElement.outerWidth()||tipHeight!==tipElement.outerHeight()));return coords}function closeDesyncedTip(){var isDesynced=false,hasDesyncableCloseEvent=$.grep(["mouseleave","mouseout","blur","focusout"],function(eventType){return $.inArray(eventType,options.closeEvents)!==-1}).length>0;if(session.isTipOpen&&!session.isClosing&&!session.delayInProgress&&hasDesyncableCloseEvent){if(session.activeHover.data(DATA_HASACTIVEHOVER)===false||session.activeHover.is(":disabled")){isDesynced=true}else if(!isMouseOver(session.activeHover)&&!session.activeHover.is(":focus")&&!session.activeHover.data(DATA_FORCEDOPEN)){if(tipElement.data(DATA_MOUSEONTOTIP)){if(!isMouseOver(tipElement)){isDesynced=true}}else{isDesynced=true}}if(isDesynced){hideTip(session.activeHover)}}}this.showTip=beginShowTip;this.hideTip=hideTip;this.resetPosition=positionTipOnElement}function isSvgElement(element){return Boolean(window.SVGElement&&element[0]instanceof SVGElement)}function isMouseEvent(event){return Boolean(event&&$.inArray(event.type,MOUSE_EVENTS)>-1&&typeof event.pageX==="number")}function initTracking(){if(!session.mouseTrackingActive){session.mouseTrackingActive=true;getViewportDimensions();$(getViewportDimensions);$document.on("mousemove"+EVENT_NAMESPACE,trackMouse);$window.on("resize"+EVENT_NAMESPACE,trackResize);$window.on("scroll"+EVENT_NAMESPACE,trackScroll)}}function getViewportDimensions(){session.scrollLeft=$window.scrollLeft();session.scrollTop=$window.scrollTop();session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackResize(){session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackScroll(){var x=$window.scrollLeft(),y=$window.scrollTop();if(x!==session.scrollLeft){session.currentX+=x-session.scrollLeft;session.scrollLeft=x}if(y!==session.scrollTop){session.currentY+=y-session.scrollTop;session.scrollTop=y}}function trackMouse(event){session.currentX=event.pageX;session.currentY=event.pageY}function isMouseOver(element){var elementPosition=element.offset(),elementBox=element[0].getBoundingClientRect(),elementWidth=elementBox.right-elementBox.left,elementHeight=elementBox.bottom-elementBox.top;return session.currentX>=elementPosition.left&&session.currentX<=elementPosition.left+elementWidth&&session.currentY>=elementPosition.top&&session.currentY<=elementPosition.top+elementHeight}function getTooltipContent(element){var tipText=element.data(DATA_POWERTIP),tipObject=element.data(DATA_POWERTIPJQ),tipTarget=element.data(DATA_POWERTIPTARGET),targetElement,content;if(tipText){if($.isFunction(tipText)){tipText=tipText.call(element[0])}content=tipText}else if(tipObject){if($.isFunction(tipObject)){tipObject=tipObject.call(element[0])}if(tipObject.length>0){content=tipObject.clone(true,true)}}else if(tipTarget){targetElement=$("#"+tipTarget);if(targetElement.length>0){content=targetElement.html()}}return content}function getViewportCollisions(coords,elementWidth,elementHeight){var viewportTop=session.scrollTop,viewportLeft=session.scrollLeft,viewportBottom=viewportTop+session.windowHeight,viewportRight=viewportLeft+session.windowWidth,collisions=Collision.none;if(coords.topviewportBottom||Math.abs(coords.bottom-session.windowHeight)>viewportBottom){collisions|=Collision.bottom}if(coords.leftviewportRight){collisions|=Collision.left}if(coords.left+elementWidth>viewportRight||coords.right1)){a.preventDefault();var c=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(b,!0,!0,window,1,c.screenX,c.screenY,c.clientX,c.clientY,!1,!1,!1,!1,0,null),a.target.dispatchEvent(d)}}if(a.support.touch="ontouchend"in document,a.support.touch){var e,b=a.ui.mouse.prototype,c=b._mouseInit,d=b._mouseDestroy;b._touchStart=function(a){var b=this;!e&&b._mouseCapture(a.originalEvent.changedTouches[0])&&(e=!0,b._touchMoved=!1,f(a,"mouseover"),f(a,"mousemove"),f(a,"mousedown"))},b._touchMove=function(a){e&&(this._touchMoved=!0,f(a,"mousemove"))},b._touchEnd=function(a){e&&(f(a,"mouseup"),f(a,"mouseout"),this._touchMoved||f(a,"click"),e=!1)},b._mouseInit=function(){var b=this;b.element.bind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),c.call(b)},b._mouseDestroy=function(){var b=this;b.element.unbind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),d.call(b)}}}(jQuery);/*! SmartMenus jQuery Plugin - v1.1.0 - September 17, 2017 - * http://www.smartmenus.org/ - * Copyright Vasil Dinkov, Vadikom Web Ltd. http://vadikom.com; Licensed MIT */(function(t){"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof module&&"object"==typeof module.exports?module.exports=t(require("jquery")):t(jQuery)})(function($){function initMouseDetection(t){var e=".smartmenus_mouse";if(mouseDetectionEnabled||t)mouseDetectionEnabled&&t&&($(document).off(e),mouseDetectionEnabled=!1);else{var i=!0,s=null,o={mousemove:function(t){var e={x:t.pageX,y:t.pageY,timeStamp:(new Date).getTime()};if(s){var o=Math.abs(s.x-e.x),a=Math.abs(s.y-e.y);if((o>0||a>0)&&2>=o&&2>=a&&300>=e.timeStamp-s.timeStamp&&(mouse=!0,i)){var n=$(t.target).closest("a");n.is("a")&&$.each(menuTrees,function(){return $.contains(this.$root[0],n[0])?(this.itemEnter({currentTarget:n[0]}),!1):void 0}),i=!1}}s=e}};o[touchEvents?"touchstart":"pointerover pointermove pointerout MSPointerOver MSPointerMove MSPointerOut"]=function(t){isTouchEvent(t.originalEvent)&&(mouse=!1)},$(document).on(getEventsNS(o,e)),mouseDetectionEnabled=!0}}function isTouchEvent(t){return!/^(4|mouse)$/.test(t.pointerType)}function getEventsNS(t,e){e||(e="");var i={};for(var s in t)i[s.split(" ").join(e+" ")+e]=t[s];return i}var menuTrees=[],mouse=!1,touchEvents="ontouchstart"in window,mouseDetectionEnabled=!1,requestAnimationFrame=window.requestAnimationFrame||function(t){return setTimeout(t,1e3/60)},cancelAnimationFrame=window.cancelAnimationFrame||function(t){clearTimeout(t)},canAnimate=!!$.fn.animate;return $.SmartMenus=function(t,e){this.$root=$(t),this.opts=e,this.rootId="",this.accessIdPrefix="",this.$subArrow=null,this.activatedItems=[],this.visibleSubMenus=[],this.showTimeout=0,this.hideTimeout=0,this.scrollTimeout=0,this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.idInc=0,this.$firstLink=null,this.$firstSub=null,this.disabled=!1,this.$disableOverlay=null,this.$touchScrollingSub=null,this.cssTransforms3d="perspective"in t.style||"webkitPerspective"in t.style,this.wasCollapsible=!1,this.init()},$.extend($.SmartMenus,{hideAll:function(){$.each(menuTrees,function(){this.menuHideAll()})},destroy:function(){for(;menuTrees.length;)menuTrees[0].destroy();initMouseDetection(!0)},prototype:{init:function(t){var e=this;if(!t){menuTrees.push(this),this.rootId=((new Date).getTime()+Math.random()+"").replace(/\D/g,""),this.accessIdPrefix="sm-"+this.rootId+"-",this.$root.hasClass("sm-rtl")&&(this.opts.rightToLeftSubMenus=!0);var i=".smartmenus";this.$root.data("smartmenus",this).attr("data-smartmenus-id",this.rootId).dataSM("level",1).on(getEventsNS({"mouseover focusin":$.proxy(this.rootOver,this),"mouseout focusout":$.proxy(this.rootOut,this),keydown:$.proxy(this.rootKeyDown,this)},i)).on(getEventsNS({mouseenter:$.proxy(this.itemEnter,this),mouseleave:$.proxy(this.itemLeave,this),mousedown:$.proxy(this.itemDown,this),focus:$.proxy(this.itemFocus,this),blur:$.proxy(this.itemBlur,this),click:$.proxy(this.itemClick,this)},i),"a"),i+=this.rootId,this.opts.hideOnClick&&$(document).on(getEventsNS({touchstart:$.proxy(this.docTouchStart,this),touchmove:$.proxy(this.docTouchMove,this),touchend:$.proxy(this.docTouchEnd,this),click:$.proxy(this.docClick,this)},i)),$(window).on(getEventsNS({"resize orientationchange":$.proxy(this.winResize,this)},i)),this.opts.subIndicators&&(this.$subArrow=$("").addClass("sub-arrow"),this.opts.subIndicatorsText&&this.$subArrow.html(this.opts.subIndicatorsText)),initMouseDetection()}if(this.$firstSub=this.$root.find("ul").each(function(){e.menuInit($(this))}).eq(0),this.$firstLink=this.$root.find("a").eq(0),this.opts.markCurrentItem){var s=/(index|default)\.[^#\?\/]*/i,o=/#.*/,a=window.location.href.replace(s,""),n=a.replace(o,"");this.$root.find("a").each(function(){var t=this.href.replace(s,""),i=$(this);(t==a||t==n)&&(i.addClass("current"),e.opts.markCurrentTree&&i.parentsUntil("[data-smartmenus-id]","ul").each(function(){$(this).dataSM("parent-a").addClass("current")}))})}this.wasCollapsible=this.isCollapsible()},destroy:function(t){if(!t){var e=".smartmenus";this.$root.removeData("smartmenus").removeAttr("data-smartmenus-id").removeDataSM("level").off(e),e+=this.rootId,$(document).off(e),$(window).off(e),this.opts.subIndicators&&(this.$subArrow=null)}this.menuHideAll();var i=this;this.$root.find("ul").each(function(){var t=$(this);t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.dataSM("shown-before")&&((i.opts.subMenusMinWidth||i.opts.subMenusMaxWidth)&&t.css({width:"",minWidth:"",maxWidth:""}).removeClass("sm-nowrap"),t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.css({zIndex:"",top:"",left:"",marginLeft:"",marginTop:"",display:""})),0==(t.attr("id")||"").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeDataSM("in-mega").removeDataSM("shown-before").removeDataSM("scroll-arrows").removeDataSM("parent-a").removeDataSM("level").removeDataSM("beforefirstshowfired").removeAttr("role").removeAttr("aria-hidden").removeAttr("aria-labelledby").removeAttr("aria-expanded"),this.$root.find("a.has-submenu").each(function(){var t=$(this);0==t.attr("id").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeClass("has-submenu").removeDataSM("sub").removeAttr("aria-haspopup").removeAttr("aria-controls").removeAttr("aria-expanded").closest("li").removeDataSM("sub"),this.opts.subIndicators&&this.$root.find("span.sub-arrow").remove(),this.opts.markCurrentItem&&this.$root.find("a.current").removeClass("current"),t||(this.$root=null,this.$firstLink=null,this.$firstSub=null,this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),menuTrees.splice($.inArray(this,menuTrees),1))},disable:function(t){if(!this.disabled){if(this.menuHideAll(),!t&&!this.opts.isPopup&&this.$root.is(":visible")){var e=this.$root.offset();this.$disableOverlay=$('
').css({position:"absolute",top:e.top,left:e.left,width:this.$root.outerWidth(),height:this.$root.outerHeight(),zIndex:this.getStartZIndex(!0),opacity:0}).appendTo(document.body)}this.disabled=!0}},docClick:function(t){return this.$touchScrollingSub?(this.$touchScrollingSub=null,void 0):((this.visibleSubMenus.length&&!$.contains(this.$root[0],t.target)||$(t.target).closest("a").length)&&this.menuHideAll(),void 0)},docTouchEnd:function(){if(this.lastTouch){if(!(!this.visibleSubMenus.length||void 0!==this.lastTouch.x2&&this.lastTouch.x1!=this.lastTouch.x2||void 0!==this.lastTouch.y2&&this.lastTouch.y1!=this.lastTouch.y2||this.lastTouch.target&&$.contains(this.$root[0],this.lastTouch.target))){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var t=this;this.hideTimeout=setTimeout(function(){t.menuHideAll()},350)}this.lastTouch=null}},docTouchMove:function(t){if(this.lastTouch){var e=t.originalEvent.touches[0];this.lastTouch.x2=e.pageX,this.lastTouch.y2=e.pageY}},docTouchStart:function(t){var e=t.originalEvent.touches[0];this.lastTouch={x1:e.pageX,y1:e.pageY,target:e.target}},enable:function(){this.disabled&&(this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),this.disabled=!1)},getClosestMenu:function(t){for(var e=$(t).closest("ul");e.dataSM("in-mega");)e=e.parent().closest("ul");return e[0]||null},getHeight:function(t){return this.getOffset(t,!0)},getOffset:function(t,e){var i;"none"==t.css("display")&&(i={position:t[0].style.position,visibility:t[0].style.visibility},t.css({position:"absolute",visibility:"hidden"}).show());var s=t[0].getBoundingClientRect&&t[0].getBoundingClientRect(),o=s&&(e?s.height||s.bottom-s.top:s.width||s.right-s.left);return o||0===o||(o=e?t[0].offsetHeight:t[0].offsetWidth),i&&t.hide().css(i),o},getStartZIndex:function(t){var e=parseInt(this[t?"$root":"$firstSub"].css("z-index"));return!t&&isNaN(e)&&(e=parseInt(this.$root.css("z-index"))),isNaN(e)?1:e},getTouchPoint:function(t){return t.touches&&t.touches[0]||t.changedTouches&&t.changedTouches[0]||t},getViewport:function(t){var e=t?"Height":"Width",i=document.documentElement["client"+e],s=window["inner"+e];return s&&(i=Math.min(i,s)),i},getViewportHeight:function(){return this.getViewport(!0)},getViewportWidth:function(){return this.getViewport()},getWidth:function(t){return this.getOffset(t)},handleEvents:function(){return!this.disabled&&this.isCSSOn()},handleItemEvents:function(t){return this.handleEvents()&&!this.isLinkInMegaMenu(t)},isCollapsible:function(){return"static"==this.$firstSub.css("position")},isCSSOn:function(){return"inline"!=this.$firstLink.css("display")},isFixed:function(){var t="fixed"==this.$root.css("position");return t||this.$root.parentsUntil("body").each(function(){return"fixed"==$(this).css("position")?(t=!0,!1):void 0}),t},isLinkInMegaMenu:function(t){return $(this.getClosestMenu(t[0])).hasClass("mega-menu")},isTouchMode:function(){return!mouse||this.opts.noMouseOver||this.isCollapsible()},itemActivate:function(t,e){var i=t.closest("ul"),s=i.dataSM("level");if(s>1&&(!this.activatedItems[s-2]||this.activatedItems[s-2][0]!=i.dataSM("parent-a")[0])){var o=this;$(i.parentsUntil("[data-smartmenus-id]","ul").get().reverse()).add(i).each(function(){o.itemActivate($(this).dataSM("parent-a"))})}if((!this.isCollapsible()||e)&&this.menuHideSubMenus(this.activatedItems[s-1]&&this.activatedItems[s-1][0]==t[0]?s:s-1),this.activatedItems[s-1]=t,this.$root.triggerHandler("activate.smapi",t[0])!==!1){var a=t.dataSM("sub");a&&(this.isTouchMode()||!this.opts.showOnClick||this.clickActivated)&&this.menuShow(a)}},itemBlur:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&this.$root.triggerHandler("blur.smapi",e[0])},itemClick:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(this.$touchScrollingSub&&this.$touchScrollingSub[0]==e.closest("ul")[0])return this.$touchScrollingSub=null,t.stopPropagation(),!1;if(this.$root.triggerHandler("click.smapi",e[0])===!1)return!1;var i=$(t.target).is(".sub-arrow"),s=e.dataSM("sub"),o=s?2==s.dataSM("level"):!1,a=this.isCollapsible(),n=/toggle$/.test(this.opts.collapsibleBehavior),r=/link$/.test(this.opts.collapsibleBehavior),h=/^accordion/.test(this.opts.collapsibleBehavior);if(s&&!s.is(":visible")){if((!r||!a||i)&&(this.opts.showOnClick&&o&&(this.clickActivated=!0),this.itemActivate(e,h),s.is(":visible")))return this.focusActivated=!0,!1}else if(a&&(n||i))return this.itemActivate(e,h),this.menuHide(s),n&&(this.focusActivated=!1),!1;return this.opts.showOnClick&&o||e.hasClass("disabled")||this.$root.triggerHandler("select.smapi",e[0])===!1?!1:void 0}},itemDown:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&e.dataSM("mousedown",!0)},itemEnter:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(!this.isTouchMode()){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);var i=this;this.showTimeout=setTimeout(function(){i.itemActivate(e)},this.opts.showOnClick&&1==e.closest("ul").dataSM("level")?1:this.opts.showTimeout)}this.$root.triggerHandler("mouseenter.smapi",e[0])}},itemFocus:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(!this.focusActivated||this.isTouchMode()&&e.dataSM("mousedown")||this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0]==e[0]||this.itemActivate(e,!0),this.$root.triggerHandler("focus.smapi",e[0]))},itemLeave:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(this.isTouchMode()||(e[0].blur(),this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0)),e.removeDataSM("mousedown"),this.$root.triggerHandler("mouseleave.smapi",e[0]))},menuHide:function(t){if(this.$root.triggerHandler("beforehide.smapi",t[0])!==!1&&(canAnimate&&t.stop(!0,!0),"none"!=t.css("display"))){var e=function(){t.css("z-index","")};this.isCollapsible()?canAnimate&&this.opts.collapsibleHideFunction?this.opts.collapsibleHideFunction.call(this,t,e):t.hide(this.opts.collapsibleHideDuration,e):canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,t,e):t.hide(this.opts.hideDuration,e),t.dataSM("scroll")&&(this.menuScrollStop(t),t.css({"touch-action":"","-ms-touch-action":"","-webkit-transform":"",transform:""}).off(".smartmenus_scroll").removeDataSM("scroll").dataSM("scroll-arrows").hide()),t.dataSM("parent-a").removeClass("highlighted").attr("aria-expanded","false"),t.attr({"aria-expanded":"false","aria-hidden":"true"});var i=t.dataSM("level");this.activatedItems.splice(i-1,1),this.visibleSubMenus.splice($.inArray(t,this.visibleSubMenus),1),this.$root.triggerHandler("hide.smapi",t[0])}},menuHideAll:function(){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);for(var t=this.opts.isPopup?1:0,e=this.visibleSubMenus.length-1;e>=t;e--)this.menuHide(this.visibleSubMenus[e]);this.opts.isPopup&&(canAnimate&&this.$root.stop(!0,!0),this.$root.is(":visible")&&(canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,this.$root):this.$root.hide(this.opts.hideDuration))),this.activatedItems=[],this.visibleSubMenus=[],this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.$root.triggerHandler("hideAll.smapi")},menuHideSubMenus:function(t){for(var e=this.activatedItems.length-1;e>=t;e--){var i=this.activatedItems[e].dataSM("sub");i&&this.menuHide(i)}},menuInit:function(t){if(!t.dataSM("in-mega")){t.hasClass("mega-menu")&&t.find("ul").dataSM("in-mega",!0);for(var e=2,i=t[0];(i=i.parentNode.parentNode)!=this.$root[0];)e++;var s=t.prevAll("a").eq(-1);s.length||(s=t.prevAll().find("a").eq(-1)),s.addClass("has-submenu").dataSM("sub",t),t.dataSM("parent-a",s).dataSM("level",e).parent().dataSM("sub",t);var o=s.attr("id")||this.accessIdPrefix+ ++this.idInc,a=t.attr("id")||this.accessIdPrefix+ ++this.idInc;s.attr({id:o,"aria-haspopup":"true","aria-controls":a,"aria-expanded":"false"}),t.attr({id:a,role:"group","aria-hidden":"true","aria-labelledby":o,"aria-expanded":"false"}),this.opts.subIndicators&&s[this.opts.subIndicatorsPos](this.$subArrow.clone())}},menuPosition:function(t){var e,i,s=t.dataSM("parent-a"),o=s.closest("li"),a=o.parent(),n=t.dataSM("level"),r=this.getWidth(t),h=this.getHeight(t),u=s.offset(),l=u.left,c=u.top,d=this.getWidth(s),m=this.getHeight(s),p=$(window),f=p.scrollLeft(),v=p.scrollTop(),b=this.getViewportWidth(),S=this.getViewportHeight(),g=a.parent().is("[data-sm-horizontal-sub]")||2==n&&!a.hasClass("sm-vertical"),M=this.opts.rightToLeftSubMenus&&!o.is("[data-sm-reverse]")||!this.opts.rightToLeftSubMenus&&o.is("[data-sm-reverse]"),w=2==n?this.opts.mainMenuSubOffsetX:this.opts.subMenusSubOffsetX,T=2==n?this.opts.mainMenuSubOffsetY:this.opts.subMenusSubOffsetY;if(g?(e=M?d-r-w:w,i=this.opts.bottomToTopSubMenus?-h-T:m+T):(e=M?w-r:d-w,i=this.opts.bottomToTopSubMenus?m-T-h:T),this.opts.keepInViewport){var y=l+e,I=c+i;if(M&&f>y?e=g?f-y+e:d-w:!M&&y+r>f+b&&(e=g?f+b-r-y+e:w-r),g||(S>h&&I+h>v+S?i+=v+S-h-I:(h>=S||v>I)&&(i+=v-I)),g&&(I+h>v+S+.49||v>I)||!g&&h>S+.49){var x=this;t.dataSM("scroll-arrows")||t.dataSM("scroll-arrows",$([$('')[0],$('')[0]]).on({mouseenter:function(){t.dataSM("scroll").up=$(this).hasClass("scroll-up"),x.menuScroll(t)},mouseleave:function(e){x.menuScrollStop(t),x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(t){t.preventDefault()}}).insertAfter(t));var A=".smartmenus_scroll";if(t.dataSM("scroll",{y:this.cssTransforms3d?0:i-m,step:1,itemH:m,subH:h,arrowDownH:this.getHeight(t.dataSM("scroll-arrows").eq(1))}).on(getEventsNS({mouseover:function(e){x.menuScrollOver(t,e)},mouseout:function(e){x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(e){x.menuScrollMousewheel(t,e)}},A)).dataSM("scroll-arrows").css({top:"auto",left:"0",marginLeft:e+(parseInt(t.css("border-left-width"))||0),width:r-(parseInt(t.css("border-left-width"))||0)-(parseInt(t.css("border-right-width"))||0),zIndex:t.css("z-index")}).eq(g&&this.opts.bottomToTopSubMenus?0:1).show(),this.isFixed()){var C={};C[touchEvents?"touchstart touchmove touchend":"pointerdown pointermove pointerup MSPointerDown MSPointerMove MSPointerUp"]=function(e){x.menuScrollTouch(t,e)},t.css({"touch-action":"none","-ms-touch-action":"none"}).on(getEventsNS(C,A))}}}t.css({top:"auto",left:"0",marginLeft:e,marginTop:i-m})},menuScroll:function(t,e,i){var s,o=t.dataSM("scroll"),a=t.dataSM("scroll-arrows"),n=o.up?o.upEnd:o.downEnd;if(!e&&o.momentum){if(o.momentum*=.92,s=o.momentum,.5>s)return this.menuScrollStop(t),void 0}else s=i||(e||!this.opts.scrollAccelerate?this.opts.scrollStep:Math.floor(o.step));var r=t.dataSM("level");if(this.activatedItems[r-1]&&this.activatedItems[r-1].dataSM("sub")&&this.activatedItems[r-1].dataSM("sub").is(":visible")&&this.menuHideSubMenus(r-1),o.y=o.up&&o.y>=n||!o.up&&n>=o.y?o.y:Math.abs(n-o.y)>s?o.y+(o.up?s:-s):n,t.css(this.cssTransforms3d?{"-webkit-transform":"translate3d(0, "+o.y+"px, 0)",transform:"translate3d(0, "+o.y+"px, 0)"}:{marginTop:o.y}),mouse&&(o.up&&o.y>o.downEnd||!o.up&&o.y0;t.dataSM("scroll-arrows").eq(i?0:1).is(":visible")&&(t.dataSM("scroll").up=i,this.menuScroll(t,!0))}e.preventDefault()},menuScrollOut:function(t,e){mouse&&(/^scroll-(up|down)/.test((e.relatedTarget||"").className)||(t[0]==e.relatedTarget||$.contains(t[0],e.relatedTarget))&&this.getClosestMenu(e.relatedTarget)==t[0]||t.dataSM("scroll-arrows").css("visibility","hidden"))},menuScrollOver:function(t,e){if(mouse&&!/^scroll-(up|down)/.test(e.target.className)&&this.getClosestMenu(e.target)==t[0]){this.menuScrollRefreshData(t);var i=t.dataSM("scroll"),s=$(window).scrollTop()-t.dataSM("parent-a").offset().top-i.itemH;t.dataSM("scroll-arrows").eq(0).css("margin-top",s).end().eq(1).css("margin-top",s+this.getViewportHeight()-i.arrowDownH).end().css("visibility","visible")}},menuScrollRefreshData:function(t){var e=t.dataSM("scroll"),i=$(window).scrollTop()-t.dataSM("parent-a").offset().top-e.itemH;this.cssTransforms3d&&(i=-(parseFloat(t.css("margin-top"))-i)),$.extend(e,{upEnd:i,downEnd:i+this.getViewportHeight()-e.subH})},menuScrollStop:function(t){return this.scrollTimeout?(cancelAnimationFrame(this.scrollTimeout),this.scrollTimeout=0,t.dataSM("scroll").step=1,!0):void 0},menuScrollTouch:function(t,e){if(e=e.originalEvent,isTouchEvent(e)){var i=this.getTouchPoint(e);if(this.getClosestMenu(i.target)==t[0]){var s=t.dataSM("scroll");if(/(start|down)$/i.test(e.type))this.menuScrollStop(t)?(e.preventDefault(),this.$touchScrollingSub=t):this.$touchScrollingSub=null,this.menuScrollRefreshData(t),$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp});else if(/move$/i.test(e.type)){var o=void 0!==s.touchY?s.touchY:s.touchStartY;if(void 0!==o&&o!=i.pageY){this.$touchScrollingSub=t;var a=i.pageY>o;void 0!==s.up&&s.up!=a&&$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp}),$.extend(s,{up:a,touchY:i.pageY}),this.menuScroll(t,!0,Math.abs(i.pageY-o))}e.preventDefault()}else void 0!==s.touchY&&((s.momentum=15*Math.pow(Math.abs(i.pageY-s.touchStartY)/(e.timeStamp-s.touchStartTime),2))&&(this.menuScrollStop(t),this.menuScroll(t),e.preventDefault()),delete s.touchY)}}},menuShow:function(t){if((t.dataSM("beforefirstshowfired")||(t.dataSM("beforefirstshowfired",!0),this.$root.triggerHandler("beforefirstshow.smapi",t[0])!==!1))&&this.$root.triggerHandler("beforeshow.smapi",t[0])!==!1&&(t.dataSM("shown-before",!0),canAnimate&&t.stop(!0,!0),!t.is(":visible"))){var e=t.dataSM("parent-a"),i=this.isCollapsible();if((this.opts.keepHighlighted||i)&&e.addClass("highlighted"),i)t.removeClass("sm-nowrap").css({zIndex:"",width:"auto",minWidth:"",maxWidth:"",top:"",left:"",marginLeft:"",marginTop:""});else{if(t.css("z-index",this.zIndexInc=(this.zIndexInc||this.getStartZIndex())+1),(this.opts.subMenusMinWidth||this.opts.subMenusMaxWidth)&&(t.css({width:"auto",minWidth:"",maxWidth:""}).addClass("sm-nowrap"),this.opts.subMenusMinWidth&&t.css("min-width",this.opts.subMenusMinWidth),this.opts.subMenusMaxWidth)){var s=this.getWidth(t);t.css("max-width",this.opts.subMenusMaxWidth),s>this.getWidth(t)&&t.removeClass("sm-nowrap").css("width",this.opts.subMenusMaxWidth)}this.menuPosition(t)}var o=function(){t.css("overflow","")};i?canAnimate&&this.opts.collapsibleShowFunction?this.opts.collapsibleShowFunction.call(this,t,o):t.show(this.opts.collapsibleShowDuration,o):canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,t,o):t.show(this.opts.showDuration,o),e.attr("aria-expanded","true"),t.attr({"aria-expanded":"true","aria-hidden":"false"}),this.visibleSubMenus.push(t),this.$root.triggerHandler("show.smapi",t[0])}},popupHide:function(t){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},t?1:this.opts.hideTimeout)},popupShow:function(t,e){if(!this.opts.isPopup)return alert('SmartMenus jQuery Error:\n\nIf you want to show this menu via the "popupShow" method, set the isPopup:true option.'),void 0;if(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),this.$root.dataSM("shown-before",!0),canAnimate&&this.$root.stop(!0,!0),!this.$root.is(":visible")){this.$root.css({left:t,top:e});var i=this,s=function(){i.$root.css("overflow","")};canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,this.$root,s):this.$root.show(this.opts.showDuration,s),this.visibleSubMenus[0]=this.$root}},refresh:function(){this.destroy(!0),this.init(!0)},rootKeyDown:function(t){if(this.handleEvents())switch(t.keyCode){case 27:var e=this.activatedItems[0];if(e){this.menuHideAll(),e[0].focus();var i=e.dataSM("sub");i&&this.menuHide(i)}break;case 32:var s=$(t.target);if(s.is("a")&&this.handleItemEvents(s)){var i=s.dataSM("sub");i&&!i.is(":visible")&&(this.itemClick({currentTarget:t.target}),t.preventDefault())}}},rootOut:function(t){if(this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),!this.opts.showOnClick||!this.opts.hideOnClick)){var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},this.opts.hideTimeout)}},rootOver:function(t){this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0)},winResize:function(t){if(this.handleEvents()){if(!("onorientationchange"in window)||"orientationchange"==t.type){var e=this.isCollapsible();this.wasCollapsible&&e||(this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0].blur(),this.menuHideAll()),this.wasCollapsible=e}}else if(this.$disableOverlay){var i=this.$root.offset();this.$disableOverlay.css({top:i.top,left:i.left,width:this.$root.outerWidth(),height:this.$root.outerHeight()})}}}}),$.fn.dataSM=function(t,e){return e?this.data(t+"_smartmenus",e):this.data(t+"_smartmenus")},$.fn.removeDataSM=function(t){return this.removeData(t+"_smartmenus")},$.fn.smartmenus=function(options){if("string"==typeof options){var args=arguments,method=options;return Array.prototype.shift.call(args),this.each(function(){var t=$(this).data("smartmenus");t&&t[method]&&t[method].apply(t,args)})}return this.each(function(){var dataOpts=$(this).data("sm-options")||null;if(dataOpts)try{dataOpts=eval("("+dataOpts+")")}catch(e){dataOpts=null,alert('ERROR\n\nSmartMenus jQuery init:\nInvalid "data-sm-options" attribute value syntax.')}new $.SmartMenus(this,$.extend({},$.fn.smartmenus.defaults,options,dataOpts))})},$.fn.smartmenus.defaults={isPopup:!1,mainMenuSubOffsetX:0,mainMenuSubOffsetY:0,subMenusSubOffsetX:0,subMenusSubOffsetY:0,subMenusMinWidth:"10em",subMenusMaxWidth:"20em",subIndicators:!0,subIndicatorsPos:"append",subIndicatorsText:"",scrollStep:30,scrollAccelerate:!0,showTimeout:250,hideTimeout:500,showDuration:0,showFunction:null,hideDuration:0,hideFunction:function(t,e){t.fadeOut(200,e)},collapsibleShowDuration:0,collapsibleShowFunction:function(t,e){t.slideDown(200,e)},collapsibleHideDuration:0,collapsibleHideFunction:function(t,e){t.slideUp(200,e)},showOnClick:!1,hideOnClick:!0,noMouseOver:!1,keepInViewport:!0,keepHighlighted:!0,markCurrentItem:!1,markCurrentTree:!0,rightToLeftSubMenus:!1,bottomToTopSubMenus:!1,collapsibleBehavior:"default"},$}); \ No newline at end of file diff --git a/docs/m-dark+documentation.compiled.css b/docs/m-dark+documentation.compiled.css new file mode 100644 index 0000000..39ae0b9 --- /dev/null +++ b/docs/m-dark+documentation.compiled.css @@ -0,0 +1,2860 @@ +/* Generated using `./postprocess.py m-dark.css m-documentation.css -o m-dark+documentation.compiled.css`. Do not edit. */ + +/* + This file is part of m.css. + + Copyright © 2017, 2018, 2019 Vladimír Vondruš + + Permission is hereby granted, free of charge, to any person obtaining a + copy of this software and associated documentation files (the "Software"), + to deal in the Software without restriction, including without limitation + the rights to use, copy, modify, merge, publish, distribute, sublicense, + and/or sell copies of the Software, and to permit persons to whom the + Software is furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included + in all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + DEALINGS IN THE SOFTWARE. +*/ + +*, ::before, ::after { box-sizing: border-box; } +body { margin: 0; } +.m-container { + width: 100%; + margin: auto; + padding-left: 1rem; + padding-right: 1rem; +} +.m-row { + margin-left: -1rem; + margin-right: -1rem; +} +.m-row:after { + content: ' '; + clear: both; + display: table; +} +.m-row > [class*='m-col-'] { + position: relative; + padding: 1rem; +} +[class*='m-clearfix-']::after { + display: block; + content: ' '; + clear: both; +} +[class*='m-show-'] { + display: none; +} +.m-container-inflate, :not(.m-row) > [class*='m-col-'] { + margin-bottom: 1rem; +} +.m-container-inflate:last-child, :not(.m-row) > [class*='m-col-']:last-child { + margin-bottom: 0; +} +.m-container.m-nopad, [class*='m-col-'].m-nopad, +.m-container.m-nopadx, [class*='m-col-'].m-nopadx, +.m-container.m-nopadl, [class*='m-col-'].m-nopadl { + padding-left: 0; +} +.m-container.m-nopad, [class*='m-col-'].m-nopad, +.m-container.m-nopadx, [class*='m-col-'].m-nopadx, +.m-container.m-nopadr, [class*='m-col-'].m-nopadr { + padding-right: 0; +} +[class*='m-col-'].m-nopad, [class*='m-col-'].m-nopady, [class*='m-col-'].m-nopadt { + padding-top: 0; +} +[class*='m-col-'].m-nopad, [class*='m-col-'].m-nopady, [class*='m-col-'].m-nopadb, +.m-container-inflate.m-nopadb { + padding-bottom: 0; +} +[class*='m-col-t-'] { float: left; } +.m-left-t { + padding-right: 1rem; + float: left; +} +.m-right-t, [class*='m-col-t-'].m-right-t { + padding-left: 1rem; + float: right; +} +.m-center-t, [class*='m-col-t-'].m-center-t { + float: none; +} +.m-center-t, [class*='m-col-t-'].m-center-t { + margin-left: auto; + margin-right: auto; + float: none; +} +.m-col-t-1 { width: calc(1 * 100% / 12); } +.m-col-t-2 { width: calc(2 * 100% / 12); } +.m-col-t-3 { width: calc(3 * 100% / 12); } +.m-col-t-4 { width: calc(4 * 100% / 12); } +.m-col-t-5 { width: calc(5 * 100% / 12); } +.m-col-t-6 { width: calc(6 * 100% / 12); } +.m-col-t-7 { width: calc(7 * 100% / 12); } +.m-col-t-8 { width: calc(8 * 100% / 12); } +.m-col-t-9 { width: calc(9 * 100% / 12); } +.m-col-t-10 { width: calc(10 * 100% / 12); } +.m-col-t-11 { width: calc(11 * 100% / 12); } +.m-col-t-12 { width: calc(12 * 100% / 12); } +.m-push-t-1 { left: calc(1 * 100% / 12); } +.m-push-t-2 { left: calc(2 * 100% / 12); } +.m-push-t-3 { left: calc(3 * 100% / 12); } +.m-push-t-4 { left: calc(4 * 100% / 12); } +.m-push-t-5 { left: calc(5 * 100% / 12); } +.m-push-t-6 { left: calc(6 * 100% / 12); } +.m-push-t-7 { left: calc(7 * 100% / 12); } +.m-push-t-8 { left: calc(8 * 100% / 12); } +.m-push-t-9 { left: calc(9 * 100% / 12); } +.m-push-t-10 { left: calc(10 * 100% / 12); } +.m-push-t-11 { left: calc(11 * 100% / 12); } +.m-pull-t-1 { right: calc(1 * 100% / 12); } +.m-pull-t-2 { right: calc(2 * 100% / 12); } +.m-pull-t-3 { right: calc(3 * 100% / 12); } +.m-pull-t-4 { right: calc(4 * 100% / 12); } +.m-pull-t-5 { right: calc(5 * 100% / 12); } +.m-pull-t-6 { right: calc(6 * 100% / 12); } +.m-pull-t-7 { right: calc(7 * 100% / 12); } +.m-pull-t-8 { right: calc(8 * 100% / 12); } +.m-pull-t-9 { right: calc(9 * 100% / 12); } +.m-pull-t-10 { right: calc(10 * 100% / 12); } +.m-pull-t-11 { right: calc(11 * 100% / 12); } +@media screen and (min-width: 576px) { + .m-container { width: 560px; } + .m-container-inflatable .m-col-s-10 .m-container-inflate:not([class*='m-left-']):not([class*='m-right-']) { + margin-left: -10%; + margin-right: -10%; + } + .m-container-inflatable .m-col-s-10 .m-container-inflate.m-left-s { + margin-left: -10%; + } + .m-container-inflatable .m-col-s-10 .m-container-inflate.m-right-s { + margin-right: -10%; + } + [class*='m-col-s-'] { float: left; } + .m-left-s { + padding-right: 1rem; + float: left; + } + .m-right-s, [class*='m-col-s-'].m-right-s { + padding-left: 1rem; + float: right; + } + .m-center-s, [class*='m-col-s-'].m-center-s { + margin-left: auto; + margin-right: auto; + float: none; + } + .m-col-s-1 { width: calc(1 * 100% / 12); } + .m-col-s-2 { width: calc(2 * 100% / 12); } + .m-col-s-3 { width: calc(3 * 100% / 12); } + .m-col-s-4 { width: calc(4 * 100% / 12); } + .m-col-s-5 { width: calc(5 * 100% / 12); } + .m-col-s-6 { width: calc(6 * 100% / 12); } + .m-col-s-7 { width: calc(7 * 100% / 12); } + .m-col-s-8 { width: calc(8 * 100% / 12); } + .m-col-s-9 { width: calc(9 * 100% / 12); } + .m-col-s-10 { width: calc(10 * 100% / 12); } + .m-col-s-11 { width: calc(11 * 100% / 12); } + .m-col-s-12 { width: calc(12 * 100% / 12); } + .m-push-s-0 { left: calc(0 * 100% / 12); } + .m-push-s-1 { left: calc(1 * 100% / 12); } + .m-push-s-2 { left: calc(2 * 100% / 12); } + .m-push-s-3 { left: calc(3 * 100% / 12); } + .m-push-s-4 { left: calc(4 * 100% / 12); } + .m-push-s-5 { left: calc(5 * 100% / 12); } + .m-push-s-6 { left: calc(6 * 100% / 12); } + .m-push-s-7 { left: calc(7 * 100% / 12); } + .m-push-s-8 { left: calc(8 * 100% / 12); } + .m-push-s-9 { left: calc(9 * 100% / 12); } + .m-push-s-10 { left: calc(10 * 100% / 12); } + .m-push-s-11 { left: calc(11 * 100% / 12); } + .m-pull-s-0 { right: calc(0 * 100% / 12); } + .m-pull-s-1 { right: calc(1 * 100% / 12); } + .m-pull-s-2 { right: calc(2 * 100% / 12); } + .m-pull-s-3 { right: calc(3 * 100% / 12); } + .m-pull-s-4 { right: calc(4 * 100% / 12); } + .m-pull-s-5 { right: calc(5 * 100% / 12); } + .m-pull-s-6 { right: calc(6 * 100% / 12); } + .m-pull-s-7 { right: calc(7 * 100% / 12); } + .m-pull-s-8 { right: calc(8 * 100% / 12); } + .m-pull-s-9 { right: calc(9 * 100% / 12); } + .m-pull-s-10 { right: calc(10 * 100% / 12); } + .m-pull-s-11 { right: calc(11 * 100% / 12); } + .m-clearfix-t::after { display: none; } + .m-hide-s { display: none; } + .m-show-s { display: block; } + .m-col-s-none { + width: auto; + float: none; + } +} +@media screen and (min-width: 768px) { + .m-container { width: 750px; } + .m-container-inflatable .m-col-m-10 .m-container-inflate:not([class*='m-left-']):not([class*='m-right-']) { + margin-left: -10%; + margin-right: -10%; + } + .m-container-inflatable .m-col-m-10 .m-container-inflate.m-left-m { + margin-left: -10%; + } + .m-container-inflatable .m-col-m-10 .m-container-inflate.m-right-m { + margin-right: -10%; + } + [class*='m-col-m-'] { float: left; } + .m-left-m { + padding-right: 1rem; + float: left; + } + .m-right-m, [class*='m-col-m-'].m-right-m { + padding-left: 1rem; + float: right; + } + .m-center-m, [class*='m-col-m-'].m-center-m { + margin-left: auto; + margin-right: auto; + float: none; + } + .m-col-m-1 { width: calc(1 * 100% / 12); } + .m-col-m-2 { width: calc(2 * 100% / 12); } + .m-col-m-3 { width: calc(3 * 100% / 12); } + .m-col-m-4 { width: calc(4 * 100% / 12); } + .m-col-m-5 { width: calc(5 * 100% / 12); } + .m-col-m-6 { width: calc(6 * 100% / 12); } + .m-col-m-7 { width: calc(7 * 100% / 12); } + .m-col-m-8 { width: calc(8 * 100% / 12); } + .m-col-m-9 { width: calc(9 * 100% / 12); } + .m-col-m-10 { width: calc(10 * 100% / 12); } + .m-col-m-11 { width: calc(11 * 100% / 12); } + .m-col-m-12 { width: calc(12 * 100% / 12); } + .m-push-m-0 { left: calc(0 * 100% / 12); } + .m-push-m-1 { left: calc(1 * 100% / 12); } + .m-push-m-2 { left: calc(2 * 100% / 12); } + .m-push-m-3 { left: calc(3 * 100% / 12); } + .m-push-m-4 { left: calc(4 * 100% / 12); } + .m-push-m-5 { left: calc(5 * 100% / 12); } + .m-push-m-6 { left: calc(6 * 100% / 12); } + .m-push-m-7 { left: calc(7 * 100% / 12); } + .m-push-m-8 { left: calc(8 * 100% / 12); } + .m-push-m-9 { left: calc(9 * 100% / 12); } + .m-push-m-10 { left: calc(10 * 100% / 12); } + .m-push-m-11 { left: calc(11 * 100% / 12); } + .m-pull-m-0 { right: calc(0 * 100% / 12); } + .m-pull-m-1 { right: calc(1 * 100% / 12); } + .m-pull-m-2 { right: calc(2 * 100% / 12); } + .m-pull-m-3 { right: calc(3 * 100% / 12); } + .m-pull-m-4 { right: calc(4 * 100% / 12); } + .m-pull-m-5 { right: calc(5 * 100% / 12); } + .m-pull-m-6 { right: calc(6 * 100% / 12); } + .m-pull-m-7 { right: calc(7 * 100% / 12); } + .m-pull-m-8 { right: calc(8 * 100% / 12); } + .m-pull-m-9 { right: calc(9 * 100% / 12); } + .m-pull-m-10 { right: calc(10 * 100% / 12); } + .m-pull-m-11 { right: calc(11 * 100% / 12); } + .m-clearfix-s::after { display: none; } + .m-hide-m { display: none; } + .m-show-m { display: block; } + .m-col-m-none { + width: auto; + float: none; + } +} +@media screen and (min-width: 992px) { + .m-container { width: 960px; } + .m-container-inflatable .m-col-l-10 .m-container-inflate:not([class*='m-left-']):not([class*='m-right-']) { + margin-left: -10%; + margin-right: -10%; + } + .m-container-inflatable .m-col-l-10 .m-container-inflate.m-left-l { + margin-left: -10%; + } + .m-container-inflatable .m-col-l-10 .m-container-inflate.m-right-l { + margin-right: -10%; + } + [class*='m-col-l-'] { float: left; } + .m-left-l { + padding-right: 1rem; + float: left; + } + .m-right-l, [class*='m-col-l-'].m-right-l { + padding-left: 1rem; + float: right; + } + .m-center-l, [class*='m-col-l-'].m-center-l { + margin-left: auto; + margin-right: auto; + float: none; + } + .m-col-l-1 { width: calc(1 * 100% / 12); } + .m-col-l-2 { width: calc(2 * 100% / 12); } + .m-col-l-3 { width: calc(3 * 100% / 12); } + .m-col-l-4 { width: calc(4 * 100% / 12); } + .m-col-l-5 { width: calc(5 * 100% / 12); } + .m-col-l-6 { width: calc(6 * 100% / 12); } + .m-col-l-7 { width: calc(7 * 100% / 12); } + .m-col-l-8 { width: calc(8 * 100% / 12); } + .m-col-l-9 { width: calc(9 * 100% / 12); } + .m-col-l-10 { width: calc(10 * 100% / 12); } + .m-col-l-11 { width: calc(11 * 100% / 12); } + .m-col-l-12 { width: calc(12 * 100% / 12); } + .m-push-l-0 { left: calc(0 * 100% / 12); } + .m-push-l-1 { left: calc(1 * 100% / 12); } + .m-push-l-2 { left: calc(2 * 100% / 12); } + .m-push-l-3 { left: calc(3 * 100% / 12); } + .m-push-l-4 { left: calc(4 * 100% / 12); } + .m-push-l-5 { left: calc(5 * 100% / 12); } + .m-push-l-6 { left: calc(6 * 100% / 12); } + .m-push-l-7 { left: calc(7 * 100% / 12); } + .m-push-l-8 { left: calc(8 * 100% / 12); } + .m-push-l-9 { left: calc(9 * 100% / 12); } + .m-push-l-10 { left: calc(10 * 100% / 12); } + .m-push-l-11 { left: calc(11 * 100% / 12); } + .m-pull-l-0 { right: calc(0 * 100% / 12); } + .m-pull-l-1 { right: calc(1 * 100% / 12); } + .m-pull-l-2 { right: calc(2 * 100% / 12); } + .m-pull-l-3 { right: calc(3 * 100% / 12); } + .m-pull-l-4 { right: calc(4 * 100% / 12); } + .m-pull-l-5 { right: calc(5 * 100% / 12); } + .m-pull-l-6 { right: calc(6 * 100% / 12); } + .m-pull-l-7 { right: calc(7 * 100% / 12); } + .m-pull-l-8 { right: calc(8 * 100% / 12); } + .m-pull-l-9 { right: calc(9 * 100% / 12); } + .m-pull-l-10 { right: calc(10 * 100% / 12); } + .m-pull-l-11 { right: calc(11 * 100% / 12); } + .m-clearfix-m::after { display: none; } + .m-hide-l { display: none; } + .m-show-l { display: block; } + .m-col-l-none { + width: auto; + float: none; + } +} + +html { + font-size: 16px; + background-color: #2f363f; +} +body { + font-family: 'Source Sans Pro', sans-serif; + font-size: 1rem; + line-height: normal; + color: #dcdcdc; +} +h1, h2, h3, h4, h5, h6 { + margin-top: 0; + font-weight: 600; +} +h1 { + margin-bottom: 1rem; +} +h2, h3, h4, h5, h6 { + margin-bottom: 0.5rem; +} +p, ul, ol, dl { + margin-top: 0; +} +ul, ol { + padding-left: 2rem; +} +ul ol, ul ul, ol ol, ol ul { + margin-bottom: 0; +} +main p { + text-indent: 1.5rem; + text-align: justify; +} +main p.m-noindent, li > p, dd > p, table.m-table td > p { + text-indent: 0; + text-align: left; +} +blockquote { + margin-top: 0; + margin-left: 1rem; + margin-right: 1rem; + padding: 1rem; + border-left-style: solid; + border-left-width: 0.25rem; +} +hr { + width: 75%; + border-width: 0.0625rem; + border-style: solid; +} +blockquote, hr { + border-color: #405363; +} +strong, .m-text.m-strong { font-weight: bold; } +em, .m-text.m-em { font-style: italic; } +s, .m-text.m-s { text-decoration: line-through; } +sub, sup, .m-text.m-sub, .m-text.m-sup { + font-size: 0.75rem; + line-height: 0; + position: relative; + vertical-align: baseline; +} +sup, .m-text.m-sup { top: -0.35rem; } +sub, .m-text.m-sub { bottom: -0.2rem; } +abbr { + cursor: help; + text-decoration: underline dotted; +} +a { + color: #5b9dd9; +} +a.m-flat { + text-decoration: none; +} +a:hover, a:focus, a:active { + color: #a5c9ea; +} +a img { border: 0; } +svg a { cursor: pointer; } +mark { + padding: 0.0625rem; + background-color: #c7cf2f; + color: #2f83cc; +} +.m-link-wrap { + word-break: break-all; +} +pre, code { + font-family: 'Source Code Pro', monospace, monospace, monospace; + font-size: 0.9em; + color: #e6e6e6; + background-color: #282e36; +} +pre.m-console, code.m-console { + color: #e6e6e6; + background-color: #1a1c1d; +} +pre { + padding: 0.5rem 1rem; + border-radius: 0.2rem; + overflow-x: auto; + margin-top: 0; +} +pre.m-console-wrap { + white-space: pre-wrap; + word-break: break-all; +} +code { + padding: 0.125rem; +} +*:focus { outline-color: #5b9dd9; } +div.m-scroll { + max-width: 100%; + overflow-x: auto; +} +.m-fullwidth { + width: 100%; +} +.m-spacing-150 { + line-height: 1.5rem; +} +.m-text-center, .m-text-center.m-noindent, table.m-table th.m-text-center, .m-text-center p { + text-align: center; +} +.m-text-left, .m-text-left.m-noindent, table.m-table th.m-text-left, .m-text-right p { + text-align: left; +} +.m-text-right, .m-text-right.m-noindent, table.m-table th.m-text-right, .m-text-right p { + text-align: right; +} +.m-text-top, table.m-table th.m-text-top, table.m-table td.m-text-top { + vertical-align: top; +} +.m-text-middle, table.m-table th.m-text-middle, table.m-table td.m-text-middle { + vertical-align: middle; +} +.m-text-bottom, table.m-table th.m-text-bottom, table.m-table td.m-text-bottom { + vertical-align: bottom; +} +.m-text.m-tiny { font-size: 50.0%; } +.m-text.m-small { font-size: 85.4%; } +.m-text.m-big { font-size: 117%; } +h1 .m-thin, h2 .m-thin, h3 .m-thin, h4 .m-thin, h5 .m-thin, h6 .m-thin { + font-weight: normal; +} +ul.m-unstyled, ol.m-unstyled { + list-style-type: none; + padding-left: 0; +} +ul[class*='m-block-'], ol[class*='m-block-'] { + padding-left: 0; +} +ul[class*='m-block-'] li, ol[class*='m-block-'] li { + display: inline; +} +ul[class*='m-block-bar-'] li:not(:last-child)::after, ol[class*='m-block-bar-'] li:not(:last-child)::after { + content: " | "; +} +ul[class*='m-block-dot-'] li:not(:last-child)::after, ol[class*='m-block-dot-'] li:not(:last-child)::after { + content: " • "; +} +@media screen and (min-width: 576px) { + ul.m-block-bar-s, ol.m-block-bar-s, + ul.m-block-dot-s, ol.m-block-dot-s { padding-left: 2rem; } + ul.m-block-bar-s li, ol.m-block-bar-s li, + ul.m-block-dot-s li, ol.m-block-dot-s li { display: list-item; } + ul.m-block-bar-s li:not(:last-child)::after, ol.m-block-bar-s li:not(:last-child)::after, + ul.m-block-dot-s li:not(:last-child)::after, ol.m-block-dot-s li:not(:last-child)::after { content: ""; } +} +@media screen and (min-width: 768px) { + ul.m-block-bar-m, ol.m-block-bar-m, + ul.m-block-dot-m, ol.m-block-dot-m { padding-left: 2rem; } + ul.m-block-bar-m li, ol.m-block-bar-m li, + ul.m-block-dot-m li, ol.m-block-dot-m li { display: list-item; } + ul.m-block-bar-m li:not(:last-child)::after, ol.m-block-bar-m li:not(:last-child)::after, + ul.m-block-dot-m li:not(:last-child)::after, ol.m-block-dot-m li:not(:last-child)::after { content: ""; } +} +@media screen and (min-width: 992px) { + ul.m-block-bar-l, ol.m-block-bar-l, + ul.m-block-dot-l, ol.m-block-dot-l { padding-left: 2rem; } + ul.m-block-bar-l li, ol.m-block-bar-l li, + ul.m-block-dot-l li, ol.m-block-dot-l li { display: list-item; } + ul.m-block-bar-l li:not(:last-child)::after, ol.m-block-bar-l li:not(:last-child)::after, + ul.m-block-dot-l li:not(:last-child)::after, ol.m-block-dot-l li:not(:last-child)::after { content: ""; } +} +p.m-poem { + text-indent: 0; + text-align: left; + margin-left: 1.5rem; +} +p.m-transition { + color: #405363; + text-indent: 0; + text-align: center; + font-size: 2rem; +} +dl.m-diary { + margin-bottom: 1.25rem; +} +dl.m-diary:last-child { + margin-bottom: 0.25rem; +} +dl.m-diary dt { + font-weight: bold; + width: 6rem; + float: left; + clear: both; + padding-top: 0.25rem; +} +dl.m-diary dd { + padding-top: 0.25rem; + padding-left: 6rem; + margin-left: 0; +} +a.m-footnote, dl.m-footnote dd span.m-footnote { + top: -0.35rem; + font-size: 0.75rem; + line-height: 0; + position: relative; + vertical-align: baseline; +} +a.m-footnote, dl.m-footnote dd span.m-footnote a { + text-decoration: none; +} +a.m-footnote::before { content: '['; } +a.m-footnote::after { content: ']'; } +dl.m-footnote dt { + width: 1.5rem; + float: left; + clear: both; +} +dl.m-footnote dd { + margin-left: 1.5rem; +} +dl.m-footnote { + font-size: 85.4%; +} +dl.m-footnote dd span.m-footnote a { + font-weight: bold; + font-style: italic; +} +.m-note { + border-radius: 0.2rem; + padding: 1rem; +} +.m-frame { + background-color: #2f363f; + border-style: solid; + border-width: 0.125rem; + border-radius: 0.2rem; + border-color: #405363; + padding: 0.875rem; +} +.m-block { + border-style: solid; + border-width: 0.0625rem; + border-left-width: 0.25rem; + border-radius: 0.2rem; + border-color: #405363; + padding: 0.9375rem 0.9375rem 0.9375rem 0.75rem; +} +.m-block.m-badge::after { + content: ' '; + display: block; + clear: both; +} +.m-block.m-badge h3 { + margin-left: 5rem; +} +.m-block.m-badge p { + margin-left: 5rem; + text-indent: 0; +} +.m-block.m-badge img { + width: 4rem; + height: 4rem; + border-radius: 2rem; + float: left; +} +div.m-button { + text-align: center; +} +div.m-button a { + display: inline-block; + border-radius: 0.2rem; + padding-top: 0.75rem; + padding-bottom: 0.75rem; + padding-left: 1.5rem; + padding-right: 1.5rem; + text-decoration: none; + font-size: 1.17rem; +} +div.m-button.m-fullwidth a { + display: block; + padding-left: 0.5rem; + padding-right: 0.5rem; +} +div.m-button a .m-big:first-child { + font-size: 1.37rem; + font-weight: bold; +} +div.m-button a .m-small:last-child { + font-size: 0.854rem; +} +.m-label { + border-radius: 0.2rem; + font-size: 75%; + font-weight: normal; + padding: 0.125rem 0.25rem; + vertical-align: 7.5%; +} +.m-label.m-flat { + border-width: 0.0625rem; + border-style: solid; + border-color: #747474; + padding: 0.0625rem 0.1875rem; +} +table.m-table { + border-collapse: collapse; + margin-left: auto; + margin-right: auto; +} +table.m-table.m-big { + margin-top: 1.75rem; +} +div.m-scroll > table.m-table:last-child { + margin-bottom: 0.0625rem; +} +table.m-table:not(.m-flat) tbody tr:hover { + background-color: #405363; +} +table.m-table th, table.m-table td { + vertical-align: top; + border-style: solid; + border-top-width: 0.0625rem; + border-left-width: 0; + border-right-width: 0; + border-bottom-width: 0; + border-color: #405363; +} +table.m-table caption { + padding-bottom: 0.5rem; +} +table.m-table thead tr:first-child th, table.m-table thead tr:first-child td { + border-top-width: 0.125rem; +} +table.m-table thead th, table.m-table thead td { + border-bottom-width: 0.125rem; + vertical-align: bottom; +} +table.m-table tfoot th, table.m-table tfoot td { + border-top-width: 0.125rem; +} +table.m-table th, table.m-table td { + padding: 0.5rem; +} +table.m-table.m-big th, table.m-table.m-big td { + padding: 0.75rem 1rem; +} +table.m-table th { + text-align: left; +} +table.m-table th.m-thin { + font-weight: normal; +} +table.m-table td.m-default, table.m-table th.m-default, +table.m-table td.m-primary, table.m-table th.m-primary, +table.m-table td.m-success, table.m-table th.m-success, +table.m-table td.m-warning, table.m-table th.m-warning, +table.m-table td.m-danger, table.m-table th.m-danger, +table.m-table td.m-info, table.m-table th.m-info, +table.m-table td.m-dim, table.m-table th.m-dim { + padding-left: 0.4375rem; + padding-right: 0.4375rem; + border-left-width: 0.0625rem; +} +table.m-table.m-big td.m-default, table.m-table.m-big th.m-default, +table.m-table.m-big td.m-primary, table.m-table.m-big th.m-primary, +table.m-table.m-big td.m-success, table.m-table.m-big th.m-success, +table.m-table.m-big td.m-warning, table.m-table.m-big th.m-warning, +table.m-table.m-big td.m-danger, table.m-table.m-big th.m-danger, +table.m-table.m-big td.m-info, table.m-table.m-big th.m-info, +table.m-table.m-big td.m-dim, table.m-table.m-big th.m-dim { + padding-left: 0.9375rem; + padding-right: 0.9375rem; + border-left-width: 0.0625rem; +} +table.m-table tr.m-default td, table.m-table td.m-default, +table.m-table tr.m-default th, table.m-table th.m-default, +table.m-table tr.m-primary td, table.m-table td.m-primary, +table.m-table tr.m-primary th, table.m-table th.m-primary, +table.m-table tr.m-success td, table.m-table td.m-success, +table.m-table tr.m-success th, table.m-table th.m-success, +table.m-table tr.m-warning td, table.m-table td.m-warning, +table.m-table tr.m-warning th, table.m-table th.m-warning, +table.m-table tr.m-danger td, table.m-table td.m-danger, +table.m-table tr.m-danger th, table.m-table th.m-danger, +table.m-table tr.m-info td, table.m-table td.m-info, +table.m-table tr.m-info th, table.m-table th.m-info, +table.m-table tr.m-dim td, table.m-table td.m-dim, +table.m-table tr.m-dim th, table.m-table th.m-dim { + border-color: #2f363f; +} +.m-note pre, .m-note code, +table.m-table tr.m-default pre, table.m-table tr.m-default code, +table.m-table td.m-default pre, table.m-table td.m-default code, +table.m-table th.m-default pre, table.m-table th.m-default code, +table.m-table tr.m-primary pre, table.m-table tr.m-primary code, +table.m-table td.m-primary pre, table.m-table td.m-primary code, +table.m-table th.m-primary pre, table.m-table th.m-primary code, +table.m-table tr.m-success pre, table.m-table tr.m-success code, +table.m-table td.m-success pre, table.m-table td.m-success code, +table.m-table th.m-success pre, table.m-table th.m-success code, +table.m-table tr.m-warning pre, table.m-table tr.m-warning code, +table.m-table td.m-warning pre, table.m-table td.m-warning code, +table.m-table th.m-warning pre, table.m-table th.m-warning code, +table.m-table tr.m-danger pre, table.m-table tr.m-danger code, +table.m-table td.m-danger pre, table.m-table td.m-danger code, +table.m-table th.m-danger pre, table.m-table th.m-danger code, +table.m-table tr.m-info pre, table.m-table tr.m-info code, +table.m-table td.m-info pre, table.m-table td.m-info code, +table.m-table th.m-info pre, table.m-table th.m-info code, +table.m-table tr.m-dim pre, table.m-table tr.m-dim code, +table.m-table td.m-dim pre, table.m-table td.m-dim code, +table.m-table th.m-dim pre, table.m-table th.m-dim code { + background-color: rgba(34, 39, 46, 0.5); +} +img.m-image, svg.m-image { + display: block; + margin-left: auto; + margin-right: auto; +} +div.m-image { + text-align: center; +} +img.m-image, svg.m-image, div.m-image img, div.m-image svg { + max-width: 100%; + border-radius: 0.2rem; +} +div.m-image.m-fullwidth img, div.m-image.m-fullwidth svg { + width: 100%; +} +img.m-image.m-badge, div.m-image.m-badge img { + border-radius: 50%; +} +figure.m-figure { + max-width: 100%; + margin-top: 0; + margin-left: auto; + margin-right: auto; + position: relative; + display: table; +} +figure.m-figure:before { + position: absolute; + content: ' '; + top: 0; + bottom: 0; + left: 0; + right: 0; + z-index: -1; + border-style: solid; + border-width: 0.125rem; + border-radius: 0.2rem; + border-color: #405363; +} +figure.m-figure.m-flat:before { + border-color: transparent; +} +figure.m-figure > * { + margin-left: 1rem; + margin-right: 1rem; + display: table-caption; + caption-side: bottom; +} +figure.m-figure > *:first-child { + display: inline; +} +figure.m-figure > *:last-child { + margin-bottom: 1rem !important; +} +figure.m-figure img, figure.m-figure svg { + position: relative; + margin-left: 0; + margin-right: 0; + margin-bottom: 0; + border-top-left-radius: 0.2rem; + border-top-right-radius: 0.2rem; + max-width: 100%; +} +figure.m-figure.m-flat img, figure.m-figure.m-flat svg { + border-bottom-left-radius: 0.2rem; + border-bottom-right-radius: 0.2rem; +} +figure.m-figure a img, figure.m-figure a svg { + margin-left: -1rem; + margin-right: -1rem; +} +figure.m-figure.m-fullwidth, figure.m-figure.m-fullwidth > * { + display: block; +} +figure.m-figure.m-fullwidth > *:first-child { + display: inline; +} +figure.m-figure.m-fullwidth img, figure.m-figure.m-fullwidth svg { + width: 100%; +} +figure.m-figure.m-fullwidth:after { + content: ' '; + display: block; + margin-top: 1rem; + height: 1px; +} +.m-code-figure, .m-console-figure { + margin-top: 0; + margin-left: 0; + margin-right: 0; + position: relative; + padding: 1rem; +} +.m-code-figure:before, .m-console-figure:before { + position: absolute; + content: ' '; + top: 0; + bottom: 0; + left: 0; + right: 0; + z-index: -1; + border-style: solid; + border-width: 0.125rem; + border-radius: 0.2rem; +} +.m-code-figure:before { + border-color: #282e36; +} +.m-console-figure:before { + border-color: #1a1c1d; +} +.m-code-figure.m-flat:before, .m-console-figure.m-flat:before { + border-color: transparent; +} +.m-code-figure > pre:first-child, .m-console-figure > pre:first-child { + position: relative; + margin: -1rem -1rem 1rem -1rem; + border-bottom-left-radius: 0; + border-bottom-right-radius: 0; +} +.m-code-figure > pre.m-nopad, .m-console-figure > pre.m-nopad { + margin-left: -0.875rem; + margin-right: -0.875rem; + margin-top: -1rem; + margin-bottom: -0.875rem; + padding-left: 0.875rem; +} +figure.m-figure figcaption, .m-code-figure figcaption, .m-console-figure figcaption { + margin-top: 0.5rem; + margin-bottom: 0.5rem; + font-weight: 600; + font-size: 1.17rem; +} +.m-imagegrid > div { + background-color: #2f363f; +} +.m-imagegrid > div > figure { + display: block; + float: left; + position: relative; + margin: 0; +} +.m-imagegrid > div > figure > div, +.m-imagegrid > div > figure > figcaption, +.m-imagegrid > div > figure > a > div, +.m-imagegrid > div > figure > a > figcaption { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + border-color: #2f363f; + border-style: solid; + border-width: 0.25rem; + padding: 0.5rem; +} +.m-imagegrid > div > figure:first-child > div, +.m-imagegrid > div > figure:first-child > figcaption, +.m-imagegrid > div > figure:first-child > a > div, +.m-imagegrid > div > figure:first-child > a > figcaption { + border-left-width: 0; +} +.m-imagegrid > div > figure:last-child > div, +.m-imagegrid > div > figure:last-child > figcaption, +.m-imagegrid > div > figure:last-child > a > div, +.m-imagegrid > div > figure:last-child > a > figcaption { + border-right-width: 0; +} +.m-imagegrid > div > figure > figcaption, +.m-imagegrid > div > figure > a > figcaption { + color: transparent; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + font-size: 0.75rem; +} +.m-imagegrid > div > figure > div::before, +.m-imagegrid > div > figure > figcaption::before, +.m-imagegrid > div > figure > a > div::before, +.m-imagegrid > div > figure > a > figcaption::before { + content: ''; + display: inline-block; + height: 100%; + vertical-align: bottom; + width: 0; +} +.m-imagegrid > div > figure:hover > figcaption, +.m-imagegrid > div > figure:hover > a > figcaption { + background: linear-gradient(transparent 0%, transparent 75%, rgba(0, 0, 0, 0.85) 100%); + color: #ffffff; +} +.m-imagegrid > div > figure > img, +.m-imagegrid > div > figure > a > img { + width: 100%; + height: 100%; +} +.m-imagegrid > div::after { + display: block; + content: ' '; + clear: both; +} +@media screen and (max-width: 767px) { + .m-imagegrid > div > figure { + float: none; + width: 100% !important; + } + .m-imagegrid > div > figure > div, + .m-imagegrid > div > figure > figcaption, + .m-imagegrid > div > figure > a > div, + .m-imagegrid > div > figure > a > figcaption { + border-left-width: 0; + border-right-width: 0; + } +} +.m-container-inflatable > .m-row > [class*='m-col-'] > .m-note, +.m-container-inflatable > .m-row > [class*='m-col-'] > .m-frame, +.m-container-inflatable > .m-row > [class*='m-col-'] > .m-block, +.m-container-inflatable > .m-row > [class*='m-col-'] > .m-imagegrid, +.m-container-inflatable > .m-row > [class*='m-col-'] > pre, +.m-container-inflatable > .m-row > [class*='m-col-'] > .m-code-figure, +.m-container-inflatable > .m-row > [class*='m-col-'] > .m-console-figure, +.m-container-inflatable > .m-row > [class*='m-col-'] section > .m-note, +.m-container-inflatable > .m-row > [class*='m-col-'] section > .m-frame, +.m-container-inflatable > .m-row > [class*='m-col-'] section > .m-block, +.m-container-inflatable > .m-row > [class*='m-col-'] section > .m-imagegrid, +.m-container-inflatable > .m-row > [class*='m-col-'] section > pre, +.m-container-inflatable > .m-row > [class*='m-col-'] section > .m-code-figure, +.m-container-inflatable > .m-row > [class*='m-col-'] section > .m-console-figure, +.m-container-inflatable [class*='m-center-'] > .m-note, +.m-container-inflatable [class*='m-center-'] > .m-frame, +.m-container-inflatable [class*='m-center-'] > .m-block, +.m-container-inflatable [class*='m-center-'] > .m-imagegrid, +.m-container-inflatable [class*='m-center-'] > pre, +.m-container-inflatable [class*='m-center-'] > .m-code-figure, +.m-container-inflatable [class*='m-center-'] > .m-console-figure, +.m-container-inflatable [class*='m-left-'] > .m-note, +.m-container-inflatable [class*='m-left-'] > .m-frame, +.m-container-inflatable [class*='m-left-'] > .m-block, +.m-container-inflatable [class*='m-left-'] > .m-imagegrid, +.m-container-inflatable [class*='m-left-'] > pre, +.m-container-inflatable [class*='m-left-'] > .m-code-figure, +.m-container-inflatable [class*='m-left-'] > .m-console-figure, +.m-container-inflatable [class*='m-right-'] > .m-note, +.m-container-inflatable [class*='m-right-'] > .m-frame, +.m-container-inflatable [class*='m-right-'] > .m-block, +.m-container-inflatable [class*='m-right-'] > .m-imagegrid, +.m-container-inflatable [class*='m-right-'] > pre, +.m-container-inflatable [class*='m-right-'] > .m-code-figure, +.m-container-inflatable [class*='m-right-'] > .m-console-figure, +.m-container-inflatable .m-container-inflate > .m-note, +.m-container-inflatable .m-container-inflate > .m-frame, +.m-container-inflatable .m-container-inflate > .m-block, +.m-container-inflatable .m-container-inflate > .m-imagegrid, +.m-container-inflatable .m-container-inflate > pre, +.m-container-inflatable .m-container-inflate > .m-code-figure, +.m-container-inflatable .m-container-inflate > .m-console-figure +{ + margin-left: -1rem; + margin-right: -1rem; +} +@media screen and (min-width: 576px) { + .m-container-inflatable .m-center-s > .m-note, + .m-container-inflatable .m-center-s > .m-frame, + .m-container-inflatable .m-center-s > .m-block, + .m-container-inflatable .m-center-s > .m-imagegrid, + .m-container-inflatable .m-center-s > pre, + .m-container-inflatable .m-center-s > .m-code-figure, + .m-container-inflatable .m-center-s > .m-console-figure { + margin-left: -1rem; + margin-right: -1rem; + } + .m-container-inflatable .m-left-s > .m-note, + .m-container-inflatable .m-left-s > .m-frame, + .m-container-inflatable .m-left-s > .m-block, + .m-container-inflatable .m-left-s > .m-imagegrid, + .m-container-inflatable .m-left-s > pre, + .m-container-inflatable .m-left-s > .m-code-figure, + .m-container-inflatable .m-left-s > .m-console-figure { + margin-left: -1rem; + margin-right: 0; + } + .m-container-inflatable .m-right-s > .m-note, + .m-container-inflatable .m-right-s > .m-frame, + .m-container-inflatable .m-right-s > .m-block, + .m-container-inflatable .m-right-s > .m-imagegrid, + .m-container-inflatable .m-right-s > pre, + .m-container-inflatable .m-right-s > .m-code-figure, + .m-container-inflatable .m-right-s > .m-console-figure { + margin-left: 0; + margin-right: -1rem; + } + .m-container-inflatable > .m-row > .m-col-s-10 > .m-imagegrid.m-container-inflate, + .m-container-inflatable > .m-row > .m-col-s-10 section > .m-imagegrid.m-container-inflate { + margin-left: -10%; + margin-right: -10%; + } +} +@media screen and (min-width: 768px) { + .m-container-inflatable .m-center-m > .m-note, + .m-container-inflatable .m-center-m > .m-frame, + .m-container-inflatable .m-center-m > .m-block, + .m-container-inflatable .m-center-m > .m-imagegrid, + .m-container-inflatable .m-center-m > pre, + .m-container-inflatable .m-center-m > .m-code-figure, + .m-container-inflatable .m-center-m > .m-console-figure { + margin-left: -1rem; + margin-right: -1rem; + } + .m-container-inflatable .m-left-m > .m-note, + .m-container-inflatable .m-left-m > .m-frame, + .m-container-inflatable .m-left-m > .m-block, + .m-container-inflatable .m-left-m > .m-imagegrid, + .m-container-inflatable .m-left-m > pre, + .m-container-inflatable .m-left-m > .m-code-figure, + .m-container-inflatable .m-left-m > .m-console-figure { + margin-left: -1rem; + margin-right: 0; + } + .m-container-inflatable .m-right-m > .m-note, + .m-container-inflatable .m-right-m > .m-frame, + .m-container-inflatable .m-right-m > .m-block, + .m-container-inflatable .m-right-m > .m-imagegrid, + .m-container-inflatable .m-right-m > pre, + .m-container-inflatable .m-right-m > .m-code-figure, + .m-container-inflatable .m-right-m > .m-console-figure { + margin-left: 0; + margin-right: -1rem; + } + .m-container-inflatable > .m-row > .m-col-m-10 > .m-imagegrid.m-container-inflate, + .m-container-inflatable > .m-row > .m-col-m-10 section > .m-imagegrid.m-container-inflate { + margin-left: -10%; + margin-right: -10%; + } +} +@media screen and (min-width: 992px) { + .m-container-inflatable .m-center-l > .m-note, + .m-container-inflatable .m-center-l > .m-frame, + .m-container-inflatable .m-center-l > .m-block, + .m-container-inflatable .m-center-l > .m-imagegrid, + .m-container-inflatable .m-center-l > pre, + .m-container-inflatable .m-center-l > .m-code-figure, + .m-container-inflatable .m-center-l > .m-console-figure { + margin-left: -1rem; + margin-right: -1rem; + } + .m-container-inflatable .m-left-l > .m-note, + .m-container-inflatable .m-left-l > .m-frame, + .m-container-inflatable .m-left-l > .m-block, + .m-container-inflatable .m-left-l > .m-imagegrid, + .m-container-inflatable .m-left-l > pre, + .m-container-inflatable .m-left-l > .m-code-figure, + .m-container-inflatable .m-left-l > .m-console-figure { + margin-left: -1rem; + margin-right: 0; + } + .m-container-inflatable .m-right-l > .m-note, + .m-container-inflatable .m-right-l > .m-frame, + .m-container-inflatable .m-right-l > .m-block, + .m-container-inflatable .m-right-l > .m-imagegrid, + .m-container-inflatable .m-right-l > pre, + .m-container-inflatable .m-right-l > .m-code-figure, + .m-container-inflatable .m-right-l > .m-console-figure { + margin-left: 0; + margin-right: -1rem; + } + .m-container-inflatable > .m-row > .m-col-l-10 > .m-imagegrid.m-container-inflate, + .m-container-inflatable > .m-row > .m-col-l-10 section > .m-imagegrid.m-container-inflate { + margin-left: -10%; + margin-right: -10%; + } +} +pre.m-code span.hll { + margin-left: -1.0rem; + margin-right: -1.0rem; + padding-left: 1.0rem; +} +.m-code.m-inverted > span, .m-console.m-inverted > span { + opacity: 0.3333; +} +.m-code.m-inverted > span.hll, .m-console.m-inverted > span.hll { + opacity: 1; + background-color: transparent; + border-color: transparent; +} +.m-code.m-inverted { color: rgba(230, 230, 230, 0.33); } +.m-console.m-inverted { color: rgba(230, 230, 230, 0.33); } +.m-code.m-inverted > span.hll { color: #e6e6e6; } +.m-cosole.m-inverted > span.hll { color: #e6e6e6; } +.m-code-color { + display: inline-block; + width: 0.75rem; + height: 0.75rem; + vertical-align: -0.05rem; + margin-left: 0.2rem; + margin-right: 0.1rem; + border-radius: 0.1rem; +} +div.m-math { + overflow-x: auto; + overflow-y: hidden; +} +div.m-math svg { + margin-left: auto; + margin-right: auto; + display: block; +} +div.m-button a svg.m-math { fill: #22272e; } +div.m-button.m-flat a svg.m-math { fill: #dcdcdc; } +div.m-button.m-flat a:hover svg.m-math, div.m-button.m-default a:focus svg.m-math, +div.m-button.m-default a:active svg.m-math { + fill: #a5c9ea; +} +.m-graph { font-size: 16px; } +div.m-plot svg, div.m-graph svg { + max-width: 100%; + margin-left: auto; + margin-right: auto; + display: block; +} +div.m-plot .m-background { fill: #34424d; } +div.m-plot svg .m-label { font-size: 11px; } +div.m-plot svg .m-title { font-size: 13px; } +div.m-plot svg .m-label, div.m-plot svg .m-title { fill: #dcdcdc; } +div.m-plot svg .m-line { + stroke: #dcdcdc; + stroke-width: 0.8; +} +div.m-plot svg .m-error { + stroke: #ffffff; + stroke-width: 1.5; +} +div.m-plot svg .m-label.m-dim { fill: #747474; } +.m-graph g.m-edge path, .m-graph g.m-node.m-flat ellipse, +.m-graph g.m-node.m-flat polygon { + fill: none; +} +.m-graph g.m-node:not(.m-flat) text { + fill: #22272e; +} +figure.m-figure > svg.m-math:first-child, +figure.m-figure > svg.m-graph:first-child { + padding: 1rem; + box-sizing: content-box; +} +figure.m-figure:not(.m-flat) > svg.m-math:first-child, +figure.m-figure:not(.m-flat) > svg.m-graph:first-child { + background-color: #405363; +} +.m-block.m-default { border-left-color: #405363; } +.m-block.m-default h3, .m-block.m-default h4, .m-block.m-default h5, .m-block.m-default h6, +.m-text.m-default, .m-label.m-flat.m-default { + color: #dcdcdc; +} +.m-block.m-default h3 a, .m-block.m-default h4 a, .m-block.m-default h5 a, .m-block.m-default h6 a { + color: #5b9dd9; +} +.m-block.m-primary { border-left-color: #a5c9ea; } +.m-block.m-primary h3, .m-block.m-primary h4, .m-block.m-primary h5, .m-block.m-primary h6, +.m-block.m-primary h3 a, .m-block.m-primary h4 a, .m-block.m-primary h5 a, .m-block.m-primary h6 a, +.m-text.m-primary, .m-label.m-flat.m-primary { + color: #a5c9ea; +} +.m-block.m-success { border-left-color: #3bd267; } +.m-block.m-success h3, .m-block.m-success h4, .m-block.m-success h5, .m-block.m-success h6, +.m-block.m-success h3 a, .m-block.m-success h4 a, .m-block.m-success h5 a, .m-block.m-success h6 a, +.m-text.m-success, .m-label.m-flat.m-success { + color: #3bd267; +} +.m-block.m-warning { border-left-color: #c7cf2f; } +.m-block.m-warning h3, .m-block.m-warning h4, .m-block.m-warning h5, .m-block.m-warning h6, +.m-block.m-warning h3 a, .m-block.m-warning h4 a, .m-block.m-warning h5 a, .m-block.m-warning h6 a, +.m-text.m-warning, .m-label.m-flat.m-warning { + color: #c7cf2f; +} +.m-block.m-danger { border-left-color: #cd3431; } +.m-block.m-danger h3, .m-block.m-danger h4, .m-block.m-danger h5, .m-block.m-danger h6, +.m-block.m-danger h3 a, .m-block.m-danger h4 a, .m-block.m-danger h5 a, .m-block.m-danger h6 a, +.m-text.m-danger, .m-label.m-flat.m-danger { + color: #cd3431; +} +.m-block.m-info { border-left-color: #2f83cc; } +.m-block.m-info h3, .m-block.m-info h4, .m-block.m-info h5, .m-block.m-info h6, +.m-block.m-info h3 a, .m-block.m-info h4 a, .m-block.m-info h5 a, .m-block.m-info h6 a, +.m-text.m-info, .m-label.m-flat.m-info { + color: #2f83cc; +} +.m-block.m-dim { border-left-color: #747474; } +.m-block.m-dim, .m-text.m-dim, .m-label.m-flat.m-dim { + color: #747474; +} +.m-block.m-dim a, .m-text.m-dim a { color: #acacac; } +.m-block.m-dim a:hover, .m-block.m-dim a:focus, .m-block.m-dim a:active, +.m-text.m-dim a:hover, .m-text.m-dim a:focus, .m-text.m-dim a:active { + color: #747474; +} +.m-block.m-flat { border-color: transparent; } +.m-block.m-flat h3, .m-block.m-flat h4, .m-block.m-flat h5, .m-block.m-flat h6 { + color: #dcdcdc; +} +.m-block.m-default h3 a:hover, .m-block.m-default h3 a:focus, .m-block.m-default h3 a:active, +.m-block.m-default h4 a:hover, .m-block.m-default h4 a:focus, .m-block.m-default h4 a:active, +.m-block.m-default h5 a:hover, .m-block.m-default h5 a:focus, .m-block.m-default h5 a:active, +.m-block.m-default h6 a:hover, .m-block.m-default h6 a:focus, .m-block.m-default h6 a:active { + color: #a5c9ea; +} +.m-block.m-primary h3 a:hover, .m-block.m-primary h3 a:focus, .m-block.m-primary h3 a:active, +.m-block.m-primary h4 a:hover, .m-block.m-primary h4 a:focus, .m-block.m-primary h4 a:active, +.m-block.m-primary h5 a:hover, .m-block.m-primary h5 a:focus, .m-block.m-primary h5 a:active, +.m-block.m-primary h6 a:hover, .m-block.m-primary h6 a:focus, .m-block.m-primary h6 a:active { + color: #dcdcdc; +} +.m-block.m-success h3 a:hover, .m-block.m-success h3 a:focus, .m-block.m-success h3 a:active, +.m-block.m-success h4 a:hover, .m-block.m-success h4 a:focus, .m-block.m-success h4 a:active, +.m-block.m-success h5 a:hover, .m-block.m-success h5 a:focus, .m-block.m-success h5 a:active, +.m-block.m-success h6 a:hover, .m-block.m-success h6 a:focus, .m-block.m-success h6 a:active { + color: #acecbe; +} +.m-block.m-warning h3 a:hover, .m-block.m-warning h3 a:focus, .m-block.m-warning h3 a:active, +.m-block.m-warning h4 a:hover, .m-block.m-warning h4 a:focus, .m-block.m-warning h4 a:active, +.m-block.m-warning h5 a:hover, .m-block.m-warning h5 a:focus, .m-block.m-warning h5 a:active, +.m-block.m-warning h6 a:hover, .m-block.m-warning h6 a:focus, .m-block.m-warning h6 a:active { + color: #e9ecae; +} +.m-block.m-danger h3 a:hover, .m-block.m-danger h3 a:focus, .m-block.m-danger h3 a:active, +.m-block.m-danger h4 a:hover, .m-block.m-danger h4 a:focus, .m-block.m-danger h4 a:active, +.m-block.m-danger h5 a:hover, .m-block.m-danger h5 a:focus, .m-block.m-danger h5 a:active, +.m-block.m-danger h6 a:hover, .m-block.m-danger h6 a:focus, .m-block.m-danger h6 a:active { + color: #ff9391; +} +.m-block.m-info h3 a:hover, .m-block.m-info h3 a:focus, .m-block.m-info h3 a:active, +.m-block.m-info h4 a:hover, .m-block.m-info h4 a:focus, .m-block.m-info h4 a:active, +.m-block.m-info h5 a:hover, .m-block.m-info h5 a:focus, .m-block.m-info h5 a:active, +.m-block.m-info h6 a:hover, .m-block.m-info h6 a:focus, .m-block.m-info h6 a:active { + color: #5297d7; +} +div.m-button a, .m-label { color: #22272e; } +div.m-button.m-flat a { color: #dcdcdc; } +div.m-button.m-flat a:hover, div.m-button.m-default a:focus, div.m-button.m-default a:active { + color: #a5c9ea; +} +div.m-button.m-default a, .m-label:not(.m-flat).m-default { background-color: #dcdcdc; } +div.m-button.m-primary a, .m-label:not(.m-flat).m-primary { background-color: #a5c9ea; } +div.m-button.m-success a, .m-label:not(.m-flat).m-success { background-color: #3bd267; } +div.m-button.m-warning a, .m-label:not(.m-flat).m-warning { background-color: #c7cf2f; } +div.m-button.m-danger a, .m-label:not(.m-flat).m-danger { background-color: #cd3431; } +div.m-button.m-info a, .m-label:not(.m-flat).m-info { background-color: #2f83cc; } +div.m-button.m-dim a, .m-label:not(.m-flat).m-dim { background-color: #747474; } +div.m-button.m-default a:hover, div.m-button.m-default a:focus, div.m-button.m-default a:active { + background-color: #a5c9ea; +} +div.m-button.m-primary a:hover, div.m-button.m-primary a:focus, div.m-button.m-primary a:active { + background-color: #dcdcdc; +} +div.m-button.m-success a:hover, div.m-button.m-success a:focus, div.m-button.m-success a:active { + background-color: #acecbe; +} +div.m-button.m-warning a:hover, div.m-button.m-warning a:focus, div.m-button.m-warning a:active { + background-color: #e9ecae; +} +div.m-button.m-danger a:hover, div.m-button.m-danger a:focus, div.m-button.m-danger a:active { + background-color: #ff9391; +} +div.m-button.m-info a:hover, div.m-button.m-info a:focus, div.m-button.m-info a:active { + background-color: #5297d7; +} +div.m-button.m-dim a:hover, div.m-button.m-dim a:focus, div.m-button.m-dim a:active { + background-color: #acacac; +} +.m-note.m-default { background-color: #34424d; } +.m-note.m-default, +table.m-table tr.m-default td, table.m-table td.m-default, +table.m-table tr.m-default th, table.m-table th.m-default { + color: #dcdcdc; +} +.m-note.m-default a:hover, +table.m-table tr.m-default td a:hover, table.m-table td.m-default a:hover, +table.m-table tr.m-default th a:hover, table.m-table th.m-default a:hover, +.m-note.m-default a:focus, +table.m-table tr.m-default td a:focus, table.m-table td.m-default a:focus, +table.m-table tr.m-default th a:focus, table.m-table th.m-default a:focus, +.m-note.m-default a:active, +table.m-table tr.m-default td a:active, table.m-table td.m-default a:active, +table.m-table tr.m-default th a:active, table.m-table th.m-default a:active { + color: #a5c9ea; +} +.m-note.m-primary a, +table.m-table tr.m-primary td a, table.m-table td.m-primary a, +table.m-table tr.m-primary th a, table.m-table th.m-primary a { + color: #5b9dd9; +} +.m-note.m-primary, +table.m-table tr.m-primary td, table.m-table td.m-primary, +table.m-table tr.m-primary th, table.m-table th.m-primary { + background-color: #a5c2db; + color: #2f363f; +} +.m-note.m-primary a, +table.m-table tr.m-primary td a, table.m-table td.m-primary a, +table.m-table tr.m-primary th a, table.m-table th.m-primary a { + color: #2a75b6; +} +.m-note.m-primary a:hover, +table.m-table tr.m-primary td a:hover, table.m-table td.m-primary a:hover, +table.m-table tr.m-primary th a:hover, table.m-table th.m-primary a:hover, +.m-note.m-primary a:focus, +table.m-table tr.m-primary td a:focus, table.m-table td.m-primary a:focus, +table.m-table tr.m-primary th a:focus, table.m-table th.m-primary a:focus, +.m-note.m-primary a:active, +table.m-table tr.m-primary td a:active, table.m-table td.m-primary a:active, +table.m-table tr.m-primary th a:active, table.m-table th.m-primary a:active { + color: #2f363f; +} +.m-note.m-success, +table.m-table tr.m-success td, table.m-table td.m-success, +table.m-table tr.m-success th, table.m-table th.m-success { + background-color: #2a703f; + color: #acecbe; +} +.m-note.m-success a, +table.m-table tr.m-success td a, table.m-table td.m-success a, +table.m-table tr.m-success th a, table.m-table th.m-success a { + color: #3bd267; +} +.m-note.m-success a:hover, +table.m-table tr.m-success td a:hover, table.m-table td.m-success a:hover, +table.m-table tr.m-success th a:hover, table.m-table th.m-success a:hover, +.m-note.m-success a:focus, +table.m-table tr.m-success td a:focus, table.m-table td.m-success a:focus, +table.m-table tr.m-success th a:focus, table.m-table th.m-success a:focus, +.m-note.m-success a:active, +table.m-table tr.m-success td a:active, table.m-table td.m-success a:active, +table.m-table tr.m-success th a:active, table.m-table th.m-success a:active { + color: #acecbe; +} +.m-note.m-warning, table.m-table tr.m-warning td, table.m-table td.m-warning, + table.m-table tr.m-warning th, table.m-table th.m-warning { + background-color: #6d702a; + color: #e9ecae; +} +.m-note.m-warning a, table.m-table tr.m-warning td a, table.m-table td.m-warning a, + table.m-table tr.m-warning th a, table.m-table th.m-warning a { + color: #b8bf2b; +} +.m-note.m-warning a:hover, +table.m-table tr.m-warning td a:hover, table.m-table td.m-warning a:hover, +table.m-table tr.m-warning th a:hover, table.m-table th.m-warning a:hover, +.m-note.m-warning a:focus, +table.m-table tr.m-warning td a:focus, table.m-table td.m-warning a:focus, +table.m-table tr.m-warning th a:focus, table.m-table th.m-warning a:focus, +.m-note.m-warning a:active, +table.m-table tr.m-warning td a:active, table.m-table td.m-warning a:active, +table.m-table tr.m-warning th a:active, table.m-table th.m-warning a:active { + color: #e9ecae; +} +.m-note.m-danger, +table.m-table tr.m-danger td, table.m-table td.m-danger, +table.m-table tr.m-danger th, table.m-table th.m-danger { + background-color: #702b2a; + color: #ff9391; +} +.m-note.m-danger a, +table.m-table tr.m-danger td a, table.m-table td.m-danger a, +table.m-table tr.m-danger th a, table.m-table th.m-danger a { + color: #d85c59; +} +.m-note.m-danger a:hover, +table.m-table tr.m-danger td a:hover, table.m-table td.m-danger a:hover, +table.m-table tr.m-danger th a:hover, table.m-table th.m-danger a:hover, +.m-note.m-danger a:focus, +table.m-table tr.m-danger td a:focus, table.m-table td.m-danger a:focus, +table.m-table tr.m-danger th a:focus, table.m-table th.m-danger a:focus, +.m-note.m-danger a:active, +table.m-table tr.m-danger td a:active, table.m-table td.m-danger a:active, +table.m-table tr.m-danger th a:active, table.m-table th.m-danger a:active { + color: #ff9391; +} +.m-note.m-info, +table.m-table tr.m-info td, table.m-table td.m-info, +table.m-table tr.m-info th, table.m-table th.m-info { + background-color: #2a4f70; + color: #a5caeb; +} +.m-note.m-info a, +table.m-table tr.m-info td a, table.m-table td.m-info a, +table.m-table tr.m-info th a, table.m-table th.m-info a { + color: #5297d7; +} +.m-note.m-info a:hover, +table.m-table tr.m-info td a:hover, table.m-table td.m-info a:hover, +table.m-table tr.m-info th a:hover, table.m-table th.m-info a:hover, +.m-note.m-info a:focus, +table.m-table tr.m-info td a:focus, table.m-table td.m-info a:focus, +table.m-table tr.m-info th a:focus, table.m-table th.m-info a:focus, +.m-note.m-info a:active, +table.m-table tr.m-info td a:active, table.m-table td.m-info a:active, +table.m-table tr.m-info th a:active, table.m-table th.m-info a:active { + color: #a5caeb; +} +.m-note.m-dim, +table.m-table tr.m-dim td, table.m-table td.m-dim, +table.m-table tr.m-dim th, table.m-table th.m-dim { + background-color: #2d3236; + color: #747474; +} +.m-note.m-dim a, +table.m-table tr.m-dim td a, table.m-table td.m-dim a, +table.m-table tr.m-dim th a, table.m-table th.m-dim a { + color: #acacac; +} +.m-note.m-dim a:hover, +table.m-table tr.m-dim td a:hover, table.m-table td.m-dim a:hover, +table.m-table tr.m-dim th a:hover, table.m-table th.m-dim a:hover, +.m-note.m-dim a:focus, +table.m-table tr.m-dim td a:focus, table.m-table td.m-dim a:focus, +table.m-table tr.m-dim th a:focus, table.m-table th.m-dim a:focus, +.m-note.m-dim a:active, +table.m-table tr.m-dim td a:active, table.m-table td.m-dim a:active, +table.m-table tr.m-dim th a:active, table.m-table th.m-dim a:active { + color: #747474; +} +figure.m-figure.m-default:before { border-color: #34424d; } +figure.m-figure.m-default figcaption { color: #dcdcdc; } +figure.m-figure.m-primary:before { border-color: #a5c2db; } +figure.m-figure.m-primary figcaption { color: #a5c9ea; } +figure.m-figure.m-success:before { border-color: #2a703f; } +figure.m-figure.m-success figcaption { color: #3bd267; } +figure.m-figure.m-warning:before { border-color: #6d702a; } +figure.m-figure.m-warning figcaption { color: #c7cf2f; } +figure.m-figure.m-danger:before { border-color: #702b2a; } +figure.m-figure.m-danger figcaption { color: #cd3431; } +figure.m-figure.m-info:before { border-color: #2a4f70; } +figure.m-figure.m-info figcaption { color: #2f83cc; } +figure.m-figure.m-dim:before { border-color: #2d3236; } +figure.m-figure.m-dim { color: #747474; } +figure.m-figure.m-dim a { color: #acacac; } +figure.m-figure.m-dim a:hover, figure.m-figure.m-dim a:focus, figure.m-figure.m-dim a:active { + color: #747474; +} +.m-math { fill: #dcdcdc; } +.m-math.m-default, .m-math g.m-default, .m-math rect.m-default, +div.m-plot svg .m-bar.m-default, +.m-graph g.m-edge polygon, +.m-graph g.m-node:not(.m-flat) ellipse, +.m-graph g.m-node:not(.m-flat) polygon, +.m-graph g.m-edge text, +.m-graph g.m-node.m-flat text, +.m-graph.m-default g.m-edge polygon, +.m-graph.m-default g.m-node:not(.m-flat) ellipse, +.m-graph.m-default g.m-node:not(.m-flat) polygon, +.m-graph.m-default g.m-edge text, +.m-graph.m-default g.m-node.m-flat text { + fill: #dcdcdc; +} +.m-graph g.m-edge polygon, +.m-graph g.m-edge path, +.m-graph g.m-node ellipse, +.m-graph g.m-node polygon, +.m-graph g.m-node polyline, +.m-graph.m-default g.m-edge polygon, +.m-graph.m-default g.m-edge path, +.m-graph.m-default g.m-node ellipse, +.m-graph.m-default g.m-node polygon, +.m-graph.m-default g.m-node polyline { + stroke: #dcdcdc; +} +.m-math.m-primary, .m-math g.m-primary, .m-math rect.m-primary, +div.m-plot svg .m-bar.m-primary, +.m-graph.m-primary g.m-edge polygon, +.m-graph.m-primary g.m-node:not(.m-flat) ellipse, +.m-graph.m-primary g.m-node:not(.m-flat) polygon, +.m-graph.m-primary g.m-edge text, +.m-graph.m-primary g.m-node.m-flat text { + fill: #a5c9ea; +} +.m-graph.m-primary g.m-edge polygon, +.m-graph.m-primary g.m-edge path, +.m-graph.m-primary g.m-node ellipse, +.m-graph.m-primary g.m-node polygon, +.m-graph.m-primary g.m-node polyline { + stroke: #a5c9ea; +} +.m-math.m-success, .m-math g.m-success, .m-math rect.m-success, +div.m-plot svg .m-bar.m-success, +.m-graph.m-success g.m-edge polygon, +.m-graph.m-success g.m-node:not(.m-flat) ellipse, +.m-graph.m-success g.m-node:not(.m-flat) polygon, +.m-graph.m-success g.m-edge text, +.m-graph.m-success g.m-node.m-flat text { + fill: #3bd267; +} +.m-graph.m-success g.m-edge polygon, +.m-graph.m-success g.m-edge path, +.m-graph.m-success g.m-node ellipse, +.m-graph.m-success g.m-node polygon, +.m-graph.m-success g.m-node polyline { + stroke: #3bd267; +} +.m-math.m-warning, .m-math g.m-warning, .m-math rect.m-warning, +div.m-plot svg .m-bar.m-warning, +.m-graph.m-warning g.m-edge polygon, +.m-graph.m-warning g.m-node:not(.m-flat) ellipse, +.m-graph.m-warning g.m-node:not(.m-flat) polygon, +.m-graph.m-warning g.m-edge text, +.m-graph.m-warning g.m-node.m-flat text { + fill: #c7cf2f; +} +.m-graph.m-warning g.m-edge polygon, +.m-graph.m-warning g.m-edge path, +.m-graph.m-warning g.m-node ellipse, +.m-graph.m-warning g.m-node polygon, +.m-graph.m-warning g.m-node polyline { + stroke: #c7cf2f; +} +.m-math.m-danger, .m-math g.m-danger, .m-math rect.m-danger, +div.m-plot svg .m-bar.m-danger, +.m-graph.m-danger g.m-edge polygon, +.m-graph.m-danger g.m-node:not(.m-flat) ellipse, +.m-graph.m-danger g.m-node:not(.m-flat) polygon, +.m-graph.m-danger g.m-edge text, +.m-graph.m-danger g.m-node.m-flat text { + fill: #cd3431; +} +.m-graph.m-danger g.m-edge polygon, +.m-graph.m-danger g.m-edge path, +.m-graph.m-danger g.m-node ellipse, +.m-graph.m-danger g.m-node polygon, +.m-graph.m-danger g.m-node polyline { + stroke: #cd3431; +} +.m-math.m-info, .m-math g.m-info, .m-math rect.m-info, +div.m-plot svg .m-bar.m-info, +.m-graph.m-info g.m-edge polygon, +.m-graph.m-info g.m-node:not(.m-flat) ellipse, +.m-graph.m-info g.m-node:not(.m-flat) polygon, +.m-graph.m-info g.m-edge text, +.m-graph.m-info g.m-node.m-flat text { + fill: #2f83cc; +} +.m-graph.m-info g.m-edge polygon, +.m-graph.m-info g.m-edge path, +.m-graph.m-info g.m-node ellipse, +.m-graph.m-info g.m-node polygon, +.m-graph.m-info g.m-node polyline { + stroke: #2f83cc; +} +.m-math.m-dim, .m-math g.m-dim, .m-math rect.m-dim, +div.m-plot svg .m-bar.m-dim, +.m-graph.m-dim g.m-edge polygon, +.m-graph.m-dim g.m-node:not(.m-flat) ellipse, +.m-graph.m-dim g.m-node:not(.m-flat) polygon, +.m-graph.m-dim g.m-edge text, +.m-graph.m-dim g.m-node.m-flat text { + fill: #747474; +} +.m-graph.m-dim g.m-edge polygon, +.m-graph.m-dim g.m-edge path, +.m-graph.m-dim g.m-node ellipse, +.m-graph.m-dim g.m-node polygon, +.m-graph.m-dim g.m-node polyline { + stroke: #747474; +} +.m-graph g.m-edge.m-default polygon, +.m-graph g.m-node.m-default:not(.m-flat) ellipse, +.m-graph g.m-node.m-default:not(.m-flat) polygon, +.m-graph g.m-edge.m-default text, +.m-graph g.m-node.m-default.m-flat text { + fill: #dcdcdc; +} +.m-graph g.m-edge.m-default polygon, +.m-graph g.m-edge.m-default path, +.m-graph g.m-node.m-default ellipse, +.m-graph g.m-node.m-default polygon, +.m-graph g.m-node.m-default polyline { + stroke: #dcdcdc; +} +.m-graph g.m-edge.m-primary polygon, +.m-graph g.m-node.m-primary:not(.m-flat) ellipse, +.m-graph g.m-node.m-primary:not(.m-flat) polygon, +.m-graph g.m-edge.m-primary text, +.m-graph g.m-node.m-primary.m-flat text { + fill: #a5c9ea; +} +.m-graph g.m-edge.m-primary polygon, +.m-graph g.m-edge.m-primary path, +.m-graph g.m-node.m-primary ellipse, +.m-graph g.m-node.m-primary polygon, +.m-graph g.m-node.m-primary polyline { + stroke: #a5c9ea; +} +.m-graph g.m-edge.m-success polygon, +.m-graph g.m-node.m-success:not(.m-flat) ellipse, +.m-graph g.m-node.m-success:not(.m-flat) polygon, +.m-graph g.m-edge.m-success text, +.m-graph g.m-node.m-success.m-flat text { + fill: #3bd267; +} +.m-graph g.m-edge.m-success polygon, +.m-graph g.m-edge.m-success path, +.m-graph g.m-node.m-success ellipse, +.m-graph g.m-node.m-success polygon, +.m-graph g.m-node.m-success polyline { + stroke: #3bd267; +} +.m-graph g.m-edge.m-warning polygon, +.m-graph g.m-node.m-warning:not(.m-flat) ellipse, +.m-graph g.m-node.m-warning:not(.m-flat) polygon, +.m-graph g.m-edge.m-warning text, +.m-graph g.m-node.m-warning.m-flat text { + fill: #c7cf2f; +} +.m-graph g.m-edge.m-warning polygon, +.m-graph g.m-edge.m-warning path, +.m-graph g.m-node.m-warning ellipse, +.m-graph g.m-node.m-warning polygon, +.m-graph g.m-node.m-warning polyline { + stroke: #c7cf2f; +} +.m-graph g.m-edge.m-danger polygon, +.m-graph g.m-node.m-danger:not(.m-flat) ellipse, +.m-graph g.m-node.m-danger:not(.m-flat) polygon, +.m-graph g.m-edge.m-danger text, +.m-graph g.m-node.m-danger.m-flat text { + fill: #cd3431; +} +.m-graph g.m-edge.m-danger polygon, +.m-graph g.m-edge.m-danger path, +.m-graph g.m-node.m-danger ellipse, +.m-graph g.m-node.m-danger polygon, +.m-graph g.m-node.m-danger polyline { + stroke: #cd3431; +} +.m-graph g.m-edge.m-info polygon, +.m-graph g.m-node.m-info:not(.m-flat) ellipse, +.m-graph g.m-node.m-info:not(.m-flat) polygon, +.m-graph g.m-edge.m-info text, +.m-graph g.m-node.m-info.m-flat text { + fill: #2f83cc; +} +.m-graph g.m-edge.m-info polygon, +.m-graph g.m-edge.m-info path, +.m-graph g.m-node.m-info ellipse, +.m-graph g.m-node.m-info polygon, +.m-graph g.m-node.m-info polyline { + stroke: #2f83cc; +} +.m-graph g.m-edge.m-dim polygon, +.m-graph g.m-node.m-dim:not(.m-flat) ellipse, +.m-graph g.m-node.m-dim:not(.m-flat) polygon, +.m-graph g.m-edge.m-dim text, +.m-graph g.m-node.m-dim.m-flat text { + fill: #747474; +} +.m-graph g.m-edge.m-dim polygon, +.m-graph g.m-edge.m-dim path, +.m-graph g.m-node.m-dim ellipse, +.m-graph g.m-node.m-dim polygon, +.m-graph g.m-node.m-dim polyline { + stroke: #747474; +} +p, ul, ol, dl, blockquote, pre, .m-code-figure, .m-console-figure, hr, .m-note, +.m-frame, .m-block, div.m-button, div.m-scroll, table.m-table, div.m-image, +img.m-image, svg.m-image, figure.m-figure, .m-imagegrid, div.m-math, +div.m-graph, div.m-plot { + margin-bottom: 1rem; +} +p:last-child, p.m-nopadb, ul:last-child, ul.m-nopadb, +ol:last-child, ol.m-nopadb, dl:last-child, dl.m-nopadb, +blockquote:last-child, blockquote.m-nopadb, pre:last-child, pre.m-nopadb, +.m-code-figure:last-child, .m-code-figure.m-nopadb, +.m-console-figure:last-child, .m-console-figure.m-nopadb, +hr:last-child, hr.m-nopadb, .m-note:last-child, .m-note.m-nopadb, +.m-frame:last-child, .m-frame.m-nopadb, .m-block:last-child, .m-block.m-nopadb, +div.m-button:last-child, div.m-button.m-nopadb, +div.m-scroll:last-child, div.m-scroll.m-nopadb, +table.m-table:last-child, table.m-table.m-nopadb, +img.m-image:last-child, img.m-image.m-nopadb, +svg.m-image:last-child, svg.m-image.m-nopadb, +div.m-image:last-child, div.m-image.m-nopadb, +figure.m-figure:last-child, figure.m-figure.m-nopadb, +.m-imagegrid:last-child, .m-imagegrid.m-nopadb, +div.m-math:last-child, div.m-math.m-nopadb, +div.m-graph:last-child, div.m-graph.m-nopadb, +div.m-plot:last-child, div.m-plot.m-nopadb { + margin-bottom: 0; +} +li > p:last-child, li > blockquote:last-child, li > pre:last-child, +li > .m-code-figure:last-child, li > .m-console-figure:last-child, +li > .m-note:last-child, li > .m-frame:last-child, li > .m-block:last-child, +li > div.m-button:last-child, li > div.m-scroll:last-child, li > table.m-table:last-child, +li > img.m-image:last-child, li > svg.m-image:last-child, li > div.m-image:last-child, +li > figure.m-figure:last-child, li > div.m-math:last-child, +li > div.m-graph:last-child, li > div.m-plot:last-child { + margin-bottom: 1rem; +} +li:last-child > p:last-child, li:last-child > p.m-nopadb, +li:last-child > blockquote:last-child, li:last-child > blockquote.m-nopadb, +li:last-child > pre:last-child, li:last-child > pre.m-nopadb, +li:last-child > .m-code-figure:last-child, li:last-child > .m-code-figure.m-nopadb, +li:last-child > .m-console-figure:last-child, li:last-child > .m-console-figure.m-nopadb, +li:last-child > .m-note:last-child, li:last-child > .m-note.m-nopadb, +li:last-child > .m-frame:last-child, li:last-child > .m-frame.m-nopadb, +li:last-child > .m-block:last-child, li:last-child > .m-block.m-nopadb, +li:last-child > div.m-button:last-child, li:last-child > div.m-button.m-nopadb, +li:last-child > div.m-scroll:last-child, li:last-child > div.m-scroll.m-nopadb, +li:last-child > table.m-table:last-child, li:last-child > table.m-table.m-nopadb, +li:last-child > img.m-image:last-child, li:last-child > img.m-image.m-nopadb, +li:last-child > svg.m-image:last-child, li:last-child > svg.m-image.m-nopadb, +li:last-child > div.m-image:last-child, li:last-child > div.m-image.m-nopadb, +li:last-child > figure.m-figure:last-child, li:last-child > figure.m-figure.m-nopadb, +li:last-child > div.m-math:last-child, li:last-child > div.m-math.m-nopadb, +li:last-child > div.m-graph:last-child, li:last-child > div.m-graph.m-nopadb, +li:last-child > div.m-plot:last-child, li:last-child > div.m-plot.m-nopadb { + margin-bottom: 0; +} + +body > header > nav { + width: 100%; + background-color: #22272e; + min-height: 3rem; +} +body > header > nav.m-navbar-landing, +body > header > nav.m-navbar-cover { + background-color: transparent; + position: relative; +} +body > header > nav.m-navbar-landing { + opacity: 0.8; +} +body > header > nav.m-navbar-cover { + background-color: rgba(34, 39, 46, 0.25); + opacity: 1; +} +body > header > nav.m-navbar-landing:hover, +body > header > nav.m-navbar-cover:hover { + background-color: rgba(34, 39, 46, 0.75); + opacity: 1; +} +body> header > nav.m-navbar-landing:target, +body> header > nav.m-navbar-cover:target { + background-color: #22272e; + opacity: 1; +} +body > header > nav.m-navbar-landing #m-navbar-brand.m-navbar-brand-hidden { + visibility: hidden; +} +body > header > nav.m-navbar-landing:target #m-navbar-brand.m-navbar-brand-hidden { + visibility: visible; +} +body > header > nav { + margin-left: auto; + margin-right: auto; + color: #ffffff; +} +body > header > nav a { + text-decoration: none; + text-transform: none; + display: inline-block; + vertical-align: middle; + line-height: 2.75rem; + color: #ffffff; +} +body > header > nav #m-navbar-brand, body > header > nav a#m-navbar-show, body > header > nav a#m-navbar-hide { + font-weight: 600; + font-size: 1.125rem; + padding-left: 1rem; + padding-right: 1rem; +} +body > header > nav a#m-navbar-brand, body > header > nav #m-navbar-brand a { + text-transform: uppercase; +} +body > header > nav a#m-navbar-brand img, body > header > nav #m-navbar-brand a img { + width: 1.75rem; + height: 1.75rem; + vertical-align: -22.5%; + margin-right: 0.5rem; +} +body > header > nav #m-navbar-brand a { + padding-left: 0; + padding-right: 0; +} +body > header > nav #m-navbar-brand .m-thin { + font-weight: normal; +} +body > header > nav #m-navbar-brand .m-breadcrumb { + color: #747474; +} +body > header > nav a#m-navbar-show:before, body > header > nav a#m-navbar-hide:before { + content:'\2630'; +} +body > header > nav #m-navbar-collapse { + padding-bottom: 1rem; +} +body > header > nav #m-navbar-collapse li { + border-style: solid; + border-color: transparent; + border-width: 0 0 0 0.25rem; + margin-left: -1rem; +} +body > header > nav #m-navbar-collapse li a { + border-style: solid; + border-color: transparent; + line-height: 1.5rem; + margin-left: -0.25rem; + padding-left: 0.75rem; + border-width: 0 0 0 0.25rem; + width: 100%; +} +body > header > nav #m-navbar-collapse li a#m-navbar-current { + color: #5b9dd9; + border-color: #5b9dd9; +} +body > header > nav ol { + list-style-type: none; + margin: 0; +} +body > header > nav ol ol { + padding-left: 1.5rem; +} +body > header > nav .m-row > [class*='m-col-'] { + padding-top: 0; + padding-bottom: 0; +} +body > header > nav a:hover, body > header > nav a:focus, body > header > nav a:active { + color: #a5c9ea; +} +body > header > nav #m-navbar-collapse li:hover { + border-color: #a5c9ea; +} +body > header > nav #m-navbar-collapse li a:hover, +body > header > nav #m-navbar-collapse li a:focus, +body > header > nav #m-navbar-collapse li a:active { + border-color: #a5c9ea; + background-color: #292f37; +} +body > header > nav.m-navbar-landing #m-navbar-collapse li a:hover, +body > header > nav.m-navbar-cover #m-navbar-collapse li a:hover, +body > header > nav.m-navbar-landing #m-navbar-collapse li a:focus, +body > header > nav.m-navbar-cover #m-navbar-collapse li a:focus, +body > header > nav.m-navbar-landing #m-navbar-collapse li a:active, +body > header > nav.m-navbar-cover #m-navbar-collapse li a:active { + background-color: rgba(41, 47, 55, 0.5); +} +body > header > nav #m-navbar-hide { + display: none; +} +body > header > nav:target #m-navbar-collapse { + display: block; +} +body > header > nav:target #m-navbar-show { + display: none; +} +body > header > nav:target #m-navbar-hide { + display: inline-block; +} +@media screen and (min-width: 768px) { + body > header > nav #m-navbar-show, body > header > nav #m-navbar-hide, + body > header > nav:target #m-navbar-show, body > header > nav:target #m-navbar-hide { + display: none; + } + body > header > nav #m-navbar-collapse li a { + line-height: 2.75rem; + } + body > header > nav a, body > header > nav #m-navbar-collapse li a { + margin-left: 0; + padding-left: 1rem; + padding-right: 1rem; + white-space: nowrap; + } + body > header > nav #m-navbar-collapse { + padding-bottom: 0; + } + body > header > nav #m-navbar-collapse li ol { + background-color: #22272e; + } + body > header > nav #m-navbar-collapse ol ol li { + margin-left: 0; + padding-left: 0; + border-left-width: 0; + } + body > header > nav #m-navbar-collapse ol ol li a { + padding-left: 0.75rem; + } + body > header > nav #m-navbar-collapse > .m-row > ol > li { + margin-left: 0; + border-left-width: 0; + } + body > header > nav #m-navbar-collapse > .m-row > ol > li > a { + border-width: 0 0 0.25rem 0; + } + body > header > nav #m-navbar-collapse ol { + padding-left: 0; + padding-right: 0; + } + body > header > nav #m-navbar-collapse > .m-row > ol, body > header > nav #m-navbar-collapse > .m-row > ol > li { + float: left; + } + body > header > nav #m-navbar-collapse ol ol { + z-index: 99999; + position: absolute; + visibility: hidden; + } + body > header > nav #m-navbar-collapse li:hover ol { + visibility: visible; + } +} +body > footer { + width: 100%; +} +body > footer > nav { + padding-top: 1rem; + padding-bottom: 1rem; + font-size: 0.85rem; + text-align: center; + color: #c5c5c5; + background-color: #444e5c; +} +body > footer > nav h3, body > footer > nav h3 a { + text-transform: uppercase; + font-weight: normal; +} +body > footer > nav ul { + list-style-type: none; + padding: 0; + margin: 0; +} +body > footer > nav a { + text-decoration: none; + text-transform: none; + color: #ffffff; +} +body > footer > nav a:hover, body > footer > nav a:focus, body > footer > nav a:active { + color: #a5c9ea; +} +body > main { + padding-top: 1rem; + padding-bottom: 1rem; +} +article h1 { + font-size: 1.75rem; +} +article h1 .m-breadcrumb { + color: #747474; + font-weight: normal; +} +article h1 .m-breadcrumb a { + color: #a5c9ea; +} +article h1 .m-breadcrumb a:hover, article h1 a:focus, article h1 a:active { + color: #dcdcdc; +} +article > header h1 { + font-size: 2rem; + margin-bottom: 0.5rem; +} +article h1 a, article > header h1, article > header h1 a, +article section > h2, article section > h2 a, +article section > h3, article section > h3 a, +article section > h4, article section > h4 a, +article section > h5, article section > h5 a, +article section > h6, article section > h6 a { + color: #a5c9ea; +} +article h1 a:hover, article > header h1 a:hover, article > header h1 a:focus, article > header h1 a:active, +article section > h2 a:hover, article section > h2 a:focus, article section > h2 a:active, +article section > h3 a:hover, article section > h3 a:focus, article section > h3 a:active, +article section > h4 a:hover, article section > h4 a:focus, article section > h4 a:active, +article section > h5 a:hover, article section > h5 a:focus, article section > h5 a:active, +article section > h6 a:hover, article section > h6 a:focus, article section > h6 a:active { + color: #dcdcdc; +} +article > header .m-date { + display: block; + width: 2.5rem; + float: left; + text-align: center; + line-height: 95%; + font-size: 0.75rem; + font-weight: normal; + white-space: nowrap; + border-right-style: solid; + border-right-width: 0.125rem; + border-color: #a5c9ea; + padding-right: 0.75rem; + margin-top: -0.1rem; + margin-right: 0.75rem; + margin-bottom: 0.25rem; +} +article > header .m-date-day { + display: block; + font-weight: bold; + padding-top: 0.2rem; + padding-bottom: 0.15rem; + font-size: 1.25rem; +} +article > header p { + color: #f0f0f0; + font-size: 1.125rem; +} +article > header h1::after { + content: " "; + clear: both; + display: table; +} +article > footer { + color: #c5c5c5; +} +article > footer p { + font-style: italic; + font-size: 0.85rem; + text-indent: 0; +} +article section:target { + margin-left: -1.0rem; + border-left-style: solid; + border-left-width: 0.25rem; + padding-left: 0.75rem; + border-color: #a5c9ea; +} +article h1 a, article > header h1 a, article section > h2 a, article section > h3 a, +article section > h4 a, article section > h5 a, article section > h6 a { + text-decoration: none; +} +#m-landing-image, #m-cover-image, article#m-jumbo > header #m-jumbo-image { + background-size: cover; + background-color: #0f1217; + background-position: center center; + background-repeat: no-repeat; + margin-top: -4rem; + padding-top: 5rem; +} +#m-landing-image { + color: #ffffff; +} +#m-cover-image { + height: 30rem; + margin-bottom: -26rem; +} +#m-landing-cover h1 { + font-size: 2.8rem; + margin-top: -0.5rem; + padding-left: 1.5rem; + padding-bottom: 1rem; + text-transform: lowercase; +} +#m-landing-cover { + padding-bottom: 10rem; + margin-bottom: -6rem; +} +article#m-jumbo { + margin-top: -1rem; +} +#m-landing-cover, #m-cover-image > div, article#m-jumbo > header #m-jumbo-cover { + background: linear-gradient(transparent 0%, transparent 50%, #2f363f 100%); + width: 100%; + height: 100%; +} +article#m-jumbo > header h1, article#m-jumbo > header h2 { + text-align: center; + font-weight: bold; +} +article#m-jumbo > header a { + text-decoration: none; +} +article#m-jumbo > header #m-jumbo-cover { + padding-bottom: 5rem; +} +article#m-jumbo > header #m-jumbo-image { + font-size: 2.5vmin; + margin-bottom: -3rem; +} +article#m-jumbo > header h1 { + font-size: 10vmin; +} +article#m-jumbo > header h2 { + font-size: 3vmin; +} +@media screen and (max-height: 640px) , screen and (max-width: 640px) { + article#m-jumbo > header h1 { + font-size: 3rem; + } + article#m-jumbo > header #m-jumbo-image, article#m-jumbo > header h2 { + font-size: 1rem; + } +} +article#m-jumbo > header, article#m-jumbo > header h1, article#m-jumbo > header a { + color: #ffffff; +} +article#m-jumbo > header a:hover, article#m-jumbo > header a:focus, article#m-jumbo > header a:active { + color: #f0f0f0; +} +article#m-jumbo.m-inverted > header, article#m-jumbo.m-inverted > header h1, article#m-jumbo.m-inverted > header a { + color: #000000; +} +article#m-jumbo.m-inverted > header a:hover, article#m-jumbo.m-inverted > header a:focus, article#m-jumbo.m-inverted > header a:active { + color: #0f0f0f; +} +.m-landing-news h3 a { + color: #dcdcdc; + text-decoration: none; + text-transform: uppercase; +} +.m-landing-news h3 a:hover, .m-landing-news h3 a:hover, .m-landing-news h3 a:focus, .m-landing-news h3 a:active { + color: #a5c9ea; +} +.m-landing-news time { + display: inline-block; + margin-left: 1rem; + float: right; +} +.m-article-pagination { + text-align: center; + padding: 1rem; +} +nav.m-navpanel { + text-align: center; +} +nav.m-navpanel h3 { + text-transform: uppercase; + font-weight: normal; +} +nav.m-navpanel ol { + text-transform: lowercase; +} +nav.m-navpanel ol, nav.m-navpanel ul { + list-style-type: none; + padding: 0; +} +nav.m-navpanel a { + color: #ffffff; + text-decoration: none; +} +nav.m-navpanel a:hover, nav.m-navpanel a:focus, nav.m-navpanel a:active { + color: #a5c9ea; +} +ul.m-tagcloud li { display: inline; } +ul.m-tagcloud li.m-tag-1 { font-size: 0.75rem; } +ul.m-tagcloud li.m-tag-2 { font-size: 0.825rem; } +ul.m-tagcloud li.m-tag-3 { font-size: 1rem; } +ul.m-tagcloud li.m-tag-4 { font-size: 1.25rem; } +ul.m-tagcloud li.m-tag-5 { font-size: 1.5rem; } +article section:target figure.m-code-figure, article section:target figure.m-console-figure { + z-index: 1; +} +article, article > header, article section { margin-bottom: 1rem; } +article:last-child, article section:last-child { margin-bottom: 0; } +.m-container-inflatable section:target > .m-note, +.m-container-inflatable section:target > .m-frame, +.m-container-inflatable section:target > .m-block, +.m-container-inflatable section:target > pre, +.m-container-inflatable section:target > .m-code-figure > pre:first-child, +.m-container-inflatable section:target > .m-console-figure > pre:first-child, +.m-container-inflatable section:target section > .m-note, +.m-container-inflatable section:target section > .m-frame, +.m-container-inflatable section:target section > .m-block, +.m-container-inflatable section:target section > pre, +.m-container-inflatable section:target section > .m-code-figure > pre:first-child, +.m-container-inflatable section:target section > .m-console-figure > pre:first-child, +.m-container-inflatable section:target [class*='m-center-'] > .m-note, +.m-container-inflatable section:target [class*='m-center-'] > .m-frame, +.m-container-inflatable section:target [class*='m-center-'] > .m-block, +.m-container-inflatable section:target [class*='m-center-'] > pre, +.m-container-inflatable section:target [class*='m-center-'] > .m-code-figure > pre:first-child, +.m-container-inflatable section:target [class*='m-center-'] > .m-console-figure > pre:first-child, +.m-container-inflatable section:target [class*='m-left-'] > .m-note, +.m-container-inflatable section:target [class*='m-left-'] > .m-frame, +.m-container-inflatable section:target [class*='m-left-'] > .m-block, +.m-container-inflatable section:target [class*='m-left-'] > pre, +.m-container-inflatable section:target [class*='m-left-'] > .m-code-figure > pre:first-child, +.m-container-inflatable section:target [class*='m-left-'] > .m-console-figure > pre:first-child, +.m-container-inflatable section:target [class*='m-right-'] > .m-note, +.m-container-inflatable section:target [class*='m-right-'] > .m-frame, +.m-container-inflatable section:target [class*='m-right-'] > .m-block, +.m-container-inflatable section:target [class*='m-right-'] > pre, +.m-container-inflatable section:target [class*='m-right-'] > .m-code-figure > pre:first-child, +.m-container-inflatable section:target [class*='m-right-'] > .m-console-figure > pre:first-child, +.m-container-inflatable section:target .m-container-inflate > .m-note, +.m-container-inflatable section:target .m-container-inflate > .m-frame, +.m-container-inflatable section:target .m-container-inflate > .m-block, +.m-container-inflatable section:target .m-container-inflate > pre, +.m-container-inflatable section:target .m-container-inflate > .m-code-figure > pre:first-child, +.m-container-inflatable section:target .m-container-inflate > .m-console-figure > pre:first-child { + margin-left: -1.0rem; + border-left-style: solid; + border-left-width: 0.25rem; + border-top-left-radius: 0; + border-bottom-left-radius: 0; + padding-left: 0.75rem; +} +.m-container-inflatable section:target > .m-code-figure::before, +.m-container-inflatable section:target > .m-console-figure::before, +.m-container-inflatable section:target section > .m-code-figure::before, +.m-container-inflatable section:target section > .m-console-figure::before, +.m-container-inflatable section:target [class*='m-center-'] > .m-code-figure::before, +.m-container-inflatable section:target [class*='m-center-'] > .m-console-figure::before, +.m-container-inflatable section:target [class*='m-left-'] > .m-code-figure::before, +.m-container-inflatable section:target [class*='m-left-'] > .m-console-figure::before, +.m-container-inflatable section:target [class*='m-right-'] > .m-code-figure::before, +.m-container-inflatable section:target [class*='m-right-'] > .m-console-figure::before, +.m-container-inflatable section:target .m-container-inflate > .m-code-figure::before, +.m-container-inflatable section:target .m-container-inflate > .m-console-figure::before { + border-top-left-radius: 0; + border-bottom-left-radius: 0; + border-left-width: 0.25rem; +} +.m-container-inflatable section:target > .m-code-figure > pre.m-nopad, +.m-container-inflatable section:target > .m-console-figure > pre.m-nopad { + margin-left: -0.75rem; + padding-left: -0.75rem; +} +@media screen and (min-width: 576px) { + .m-container-inflatable section:target .m-center-s > .m-note, + .m-container-inflatable section:target .m-center-s > pre, + .m-container-inflatable section:target .m-center-s > figure.m-code-figure > pre:first-child, + .m-container-inflatable section:target .m-center-s > figure.m-console-figure > pre:first-child, + .m-container-inflatable section:target .m-right-s > figure.m-code-figure > pre:first-child, + .m-container-inflatable section:target .m-right-s > figure.m-console-figure > pre:first-child { + border-left-width: 0; + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + padding-left: 1rem; + } + .m-container-inflatable section:target .m-center-s > .m-block, + .m-container-inflatable section:target .m-right-s > .m-block { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + } + .m-container-inflatable section:target .m-center-s > .m-frame, + .m-container-inflatable section:target .m-right-s > .m-frame { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + border-left-width: 0.125rem; + padding-left: 0.875rem; + } + .m-container-inflatable section:target .m-right-s > .m-block, + .m-container-inflatable section:target .m-right-s > .m-frame { + margin-left: 0; + } + .m-container-inflatable section:target .m-right-s > .m-note, + .m-container-inflatable section:target .m-right-s > pre { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + margin-left: 0; + border-left-width: 0; + padding-left: 1rem; + } + .m-container-inflatable section:target .m-center-s > figure.m-code-figure::before, + .m-container-inflatable section:target .m-center-s > figure.m-console-figure::before, + .m-container-inflatable section:target .m-right-s > figure.m-code-figure::before, + .m-container-inflatable section:target .m-right-s > figure.m-console-figure::before { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + border-left-width: 0.125rem; + } +} +@media screen and (min-width: 768px) { + .m-container-inflatable section:target .m-center-m > .m-note, + .m-container-inflatable section:target .m-center-m > pre, + .m-container-inflatable section:target .m-center-m > figure.m-code-figure > pre:first-child, + .m-container-inflatable section:target .m-center-m > figure.m-console-figure > pre:first-child, + .m-container-inflatable section:target .m-right-m > figure.m-code-figure > pre:first-child, + .m-container-inflatable section:target .m-right-m > figure.m-console-figure > pre:first-child { + border-left-width: 0; + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + padding-left: 1rem; + } + .m-container-inflatable section:target .m-center-m > .m-block, + .m-container-inflatable section:target .m-right-m > .m-block { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + } + .m-container-inflatable section:target .m-center-m > .m-frame, + .m-container-inflatable section:target .m-right-m > .m-frame { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + border-left-width: 0.125rem; + padding-left: 0.875rem; + } + .m-container-inflatable section:target .m-right-m > .m-block, + .m-container-inflatable section:target .m-right-m > .m-frame { + margin-left: 0; + } + .m-container-inflatable section:target .m-right-m > .m-note, + .m-container-inflatable section:target .m-right-m > pre { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + margin-left: 0; + border-left-width: 0; + padding-left: 1rem; + } + .m-container-inflatable section:target .m-center-m > figure.m-code-figure::before, + .m-container-inflatable section:target .m-center-m > figure.m-console-figure::before, + .m-container-inflatable section:target .m-right-m > figure.m-code-figure::before, + .m-container-inflatable section:target .m-right-m > figure.m-console-figure::before { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + border-left-width: 0.125rem; + } +} +@media screen and (min-width: 992px) { + .m-container-inflatable section:target .m-center-l > .m-note, + .m-container-inflatable section:target .m-center-l > pre, + .m-container-inflatable section:target .m-center-l > figure.m-code-figure > pre:first-child, + .m-container-inflatable section:target .m-center-l > figure.m-console-figure > pre:first-child, + .m-container-inflatable section:target .m-right-l > figure.m-code-figure > pre:first-child, + .m-container-inflatable section:target .m-right-l > figure.m-console-figure > pre:first-child { + border-left-width: 0; + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + padding-left: 1rem; + } + .m-container-inflatable section:target .m-center-l > .m-block, + .m-container-inflatable section:target .m-right-l > .m-block { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + } + .m-container-inflatable section:target .m-center-l > .m-frame, + .m-container-inflatable section:target .m-right-l > .m-frame { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + border-left-width: 0.125rem; + padding-left: 0.875rem; + } + .m-container-inflatable section:target .m-right-l > .m-block, + .m-container-inflatable section:target .m-right-l > .m-frame { + margin-left: 0; + } + .m-container-inflatable section:target .m-right-l > .m-note, + .m-container-inflatable section:target .m-right-l > pre { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + margin-left: 0; + border-left-width: 0; + padding-left: 1rem; + } + .m-container-inflatable section:target .m-center-l > figure.m-code-figure::before, + .m-container-inflatable section:target .m-center-l > figure.m-console-figure::before, + .m-container-inflatable section:target .m-right-l > figure.m-code-figure::before, + .m-container-inflatable section:target .m-right-l > figure.m-console-figure::before { + border-top-left-radius: 0.2rem; + border-bottom-left-radius: 0.2rem; + border-left-width: 0.125rem; + } +} +.m-container-inflatable section:target > figure.m-code-figure::before, +.m-container-inflatable section:target > figure.m-console-figure::before, +.m-container-inflatable section:target section > figure.m-code-figure::before, +.m-container-inflatable section:target section > figure.m-console-figure::before, +.m-container-inflatable section:target [class*='m-center-'] > figure.m-code-figure::before, +.m-container-inflatable section:target [class*='m-center-'] > figure.m-console-figure::before, +.m-container-inflatable section:target [class*='m-left-'] > figure.m-code-figure::before, +.m-container-inflatable section:target [class*='m-left-'] > figure.m-console-figure::before, +.m-container-inflatable section:target [class*='m-right-'] > figure.m-code-figure::before, +.m-container-inflatable section:target [class*='m-right-'] > figure.m-console-figure::before, +.m-container-inflatable section:target .m-container-inflatable > figure.m-code-figure::before, +.m-container-inflatable section:target .m-container-inflatable > figure.m-console-figure::before { + border-left-color: #405363; +} +@media screen and (min-width: 576px) { + .m-container-inflatable section:target .m-center-s > figure.m-code-figure::before, + .m-container-inflatable section:target .m-right-s > figure.m-code-figure::before { + border-color: #282e36; + } + .m-container-inflatable section:target .m-center-s > figure.m-console-figure::before, + .m-container-inflatable section:target .m-right-s > figure.m-console-figure::before { + border-color: #1a1c1d; + } +} +@media screen and (min-width: 768px) { + .m-container-inflatable section:target .m-center-m > figure.m-code-figure::before, + .m-container-inflatable section:target .m-right-m > figure.m-code-figure::before { + border-color: #282e36; + } + .m-container-inflatable section:target .m-center-m > figure.m-console-figure::before, + .m-container-inflatable section:target .m-right-m > figure.m-console-figure::before { + border-color: #1a1c1d; + } +} +@media screen and (min-width: 992px) { + .m-container-inflatable section:target .m-center-l > figure.m-code-figure::before, + .m-container-inflatable section:target .m-right-l > figure.m-code-figure::before { + border-color: #282e36; + } + .m-container-inflatable section:target .m-center-l > figure.m-console-figure::before, + .m-container-inflatable section:target .m-right-l > figure.m-console-figure::before { + border-color: #1a1c1d; + } +} +.m-container-inflatable section:target pre, +.m-container-inflatable section:target figure.m-code-figure > pre:first-child, +.m-container-inflatable section:target figure.m-console-figure > pre:first-child { + border-color: #405363; +} +.m-container-inflatable section:target .m-note.m-default { + border-color: #405363; +} +.m-container-inflatable section:target .m-note.m-primary { + border-color: #a5c9ea; +} +.m-container-inflatable section:target .m-note.m-success { + border-color: #3bd267; +} +.m-container-inflatable section:target .m-note.m-warning { + border-color: #c7cf2f; +} +.m-container-inflatable section:target .m-note.m-danger { + border-color: #cd3431; +} +.m-container-inflatable section:target .m-note.m-info { + border-color: #2f83cc; +} +.m-container-inflatable section:target .m-note.m-dim { + border-color: #747474; +} + +.m-code .hll { background-color: #34424d } +.m-code .c { color: #a5c9ea } +.m-code .k { color: #ffffff; font-weight: bold } +.m-code .n { color: #dcdcdc } +.m-code .o { color: #aaaaaa } +.m-code .p { color: #aaaaaa } +.m-code .ch { color: #a5c9ea } +.m-code .cm { color: #a5c9ea } +.m-code .cp { color: #3bd267 } +.m-code .cpf { color: #c7cf2f } +.m-code .c1 { color: #a5c9ea } +.m-code .cs { color: #a5c9ea } +.m-code .gd { color: #cd3431 } +.m-code .ge { color: #e6e6e6; font-style: italic } +.m-code .gh { color: #ffffff; font-weight: bold } +.m-code .gi { color: #3bd267 } +.m-code .gs { color: #e6e6e6; font-weight: bold } +.m-code .gu { color: #5b9dd9 } +.m-code .kc { color: #ffffff; font-weight: bold } +.m-code .kd { color: #ffffff; font-weight: bold } +.m-code .kn { color: #ffffff; font-weight: bold } +.m-code .kp { color: #ffffff; font-weight: bold } +.m-code .kr { color: #ffffff; font-weight: bold } +.m-code .kt { color: #ffffff; font-weight: bold } +.m-code .m { color: #c7cf2f } +.m-code .s { color: #e07f7c } +.m-code .na { color: #dcdcdc; font-weight: bold } +.m-code .nb { color: #ffffff; font-weight: bold } +.m-code .nc { color: #dcdcdc; font-weight: bold } +.m-code .no { color: #dcdcdc } +.m-code .nd { color: #dcdcdc } +.m-code .ni { color: #dcdcdc } +.m-code .ne { color: #dcdcdc } +.m-code .nf { color: #dcdcdc } +.m-code .nl { color: #dcdcdc } +.m-code .nn { color: #dcdcdc } +.m-code .nx { color: #dcdcdc } +.m-code .py { color: #dcdcdc } +.m-code .nt { color: #dcdcdc; font-weight: bold } +.m-code .nv { color: #c7cf2f } +.m-code .ow { color: #dcdcdc; font-weight: bold } +.m-code .mb { color: #c7cf2f } +.m-code .mf { color: #c7cf2f } +.m-code .mh { color: #c7cf2f } +.m-code .mi { color: #c7cf2f } +.m-code .mo { color: #c7cf2f } +.m-code .sa { color: #e07f7c } +.m-code .sb { color: #e07f7c } +.m-code .sc { color: #e07cdc } +.m-code .dl { color: #e07f7c } +.m-code .sd { color: #e07f7c } +.m-code .s2 { color: #e07f7c } +.m-code .se { color: #e07f7c } +.m-code .sh { color: #e07f7c } +.m-code .si { color: #e07f7c } +.m-code .sx { color: #e07f7c } +.m-code .sr { color: #e07f7c } +.m-code .s1 { color: #e07f7c } +.m-code .ss { color: #e07f7c } +.m-code .bp { color: #ffffff; font-weight: bold } +.m-code .fm { color: #dcdcdc } +.m-code .vc { color: #c7cf2f } +.m-code .vg { color: #c7cf2f } +.m-code .vi { color: #c7cf2f } +.m-code .vm { color: #c7cf2f } +.m-code .il { color: #c7cf2f } + +.m-console .hll { background-color: #ffffcc } +.m-console .g-AnsiBlack { color: #232627 } +.m-console .g-AnsiBlue { color: #1d99f3 } +.m-console .g-AnsiBrightBlack { color: #7f8c8d; font-weight: bold } +.m-console .g-AnsiBrightBlue { color: #3daee9; font-weight: bold } +.m-console .g-AnsiBrightCyan { color: #16a085; font-weight: bold } +.m-console .g-AnsiBrightDefault { color: #ffffff; font-weight: bold } +.m-console .g-AnsiBrightGreen { color: #1cdc9a; font-weight: bold } +.m-console .g-AnsiBrightMagenta { color: #8e44ad; font-weight: bold } +.m-console .g-AnsiBrightRed { color: #c0392b; font-weight: bold } +.m-console .g-AnsiBrightWhite { color: #ffffff; font-weight: bold } +.m-console .g-AnsiBrightYellow { color: #fdbc4b; font-weight: bold } +.m-console .g-AnsiCyan { color: #1abc9c } +.m-console .g-AnsiDefault { color: #fcfcfc } +.m-console .g-AnsiGreen { color: #11d116 } +.m-console .g-AnsiMagenta { color: #9b59b6 } +.m-console .g-AnsiRed { color: #ed1515 } +.m-console .g-AnsiWhite { color: #fcfcfc } +.m-console .g-AnsiYellow { color: #f67400 } +.m-console .go { color: #fcfcfc } +.m-console .gp { color: #16a085; font-weight: bold } +.m-console .w { color: #fcfcfc } + +a.m-doc, a.m-doc-self, a.m-doc-external, +ul.m-doc li.m-doc-expansible > a:first-child, ul.m-doc li.m-doc-collapsible > a:first-child, +.m-code.m-inverted.m-doc-include > a { + text-decoration: none; +} +a.m-doc, a.m-doc-self { + font-weight: bold; +} +.m-thin a.m-doc, .m-thin a.m-doc-self { + font-weight: normal; +} +ul.m-doc li.m-doc-expansible > a:first-child, +ul.m-doc li.m-doc-collapsible > a:first-child, +ul.m-doc li.m-doc-expansible > a:first-child:hover, +ul.m-doc li.m-doc-expansible > a:first-child:focus, +ul.m-doc li.m-doc-expansible > a:first-child:active, +ul.m-doc li.m-doc-collapsible > a:first-child:hover, +ul.m-doc li.m-doc-collapsible > a:first-child:focus, +ul.m-doc li.m-doc-collapsible > a:first-child:active { + color: #dcdcdc; +} +a.m-doc-self, +ul.m-doc li.m-doc-expansible > a:first-child:before, +ul.m-doc li.m-doc-collapsible > a:first-child:before { + color: #a5c9ea; +} +a.m-doc-self:hover, a.m-doc-self:focus, a.m-doc-self:active, +ul.m-doc li.m-doc-expansible > a:first-child:hover::before, +ul.m-doc li.m-doc-expansible > a:first-child:focus::before, +ul.m-doc li.m-doc-expansible > a:first-child:active::before, +ul.m-doc li.m-doc-collapsible > a:first-child:hover::before, +ul.m-doc li.m-doc-collapsible > a:first-child:focus::before, +ul.m-doc li.m-doc-collapsible > a:first-child:active::before { + color: #dcdcdc; +} +h3 a.m-doc-external { + font-weight: normal; +} +span.m-doc-wrap-bumper { + margin-right: -1rem; +} +span.m-doc-wrap { + padding-left: 1rem; + display: inline-block; + vertical-align: text-top; + white-space: pre-line; + max-width: 100%; +} +dl.m-doc dd { + margin-bottom: 0.5rem; +} +dl.m-doc dd { + margin-left: 0; + padding-left: 2.5rem; +} +dl.m-doc dt:target, dl.m-doc dt:target + dd { + margin-left: -1.0rem; + border-left-style: solid; + border-left-width: 0.25rem; + border-color: #a5c9ea; +} +dl.m-doc dt:target { padding-left: 0.75rem; } +dl.m-doc dt:target + dd { padding-left: 3.25rem; } +ul.m-doc { + list-style: none; + margin-left: 1.0375rem; + padding-left: 0.9rem; + border-left-color: #405363; + border-left-width: 0.0625rem; + border-left-style: solid; +} +ul.m-doc li { + text-indent: -1rem; + padding-left: 1rem; +} +ul.m-doc li.m-doc-expansible > ul { + display: none; +} +ul.m-doc li.m-doc-expansible, ul.m-doc li.m-doc-collapsible { + padding-left: 0.6rem; +} +ul.m-doc li.m-doc-expansible > ul.m-doc, ul.m-doc li.m-doc-collapsible > ul.m-doc { + margin-left: 0.5rem; +} +ul.m-doc li.m-doc-expansible > a:first-child:before, ul.m-doc li.m-doc-collapsible > a:first-child:before { + background-color: #2f363f; + display: inline-block; + width: 0.4rem; + font-weight: bold; +} +ul.m-doc li.m-doc-expansible > a:first-child:before { content: '⊕'; } +ul.m-doc li.m-doc-collapsible > a:first-child:before { content: '⊖'; } +h1 .m-doc-template, h1 .m-doc-include { + font-size: 1.3rem; + font-weight: normal; +} +h1 .m-doc-include:last-child { + margin-bottom: -0.5rem; +} +h3 .m-doc-template, h3 .m-doc-include { + font-size: 1rem; + font-weight: normal; +} +.m-doc-template, dl.m-doc dd, ul.m-doc li > span.m-doc { + color: #747474; +} +dl.m-doc dd svg.m-math, ul.m-doc li > span.m-doc svg.m-math { + fill: #747474; +} +.m-doc-template a, dl.m-doc dd a, ul.m-doc li > span.m-doc a { + color: #acacac; +} +.m-doc-template a:hover, .m-doc-template a:focus, .m-doc-template a:active, +dl.m-doc dd a:hover, dl.m-doc dd a:focus, dl.m-doc dd a:active, +ul.m-doc li > span.m-doc a:hover, ul.m-doc li > span.m-doc a:focus, ul.m-doc li > span.m-doc a:active { + color: #747474; +} +.m-code.m-inverted.m-doc-include > a:link, +.m-code.m-inverted.m-doc-include > a:visited { + opacity: 0.6666; +} +.m-code.m-inverted.m-doc-include > a:hover, +.m-code.m-inverted.m-doc-include > a:focus, +.m-code.m-inverted.m-doc-include > a:active { + opacity: 1; +} +article section.m-doc-details > div { + margin-top: 0; + margin-left: 0; + margin-right: 0; + position: relative; + padding: 1rem; +} +article section.m-doc-details > div::before { + position: absolute; + content: ' '; + top: 0; + bottom: 0; + left: 0; + right: 0; + z-index: -1; + border-style: solid; + border-width: 0.125rem; + border-radius: 0.2rem; + border-color: #282e36; +} +article section.m-doc-details > div > h3:first-child { + position: relative; + margin: -1rem -1rem 1rem -1rem; + padding: 0.5rem 1rem; + background-color: #282e36; + border-top-left-radius: 0.2rem; + border-top-right-radius: 0.2rem; + border-bottom-left-radius: 0; + border-bottom-right-radius: 0; +} +article section.m-doc-details:target { + border-color: transparent; +} +article section.m-doc-details:target > div { + z-index: 1; +} +.m-container-inflatable > .m-row > [class*='m-col-'] section.m-doc-details > div { + margin-left: -1rem; + margin-right: -1rem; +} +.m-container-inflatable section.m-doc-details:target > div > h3:first-child, +.m-container-inflatable section.m-doc-details:target section > div > h3:first-child { + margin-left: -1.0rem; + border-left-style: solid; + border-left-color: #dcdcdc; + border-left-width: 0.25rem; + padding-left: 0.75rem; +} +.m-container-inflatable section.m-doc-details:target > div::before, +.m-container-inflatable section-dox-details:target section > div.m::before { + border-left-width: 0.25rem; + border-left-color: #a5c9ea; +} +a.m-doc-search-icon { + padding-left: 1rem; + padding-right: 1rem; +} +a.m-doc-search-icon svg { + fill: #ffffff; +} +body > header > nav #m-navbar-collapse a.m-doc-search-icon svg { + vertical-align: -5%; +} +a.m-doc-search-icon:focus svg, a.m-doc-search-icon:hover svg, a.m-doc-search-icon:active svg { + fill: #a5c9ea; +} +.m-doc-search { + display: none; + z-index: 10; + position: fixed; + left: 0; + right: 0; + top: 0; + bottom: 0; + background-color: rgba(34, 39, 46, 0.75); +} +.m-doc-search:target { + display: block; +} +.m-doc-search > a { + display: block; + position: absolute; + left: 0; + right: 0; + top: 0; + bottom: 0; +} +.m-doc-search-header { + margin-top: 2.5rem; + padding: 0.5rem 1rem; + height: 2rem; +} +.m-doc-search-header > div:first-child { + float: right; +} +.m-doc-search-content { + background-color: #22272e; + border-radius: 0.2rem; + padding: 1rem; +} +.m-doc-search input { + width: 100%; + height: 3rem; + font-size: 1.2rem; + border-width: 0; + color: #dcdcdc; + background-color: #34424d; + border-radius: 0.2rem; + margin-bottom: 1rem; + padding: 0 1rem; +} +.m-doc-search #search-notfound { + display: none; +} +.m-doc-search ul#search-results { + list-style-type: none; + padding-left: 0; + max-height: calc(100vh - 12.5rem); + overflow-y: auto; + display: none; +} +.m-doc-search ul#search-results li a { + display: block; + padding-left: 1rem; + padding-right: 1rem; + text-decoration: none; + width: 100%; + line-height: 1.5rem; + color: #dcdcdc; +} +.m-doc-search ul#search-results li a > div { + white-space: nowrap; + overflow: hidden; +} +.m-doc-search ul#search-results li a > div:not(.m-doc-search-alias) { + direction: rtl; +} +.m-doc-search ul#search-results li a .m-label { + float: right; + line-height: 1rem; + margin-top: 0.1rem; + margin-left: 0.25rem; +} +.m-doc-search ul#search-results li a .m-label.m-flat { + margin-right: -0.75rem; +} +.m-doc-search ul#search-results li#search-current a { + background-color: #34424d; +} +.m-doc-search ul#search-results li#search-current.m-doc-search-copied a { + background-color: #2a703f; +} +.m-doc-search-typed { + color: #5b9dd9; +} +.m-doc-search input[type="search"] { -webkit-appearance: textfield; } +.m-doc-search input[type="search"]::-webkit-search-decoration, +.m-doc-search input[type="search"]::-webkit-search-cancel-button, +.m-doc-search input[type="search"]::-webkit-search-results-button, +.m-doc-search input[type="search"]::-webkit-search-results-decoration { + display: none; +} diff --git a/docs/main_8cpp.html b/docs/main_8cpp.html new file mode 100644 index 0000000..4cb6eb7 --- /dev/null +++ b/docs/main_8cpp.html @@ -0,0 +1,100 @@ + + + + + src/main.cpp file | Skribble - Collaborative app made with Qt + + + + + + + +
+
+
+
+
+

+ src/main.cpp file +

+

Driver for Skribble.

+
+
+
+
+ + + +
+ + diff --git a/docs/main_8cpp.xml b/docs/main_8cpp.xml new file mode 100644 index 0000000..bcf8e74 --- /dev/null +++ b/docs/main_8cpp.xml @@ -0,0 +1,296 @@ + + + + main.cpp + QCommandLineOption + QCommandLineParser + QGuiApplication + QQmlApplicationEngine + QStringList + canvas.hpp + network_config.hpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + int + int main + (int argc, char *argv[]) + main + + int + argc + + + char * + argv + [] + + + + + + + + + + + +Driver for Skribble. + + + + + + diff --git a/docs/main_8cpp_source.html b/docs/main_8cpp_source.html deleted file mode 100644 index c380a23..0000000 --- a/docs/main_8cpp_source.html +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - -Skribble: src/main.cpp Source File - - - - - - - - - -
-
- - - - - - -
-
Skribble -
-
Collaborative app made with Qt
-
-
- - - - - - - - -
-
- - -
- -
- - -
-
-
-
main.cpp
-
-
-
1 #include <QCommandLineOption>
-
2 #include <QCommandLineParser>
-
3 #include <QGuiApplication>
-
4 #include <QQmlApplicationEngine>
-
5 #include <QStringList>
-
6 
-
7 #include "canvas.hpp"
-
8 #include "network_config.hpp"
-
9 
-
10 int main(int argc, char* argv[])
-
11 {
-
12  QGuiApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
-
13  QGuiApplication app{ argc, argv };
-
14  QGuiApplication::setApplicationName("Skribble");
-
15  QQmlApplicationEngine engine{};
-
16 
-
17  QCommandLineParser parser{};
-
18  parser.setApplicationDescription("What mode to run Skribble in?");
-
19  parser.addHelpOption();
-
20 
-
21  QCommandLineOption serverMode{ QStringList{} << "s"
-
22  << "server-mode",
-
23  QGuiApplication::translate(
-
24  "main", "Start in server mode") };
-
25 
-
26  parser.addOption(serverMode);
-
27 
-
28  QCommandLineOption clientMode{
-
29  QStringList{} << "c"
-
30  << "client-mode",
-
31  QGuiApplication::translate(
-
32  "main", "Start in client mode AKA connect to <server>"),
-
33  QGuiApplication::translate("main", "server")
-
34  };
-
35 
-
36  parser.addOption(clientMode);
-
37  parser.process(app);
-
38 
-
39  if(parser.isSet(serverMode)) {
-
40  qDebug() << "Server mode!";
-
41  sk::networkMode = sk::NetworkModes::SERVER;
-
42  }
-
43  else if(parser.isSet(clientMode)) {
-
44  qDebug() << "Client mode: " << parser.value(clientMode);
-
45  sk::networkMode = sk::NetworkModes::CLIENT;
-
46  sk::host_ip = parser.value(clientMode);
-
47  }
-
48  else {
-
49  sk::networkMode = sk::NetworkModes::SINGLE_USER;
-
50  }
-
51 
-
52  qmlRegisterType<sk::Canvas>("Backend.Canvas", 1, 0, "SkCanvas");
-
53 
-
54  engine.addImportPath("qrc:/qml");
-
55  engine.load(QUrl{ "qrc:/qml/main.qml" });
-
56 
-
57  return QGuiApplication::exec();
-
58 }
-
- - - - diff --git a/docs/menu.js b/docs/menu.js deleted file mode 100644 index 433c15b..0000000 --- a/docs/menu.js +++ /dev/null @@ -1,50 +0,0 @@ -/* - @licstart The following is the entire license notice for the - JavaScript code in this file. - - Copyright (C) 1997-2017 by Dimitri van Heesch - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License along - with this program; if not, write to the Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - - @licend The above is the entire license notice - for the JavaScript code in this file - */ -function initMenu(relPath,searchEnabled,serverSide,searchPage,search) { - function makeTree(data,relPath) { - var result=''; - if ('children' in data) { - result+=''; - } - return result; - } - - $('#main-nav').append(makeTree(menudata,relPath)); - $('#main-nav').children(':first').addClass('sm sm-dox').attr('id','main-menu'); - if (searchEnabled) { - if (serverSide) { - $('#main-menu').append('
  • '); - } else { - $('#main-menu').append('
  • '); - } - } - $('#main-menu').smartmenus(); -} -/* @license-end */ diff --git a/docs/menudata.js b/docs/menudata.js deleted file mode 100644 index af4aeaa..0000000 --- a/docs/menudata.js +++ /dev/null @@ -1,35 +0,0 @@ -/* -@licstart The following is the entire license notice for the -JavaScript code in this file. - -Copyright (C) 1997-2019 by Dimitri van Heesch - -This program is free software; you can redistribute it and/or modify -it under the terms of version 2 of the GNU General Public License as published by -the Free Software Foundation - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -@licend The above is the entire license notice -for the JavaScript code in this file -*/ -var menudata={children:[ -{text:"Main Page",url:"index.html"}, -{text:"Namespaces",url:"namespaces.html",children:[ -{text:"Namespace List",url:"namespaces.html"}]}, -{text:"Classes",url:"annotated.html",children:[ -{text:"Class List",url:"annotated.html"}, -{text:"Class Index",url:"classes.html"}, -{text:"Class Hierarchy",url:"inherits.html"}, -{text:"Class Members",url:"functions.html",children:[ -{text:"All",url:"functions.html"}, -{text:"Functions",url:"functions_func.html"}]}]}, -{text:"Files",url:"files.html",children:[ -{text:"File List",url:"files.html"}]}]} diff --git a/docs/message__parser_8cpp.xml b/docs/message__parser_8cpp.xml new file mode 100644 index 0000000..96b528b --- /dev/null +++ b/docs/message__parser_8cpp.xml @@ -0,0 +1,45 @@ + + + + message_parser.cpp + message_parser.hpp + string + vector + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + sk::anonymous_namespace{message_parser.cpp} + + + + + + + diff --git a/docs/message__parser_8cpp_source.html b/docs/message__parser_8cpp_source.html deleted file mode 100644 index 9b16a5e..0000000 --- a/docs/message__parser_8cpp_source.html +++ /dev/null @@ -1,163 +0,0 @@ - - - - - - - -Skribble: src/message_parser.cpp Source File - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    message_parser.cpp
    -
    -
    -
    1 #include "message_parser.hpp"
    -
    2 
    -
    3 #include <string>
    -
    4 #include <vector>
    -
    5 
    -
    6 namespace sk {
    -
    7 
    -
    8 namespace {
    -
    9 
    -
    10 auto split(std::string const& str, std::string const& pattern)
    -
    11  -> std::vector<std::string>
    -
    12 {
    -
    13  std::vector<std::string> result{};
    -
    14  std::string tmp{};
    -
    15 
    -
    16  for(char const ch : str) {
    -
    17  if(pattern.find(ch) != std::string::npos) {
    -
    18  if(!tmp.empty()) {
    -
    19  result.push_back(tmp);
    -
    20  tmp.clear();
    -
    21  }
    -
    22  }
    -
    23  else {
    -
    24  tmp.push_back(ch);
    -
    25  }
    -
    26  }
    -
    27 
    -
    28  if(!tmp.empty()) {
    -
    29  result.push_back(tmp);
    -
    30  }
    -
    31 
    -
    32  return result;
    -
    33 }
    -
    34 
    -
    35 } // namespace
    -
    36 
    -
    37 auto parse(std::string const& msg) -> std::tuple<Operation, int, int, int, int>
    -
    38 {
    -
    39  if(msg.empty()) {
    -
    40  return { Operation::NONE, 0, 0, 0, 0 };
    -
    41  }
    -
    42 
    -
    43  auto words = split(msg, " ");
    -
    44 
    -
    45  switch(words[0][0]) {
    -
    46  case 'd': {
    -
    47  return {
    -
    48  Operation::DRAW_AT, std::stoi(words[1]), std::stoi(words[2]), 0, 0
    -
    49  };
    -
    50  }
    -
    51  case 'm': {
    -
    52  return { Operation::MOUSE_RELEASED, 0, 0, 0, 0 };
    -
    53  }
    -
    54  case 'u': {
    -
    55  return { Operation::UNDO, 0, 0, 0, 0 };
    -
    56  }
    -
    57  case 'r': {
    -
    58  return { Operation::REDO, 0, 0, 0, 0 };
    -
    59  }
    -
    60  case 'c': {
    -
    61  return { Operation::CHANGE_COLOR,
    -
    62  std::stoi(words[1]),
    -
    63  std::stoi(words[2]),
    -
    64  std::stoi(words[3]),
    -
    65  std::stoi(words[4]) };
    -
    66  }
    -
    67  case 'w': {
    -
    68  return { Operation::CHANGE_WIDTH, std::stoi(words[1]), 0, 0, 0 };
    -
    69  }
    -
    70  case 'p': {
    -
    71  return { Operation::TO_PEN, 0, 0, 0, 0 };
    -
    72  }
    -
    73  case 'b': {
    -
    74  return { Operation::TO_BRUSH, 0, 0, 0, 0 };
    -
    75  }
    -
    76  default: {
    -
    77  return { Operation::NONE, 0, 0, 0, 0 };
    -
    78  }
    -
    79  }
    -
    80 }
    -
    81 
    -
    82 } // namespace sk
    -
    - - - - diff --git a/docs/message__parser_8hpp.xml b/docs/message__parser_8hpp.xml new file mode 100644 index 0000000..6324c15 --- /dev/null +++ b/docs/message__parser_8hpp.xml @@ -0,0 +1,57 @@ + + + + message_parser.hpp + string + tuple + src/canvas.cpp + src/message_parser.cpp + tests/message_parser_test.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + + + + + + + diff --git a/docs/message__parser_8hpp_source.html b/docs/message__parser_8hpp_source.html deleted file mode 100644 index aa0b9b7..0000000 --- a/docs/message__parser_8hpp_source.html +++ /dev/null @@ -1,109 +0,0 @@ - - - - - - - -Skribble: src/message_parser.hpp Source File - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    message_parser.hpp
    -
    -
    -
    1 #ifndef MESSAGE_PARSER_HPP
    -
    2 #define MESSAGE_PARSER_HPP
    -
    3 #pragma once
    -
    4 
    -
    5 #include <string>
    -
    6 #include <tuple>
    -
    7 
    -
    8 namespace sk {
    -
    9 
    -
    10 enum class Operation
    -
    11 {
    -
    12  UNDO,
    -
    13  REDO,
    -
    14  DRAW_AT,
    -
    15  MOUSE_RELEASED,
    -
    16  CHANGE_COLOR,
    -
    17  CHANGE_WIDTH,
    -
    18  TO_BRUSH,
    -
    19  TO_PEN,
    -
    20  NONE
    -
    21 };
    -
    22 
    -
    23 [[nodiscard]] auto parse(std::string const& msg)
    -
    24  -> std::tuple<Operation, int, int, int, int>;
    -
    25 
    -
    26 } // namespace sk
    -
    27 
    -
    28 #endif // !MESSAGE_PARSER_HPP
    -
    - - - - diff --git a/docs/message__parser__test_8cpp.xml b/docs/message__parser__test_8cpp.xml new file mode 100644 index 0000000..fd04209 --- /dev/null +++ b/docs/message__parser__test_8cpp.xml @@ -0,0 +1,283 @@ + + + + message_parser_test.cpp + message_parser.hpp + ostream + test.hpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + auto + auto operator<< + (std::ostream &os, sk::Operation const op) -> std::ostream & + operator<< + + std::ostream & + os + + + sk::Operation const + op + + + + + + + + + + + + TEST + ("[MessageParser] Undo") + TEST + + " Undo" + [MessageParser] + + + + + + + + + + + + TEST + ("[MessageParser] Redo") + TEST + + " Redo" + [MessageParser] + + + + + + + + + + + + TEST + ("[MessageParser] DrawAt") + TEST + + " DrawAt" + [MessageParser] + + + + + + + + + + + + TEST + ("[MessageParser] MouseReleased") + TEST + + " MouseReleased" + [MessageParser] + + + + + + + + + + + + TEST + ("[MessageParser] ChangeColor") + TEST + + " ChangeColor" + [MessageParser] + + + + + + + + + + + + TEST + ("[MessageParser] ChangeWidth") + TEST + + " ChangeWidth" + [MessageParser] + + + + + + + + + + + + TEST + ("[MessageParser] ToPen") + TEST + + " ToPen" + [MessageParser] + + + + + + + + + + + + TEST + ("[MessageParser] ToBrush") + TEST + + " ToBrush" + [MessageParser] + + + + + + + + + + + + TEST + ("[MessageParser] Junk") + TEST + + " Junk" + [MessageParser] + + + + + + + + + + + + + + + + + diff --git a/docs/message__parser__test_8cpp_source.html b/docs/message__parser__test_8cpp_source.html deleted file mode 100644 index 86c849f..0000000 --- a/docs/message__parser__test_8cpp_source.html +++ /dev/null @@ -1,259 +0,0 @@ - - - - - - - -Skribble: tests/message_parser_test.cpp Source File - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    message_parser_test.cpp
    -
    -
    -
    1 #include "message_parser.hpp"
    -
    2 
    -
    3 #include <ostream>
    -
    4 
    -
    5 auto operator<<(std::ostream& os, sk::Operation const op) -> std::ostream&
    -
    6 {
    -
    7  switch(op) {
    -
    8  case sk::Operation::DRAW_AT: {
    -
    9  return os << "DRAW_AT";
    -
    10  }
    -
    11  case sk::Operation::MOUSE_RELEASED: {
    -
    12  return os << "MOUSE_RELEASED";
    -
    13  }
    -
    14  case sk::Operation::UNDO: {
    -
    15  return os << "UNDO";
    -
    16  }
    -
    17  case sk::Operation::REDO: {
    -
    18  return os << "REDO";
    -
    19  }
    -
    20  case sk::Operation::CHANGE_COLOR: {
    -
    21  return os << "CHANGE_COLOR";
    -
    22  }
    -
    23  case sk::Operation::CHANGE_WIDTH: {
    -
    24  return os << "CHANGE_WIDTH";
    -
    25  }
    -
    26  case sk::Operation::TO_PEN: {
    -
    27  return os << "TO_PEN";
    -
    28  }
    -
    29  case sk::Operation::TO_BRUSH: {
    -
    30  return os << "TO_BRUSH";
    -
    31  }
    -
    32  default: {
    -
    33  return os << "UNKOWN_OPERATION";
    -
    34  }
    -
    35  }
    -
    36 }
    -
    37 
    -
    38 #include "test.hpp"
    -
    39 
    -
    40 TEST("[MessageParser] Undo")
    -
    41 {
    -
    42  auto const& [op, a, b, c, d] = sk::parse("u");
    -
    43 
    -
    44  ASSERT(op == sk::Operation::UNDO);
    -
    45 
    -
    46  static_cast<void>(a);
    -
    47  static_cast<void>(b);
    -
    48  static_cast<void>(c);
    -
    49  static_cast<void>(d);
    -
    50 }
    -
    51 
    -
    52 TEST("[MessageParser] Redo")
    -
    53 {
    -
    54  auto const& [op, a, b, c, d] = sk::parse("r");
    -
    55 
    -
    56  ASSERT(op == sk::Operation::REDO);
    -
    57 
    -
    58  static_cast<void>(a);
    -
    59  static_cast<void>(b);
    -
    60  static_cast<void>(c);
    -
    61  static_cast<void>(d);
    -
    62 }
    -
    63 
    -
    64 TEST("[MessageParser] DrawAt")
    -
    65 {
    -
    66  {
    -
    67  auto const& [op, a, b, c, d] = sk::parse("d 0 0");
    -
    68 
    -
    69  ASSERT(op == sk::Operation::DRAW_AT);
    -
    70  ASSERT(a == 0);
    -
    71  ASSERT(b == 0);
    -
    72 
    -
    73  static_cast<void>(c);
    -
    74  static_cast<void>(d);
    -
    75  }
    -
    76  {
    -
    77  auto const& [op, a, b, c, d] = sk::parse("d 123 -17");
    -
    78 
    -
    79  ASSERT(op == sk::Operation::DRAW_AT);
    -
    80  ASSERT(a == 123);
    -
    81  ASSERT(b == -17);
    -
    82 
    -
    83  static_cast<void>(c);
    -
    84  static_cast<void>(d);
    -
    85  }
    -
    86  {
    -
    87  auto const& [op, a, b, c, d] = sk::parse("d 330 600");
    -
    88 
    -
    89  ASSERT(op == sk::Operation::DRAW_AT);
    -
    90  ASSERT(a == 330);
    -
    91  ASSERT(b == 600);
    -
    92 
    -
    93  static_cast<void>(c);
    -
    94  static_cast<void>(d);
    -
    95  }
    -
    96 }
    -
    97 
    -
    98 TEST("[MessageParser] MouseReleased")
    -
    99 {
    -
    100  auto const& [op, a, b, c, d] = sk::parse("m");
    -
    101 
    -
    102  ASSERT(op == sk::Operation::MOUSE_RELEASED);
    -
    103 
    -
    104  static_cast<void>(a);
    -
    105  static_cast<void>(b);
    -
    106  static_cast<void>(c);
    -
    107  static_cast<void>(d);
    -
    108 }
    -
    109 
    -
    110 TEST("[MessageParser] ChangeColor")
    -
    111 {
    -
    112  {
    -
    113  auto const& [op, a, b, c, d] = sk::parse("c 0 0 0 0");
    -
    114 
    -
    115  ASSERT(op == sk::Operation::CHANGE_COLOR);
    -
    116  ASSERT(a == 0);
    -
    117  ASSERT(b == 0);
    -
    118  ASSERT(c == 0);
    -
    119  ASSERT(d == 0);
    -
    120  }
    -
    121  {
    -
    122  auto const& [op, a, b, c, d] = sk::parse("c 255 255 255 255");
    -
    123 
    -
    124  ASSERT(op == sk::Operation::CHANGE_COLOR);
    -
    125  ASSERT(a == 255);
    -
    126  ASSERT(b == 255);
    -
    127  ASSERT(c == 255);
    -
    128  ASSERT(d == 255);
    -
    129  }
    -
    130 }
    -
    131 
    -
    132 TEST("[MessageParser] ChangeWidth")
    -
    133 {
    -
    134  auto const& [op, a, b, c, d] = sk::parse("w 100");
    -
    135 
    -
    136  ASSERT(op == sk::Operation::CHANGE_WIDTH);
    -
    137  ASSERT(a == 100);
    -
    138 
    -
    139  static_cast<void>(b);
    -
    140  static_cast<void>(c);
    -
    141  static_cast<void>(d);
    -
    142 }
    -
    143 
    -
    144 TEST("[MessageParser] ToPen")
    -
    145 {
    -
    146  auto const& [op, a, b, c, d] = sk::parse("p");
    -
    147 
    -
    148  ASSERT(op == sk::Operation::TO_PEN);
    -
    149 
    -
    150  static_cast<void>(a);
    -
    151  static_cast<void>(b);
    -
    152  static_cast<void>(c);
    -
    153  static_cast<void>(d);
    -
    154 }
    -
    155 
    -
    156 TEST("[MessageParser] ToBrush")
    -
    157 {
    -
    158  auto const& [op, a, b, c, d] = sk::parse("b");
    -
    159 
    -
    160  ASSERT(op == sk::Operation::TO_BRUSH);
    -
    161 
    -
    162  static_cast<void>(a);
    -
    163  static_cast<void>(b);
    -
    164  static_cast<void>(c);
    -
    165  static_cast<void>(d);
    -
    166 }
    -
    167 
    -
    168 TEST("[MessageParser] Junk")
    -
    169 {
    -
    170  auto const& [op, a, b, c, d] =
    -
    171  sk::parse("sja;lfiqeqowfjiew f;w(*#&*((Jf'\"f}F@_P=");
    -
    172 
    -
    173  ASSERT(op == sk::Operation::NONE);
    -
    174  ASSERT(a == 0);
    -
    175  ASSERT(b == 0);
    -
    176  ASSERT(c == 0);
    -
    177  ASSERT(d == 0);
    -
    178 }
    -
    - - - - diff --git a/docs/modules.html b/docs/modules.html new file mode 100644 index 0000000..4be6a1b --- /dev/null +++ b/docs/modules.html @@ -0,0 +1,115 @@ + + + + + Skribble - Collaborative app made with Qt + + + + + + + +
    +
    +
    +
    +
    +

    Modules

    +
      +
    + +
    +
    +
    +
    + + + +
    + + diff --git a/docs/namespaceanonymous__namespace_02cached__resource__test_8cpp_03.html b/docs/namespaceanonymous__namespace_02cached__resource__test_8cpp_03.html deleted file mode 100644 index 1849811..0000000 --- a/docs/namespaceanonymous__namespace_02cached__resource__test_8cpp_03.html +++ /dev/null @@ -1,86 +0,0 @@ - - - - - - - -Skribble: anonymous_namespace{cached_resource_test.cpp} Namespace Reference - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    - -
    -
    anonymous_namespace{cached_resource_test.cpp} Namespace Reference
    -
    -
    - - - - -

    -Variables

    -auto adder = [](int& dest, int& src) -> void { dest += src; }
     
    -
    - - - - diff --git a/docs/namespaceanonymous__namespace_02cached__resource__test_8cpp_03.xml b/docs/namespaceanonymous__namespace_02cached__resource__test_8cpp_03.xml new file mode 100644 index 0000000..0a609ab --- /dev/null +++ b/docs/namespaceanonymous__namespace_02cached__resource__test_8cpp_03.xml @@ -0,0 +1,27 @@ + + + + anonymous_namespace{cached_resource_test.cpp} + + + auto + auto anonymous_namespace{cached_resource_test.cpp}::adder + + adder + = [](int& dest, int& src) -> void { dest += src; } + + + + + + + + + + + + + + + + diff --git a/docs/namespaceanonymous__namespace_02fcached__resource__test_8cpp_03.html b/docs/namespaceanonymous__namespace_02fcached__resource__test_8cpp_03.html deleted file mode 100644 index 92d6b3d..0000000 --- a/docs/namespaceanonymous__namespace_02fcached__resource__test_8cpp_03.html +++ /dev/null @@ -1,89 +0,0 @@ - - - - - - - -Skribble: anonymous_namespace{fcached_resource_test.cpp} Namespace Reference - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    - -
    -
    anonymous_namespace{fcached_resource_test.cpp} Namespace Reference
    -
    -
    - - - - - - -

    -Variables

    -auto adder = [](int& dest, int& src) -> void { dest += src; }
     
    -auto init = [](int& num) -> void { num = 0; }
     
    -
    - - - - diff --git a/docs/namespaceanonymous__namespace_02fcached__resource__test_8cpp_03.xml b/docs/namespaceanonymous__namespace_02fcached__resource__test_8cpp_03.xml new file mode 100644 index 0000000..4e0eaba --- /dev/null +++ b/docs/namespaceanonymous__namespace_02fcached__resource__test_8cpp_03.xml @@ -0,0 +1,41 @@ + + + + anonymous_namespace{fcached_resource_test.cpp} + + + auto + auto anonymous_namespace{fcached_resource_test.cpp}::adder + + adder + = [](int& dest, int& src) -> void { dest += src; } + + + + + + + + + + auto + auto anonymous_namespace{fcached_resource_test.cpp}::init + + init + = [](int& num) -> void { num = 0; } + + + + + + + + + + + + + + + + diff --git a/docs/namespaces.html b/docs/namespaces.html index 8fc367c..7441d6d 100644 --- a/docs/namespaces.html +++ b/docs/namespaces.html @@ -1,86 +1,122 @@ - - + + - - - - -Skribble: Namespace List - - - - - - - + + Skribble - Collaborative app made with Qt + + + + + -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    +
    +
    +
    +
    +
    +

    Namespaces

    +
      +
    • + namespace sk +
        +
      • namespace config All configuration for the canvas is here.
      • +
      • namespace impl Implementation details in this namespace.
      • +
      +
    • +
    + +
    +
    +
    +
    + - - - - - - - -
    - -
    -
    - - -
    - -
    - -
    -
    -
    Namespace List
    -
    -
    -
    Here is a list of all documented namespaces with brief descriptions:
    -
    - - + + +
    diff --git a/docs/namespacesk.html b/docs/namespacesk.html new file mode 100644 index 0000000..a252eaa --- /dev/null +++ b/docs/namespacesk.html @@ -0,0 +1,283 @@ + + + + + sk namespace | Skribble - Collaborative app made with Qt + + + + + + + +
    +
    +
    +
    +
    +

    + sk namespace +

    +
    +

    Contents

    + +
    +

    All Skribble functionality is implemented in this namespace.

    +
    +

    Namespaces

    +
    +
    namespace config
    +
    All configuration for the canvas is here.
    +
    namespace impl
    +
    Implementation details in this namespace.
    +
    +
    +
    +

    Classes

    +
    +
    + class AbstractNetwork +
    +
    Contains all common events for a client/server.
    +
    + class BrushMode +
    +
    Implements drawing with a brush.
    +
    +
    template<typename T, typename Traits = ResourceTraits<T>>
    + class CachedResource +
    +
    Another utility that can manage undo/redo.
    +
    + class Canvas +
    +
    The class where all the magic happens.
    +
    + class Client +
    +
    Implements AbstractNetwork for a client.
    +
    + class DrawHistory +
    +
    A manager that correctly stores history about modifications to a canvas, even if multiple users are drawing.
    +
    + class DrawMode +
    +
    Defines methods for drawing with different instruments.
    +
    + class DummyNetwork +
    +
    Implement AbstractNetwork for single-user mode.
    +
    +
    template<typename T, typename Traits = FResTraits<T>>
    + class FCachedResource +
    +
    Class that manages undo/redo.
    +
    +
    template<typename T>
    + struct FResTraits +
    +
    Parameters for FCachedResource.
    +
    + class NetworkFactory +
    +
    Helper implementing Factory design pattern.
    +
    + class PenMode +
    +
    Implements drawing with a pen.
    +
    +
    template<typename T>
    + struct ResourceTraits +
    +
    Parameters for CachedResource.
    +
    + class Server +
    +
    Implements AbstractNetwork for a server.
    +
    +
    +
    +

    Enums

    +
    +
    + enum class Operation { UNDO, + REDO, + DRAW_AT, + MOUSE_RELEASED, + CHANGE_COLOR, + CHANGE_WIDTH, + TO_BRUSH, + TO_PEN, + NONE } +
    +
    Possible kinds of messages to be sent over the network.
    +
    + enum class NetworkModes { SINGLE_USER, + CLIENT, + SERVER } +
    +
    Connection type.
    +
    +
    +
    +

    Functions

    +
    +
    +
    template<std::size_t N, typename... Ts>
    + auto format(char const (&fmt)[N], + Ts && ... args) -> std::string -> auto +
    +
    Helper to format strings sanely.
    +
    + auto parse(std::string const& msg) -> std::tuple< Operation, int, int, int, int > -> auto +
    +
    Helper to parse messages received over the network.
    +
    +
    +
    +

    Variables

    +
    +
    + int port constexpr +
    +
    Communication port used by Skribble clients/servers.
    +
    + QString host_ip +
    +
    Stores the ip to connect to.
    +
    + NetworkModes networkMode +
    +
    Stores the connection mode the user has requested.
    +
    +
    +
    +

    Function documentation

    +
    +

    +
    + template<std::size_t N, typename... Ts> +
    + auto sk::format(char const (&fmt)[N], + Ts && ... args) -> std::string +

    +

    Helper to format strings sanely.

    +

    Inspired by python's print("{} {} {}", ...).

    You can use it like this: sk::format("%1 %2 %1", "abra", "cad"); // returns "abracadabra"

    Being equivalent to: "{0} {1} {0}".format("abra", "cad")

    This function is quite an abuse of templates and fold expressions :D

    +
    +
    +

    + auto sk::parse(std::string const& msg) -> std::tuple< Operation, int, int, int, int > +

    +

    Helper to parse messages received over the network.

    + + + + + + + +
    Returns{ kind, a, b, c, d }
    +

    The structure of a message is kind a b c d, where:

    • kind cand be one of 'u' - undo, 'r' - redo, 'd' - draw_at, 'm' - mouse released, 'c' - change color, 'w' - change width, 'b' - to brush, 'p' - to pen
    • a is an integer used by 'w', 'd', 'c'
    • b is an integer used by 'd', 'c'
    • c and d are only used by 'c'
    +
    +
    +
    +

    Variable documentation

    +
    +

    + QString sk::host_ip +

    +

    Stores the ip to connect to.

    + +
    +
    +
    +
    +
    +
    + + + +
    + + diff --git a/docs/namespacesk.xml b/docs/namespacesk.xml new file mode 100644 index 0000000..afff2f7 --- /dev/null +++ b/docs/namespacesk.xml @@ -0,0 +1,473 @@ + + + + sk + sk::AbstractNetwork + sk::BrushMode + sk::CachedResource + sk::Canvas + sk::Client + sk::DrawHistory + sk::DrawMode + sk::DummyNetwork + sk::FCachedResource + sk::FResTraits + sk::NetworkFactory + sk::PenMode + sk::ResourceTraits + sk::Server + sk::anonymous_namespace{abstract_network.cpp} + sk::anonymous_namespace{message_parser.cpp} + sk::config + sk::impl + + + + Operation + + UNDO + + + + + + + REDO + + + + + + + DRAW_AT + + + + + + + MOUSE_RELEASED + + + + + + + CHANGE_COLOR + + + + + + + CHANGE_WIDTH + + + + + + + TO_BRUSH + + + + + + + TO_PEN + + + + + + + NONE + + + + + + +Possible kinds of messages to be sent over the network. + + + + + + + + + + NetworkModes + + SINGLE_USER + + + + + + + CLIENT + + + + + + + SERVER + + + + + + +Connection type. + + + + + + + + + + + constexpr int + constexpr int sk::port + + port + = 7654 + +Communication port used by Skribble clients/servers. + + + + + + + + + QString + QString sk::host_ip + + host_ip + {} + +Stores the ip to connect to. + + +Used only by clients. + + + + + + + + + NetworkModes + NetworkModes sk::networkMode + + networkMode + = NetworkModes::SINGLE_USER + +Stores the connection mode the user has requested. + + + + + + + + + + + auto + auto sk::makeDrawMode + (QPen &&pen) -> std::unique_ptr< PenMode > + makeDrawMode + + QPen && + pen + + + + + + + + + + + auto + auto sk::makeDrawMode + (QBrush &&brush) -> std::unique_ptr< BrushMode > + makeDrawMode + + QBrush && + brush + + + + + + + + + + + auto + auto sk::makeDrawMode + (PenMode &&pen) -> std::unique_ptr< PenMode > + makeDrawMode + + PenMode && + pen + + + + + + + + + + + auto + auto sk::makeDrawMode + (BrushMode &&brush) -> std::unique_ptr< BrushMode > + makeDrawMode + + BrushMode && + brush + + + + + + + + + + + + + std::size_t + N + N + + + typename... + Ts + Ts + + + auto + auto sk::format + (char const (&fmt)[N], Ts &&... args) -> std::string + format + + char const (&) + fmt + [N] + + + Ts &&... + args + + +Helper to format strings sanely. + + +Inspired by python's print("{} {} {}", ...). +You can use it like this: sk::format("%1%2%1","abra","cad");//returns"abracadabra" + +Being equivalent to: "{0}{1}{0}".format("abra","cad") + +This function is quite an abuse of templates and fold expressions :D + + + + + + + + + std::size_t + N + N + + + typename... + Ts + Ts + + + auto + auto sk::printTo + (std::ostream &os, char const (&fmt)[N], Ts &&... args) -> void + printTo + + std::ostream & + os + + + char const (&) + fmt + [N] + + + Ts &&... + args + + + + + + + + + + + + + std::size_t + N + N + + + typename... + Ts + Ts + + + auto + auto sk::printlnTo + (std::ostream &os, char const (&fmt)[N], Ts &&... args) -> void + printlnTo + + std::ostream & + os + + + char const (&) + fmt + [N] + + + Ts &&... + args + + + + + + + + + + + + + std::size_t + N + N + + + typename... + Ts + Ts + + + auto + auto sk::print + (char const (&fmt)[N], Ts &&... args) -> void + print + + char const (&) + fmt + [N] + + + Ts &&... + args + + + + + + + + + + + + + std::size_t + N + N + + + typename... + Ts + Ts + + + auto + auto sk::println + (char const (&fmt)[N], Ts &&... args) -> void + println + + char const (&) + fmt + [N] + + + Ts &&... + args + + + + + + + + + + + auto + auto sk::parse + (std::string const &msg) -> std::tuple< Operation, int, int, int, int > + parse + + std::string const & + msg + + +Helper to parse messages received over the network. + + +The structure of a message is kind a b c d, where: +kind cand be one of 'u' - undo, 'r' - redo, 'd' - draw_at, 'm' - mouse released, 'c' - change color, 'w' - change width, 'b' - to brush, 'p' - to pen +a is an integer used by 'w', 'd', 'c' +b is an integer used by 'd', 'c' +c and d are only used by 'c' + + +{ kind, a, b, c, d } + + + + + + + + + + + +All Skribble functionality is implemented in this namespace. + + + + diff --git a/docs/namespacesk_1_1anonymous__namespace_02abstract__network_8cpp_03.html b/docs/namespacesk_1_1anonymous__namespace_02abstract__network_8cpp_03.html deleted file mode 100644 index 80077c6..0000000 --- a/docs/namespacesk_1_1anonymous__namespace_02abstract__network_8cpp_03.html +++ /dev/null @@ -1,90 +0,0 @@ - - - - - - - -Skribble: sk::anonymous_namespace{abstract_network.cpp} Namespace Reference - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    - -
    -
    sk::anonymous_namespace{abstract_network.cpp} Namespace Reference
    -
    -
    - - - - -

    -Functions

    -auto handleWrite (QTcpSocket &socket) -> void
     
    -
    - - - - diff --git a/docs/namespacesk_1_1anonymous__namespace_02abstract__network_8cpp_03.xml b/docs/namespacesk_1_1anonymous__namespace_02abstract__network_8cpp_03.xml new file mode 100644 index 0000000..001bea9 --- /dev/null +++ b/docs/namespacesk_1_1anonymous__namespace_02abstract__network_8cpp_03.xml @@ -0,0 +1,30 @@ + + + + sk::anonymous_namespace{abstract_network.cpp} + + + auto + auto sk::anonymous_namespace{abstract_network.cpp}::handleWrite + (QTcpSocket &socket) -> void + handleWrite + + QTcpSocket & + socket + + + + + + + + + + + + + + + + + diff --git a/docs/namespacesk_1_1anonymous__namespace_02message__parser_8cpp_03.html b/docs/namespacesk_1_1anonymous__namespace_02message__parser_8cpp_03.html deleted file mode 100644 index f9ba863..0000000 --- a/docs/namespacesk_1_1anonymous__namespace_02message__parser_8cpp_03.html +++ /dev/null @@ -1,90 +0,0 @@ - - - - - - - -Skribble: sk::anonymous_namespace{message_parser.cpp} Namespace Reference - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    - -
    -
    sk::anonymous_namespace{message_parser.cpp} Namespace Reference
    -
    -
    - - - - -

    -Functions

    -auto split (std::string const &str, std::string const &pattern) -> std::vector< std::string >
     
    -
    - - - - diff --git a/docs/namespacesk_1_1anonymous__namespace_02message__parser_8cpp_03.xml b/docs/namespacesk_1_1anonymous__namespace_02message__parser_8cpp_03.xml new file mode 100644 index 0000000..0311adb --- /dev/null +++ b/docs/namespacesk_1_1anonymous__namespace_02message__parser_8cpp_03.xml @@ -0,0 +1,34 @@ + + + + sk::anonymous_namespace{message_parser.cpp} + + + auto + auto sk::anonymous_namespace{message_parser.cpp}::split + (std::string const &str, std::string const &pattern) -> std::vector< std::string > + split + + std::string const & + str + + + std::string const & + pattern + + + + + + + + + + + + + + + + + diff --git a/docs/namespacesk_1_1config.html b/docs/namespacesk_1_1config.html new file mode 100644 index 0000000..4c1efbe --- /dev/null +++ b/docs/namespacesk_1_1config.html @@ -0,0 +1,124 @@ + + + + + sk::config namespace | Skribble - Collaborative app made with Qt + + + + + + + +
    +
    +
    +
    +
    +

    + sk::config namespace +

    +

    All configuration for the canvas is here.

    +
    +

    Contents

    + +
    +
    +

    Variables

    +
    +
    + int width constexpr +
    +
    Width of the canvas.
    +
    + int height constexpr +
    +
    Height of the canvas.
    +
    +
    +
    +
    +
    +
    + + + +
    + + diff --git a/docs/namespacesk_1_1config.xml b/docs/namespacesk_1_1config.xml new file mode 100644 index 0000000..fb61afe --- /dev/null +++ b/docs/namespacesk_1_1config.xml @@ -0,0 +1,44 @@ + + + + sk::config + + + constexpr int + constexpr int sk::config::width + + width + = 400 + +Width of the canvas. + + + + + + + + + constexpr int + constexpr int sk::config::height + + height + = 600 + +Height of the canvas. + + + + + + + + + +All configuration for the canvas is here. + + + + + + diff --git a/docs/namespacesk_1_1impl.html b/docs/namespacesk_1_1impl.html new file mode 100644 index 0000000..dfe3934 --- /dev/null +++ b/docs/namespacesk_1_1impl.html @@ -0,0 +1,120 @@ + + + + + sk::impl namespace | Skribble - Collaborative app made with Qt + + + + + + + +
    +
    +
    +
    +
    +

    + sk::impl namespace +

    +

    Implementation details in this namespace.

    +
    +

    Contents

    + +
    +
    +

    Classes

    +
    +
    + class CachedLayers +
    +
    A helper class that wraps FCachedResource and represents modifications to a batch of layers.
    +
    +
    +
    +
    +
    +
    + + + +
    + + diff --git a/docs/namespacesk_1_1impl.xml b/docs/namespacesk_1_1impl.xml new file mode 100644 index 0000000..19a7ab0 --- /dev/null +++ b/docs/namespacesk_1_1impl.xml @@ -0,0 +1,13 @@ + + + + sk::impl + sk::impl::CachedLayers + +Implementation details in this namespace. + + + + + + diff --git a/docs/nav_f.png b/docs/nav_f.png deleted file mode 100644 index 72a58a5..0000000 Binary files a/docs/nav_f.png and /dev/null differ diff --git a/docs/nav_g.png b/docs/nav_g.png deleted file mode 100644 index 2093a23..0000000 Binary files a/docs/nav_g.png and /dev/null differ diff --git a/docs/nav_h.png b/docs/nav_h.png deleted file mode 100644 index 33389b1..0000000 Binary files a/docs/nav_h.png and /dev/null differ diff --git a/docs/network__config_8hpp.xml b/docs/network__config_8hpp.xml new file mode 100644 index 0000000..13dc401 --- /dev/null +++ b/docs/network__config_8hpp.xml @@ -0,0 +1,76 @@ + + + + network_config.hpp + QString + src/canvas.cpp + src/network_factory.hpp + src/client.cpp + src/main.cpp + src/network_factory.cpp + src/server.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + + + + + + + diff --git a/docs/network__config_8hpp_source.html b/docs/network__config_8hpp_source.html deleted file mode 100644 index 3ad46aa..0000000 --- a/docs/network__config_8hpp_source.html +++ /dev/null @@ -1,104 +0,0 @@ - - - - - - - -Skribble: src/network_config.hpp Source File - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    network_config.hpp
    -
    -
    -
    1 #ifndef NETWORK_CONFIG_HPP
    -
    2 #define NETWORK_CONFIG_HPP
    -
    3 #pragma once
    -
    4 
    -
    5 #include <QString>
    -
    6 
    -
    7 namespace sk {
    -
    8 
    -
    9 inline constexpr int port = 7654;
    -
    10 inline QString host_ip{};
    -
    11 
    -
    12 enum class NetworkModes
    -
    13 {
    -
    14  SINGLE_USER,
    -
    15  CLIENT,
    -
    16  SERVER
    -
    17 };
    -
    18 
    -
    19 inline NetworkModes networkMode = NetworkModes::SINGLE_USER;
    -
    20 
    -
    21 } // namespace sk
    -
    22 
    -
    23 #endif // !NETWORK_CONFIG_HPP
    -
    - - - - diff --git a/docs/network__factory_8cpp.xml b/docs/network__factory_8cpp.xml new file mode 100644 index 0000000..b7964c4 --- /dev/null +++ b/docs/network__factory_8cpp.xml @@ -0,0 +1,111 @@ + + + + network_factory.cpp + network_factory.hpp + network_config.hpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + + + + + + + diff --git a/docs/network__factory_8cpp_source.html b/docs/network__factory_8cpp_source.html deleted file mode 100644 index 2de751a..0000000 --- a/docs/network__factory_8cpp_source.html +++ /dev/null @@ -1,106 +0,0 @@ - - - - - - - -Skribble: src/network_factory.cpp Source File - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    network_factory.cpp
    -
    -
    -
    1 #include "network_factory.hpp"
    -
    2 #include "network_config.hpp"
    -
    3 
    -
    4 namespace sk {
    -
    5 
    -
    6 auto NetworkFactory::create(sk::NetworkModes const mode)
    -
    7  -> std::unique_ptr<AbstractNetwork>
    -
    8 {
    -
    9  switch(mode) {
    -
    10  case sk::NetworkModes::SINGLE_USER: {
    -
    11  return std::make_unique<DummyNetwork>();
    -
    12  }
    -
    13  case sk::NetworkModes::CLIENT: {
    -
    14  return std::make_unique<Client>(sk::host_ip);
    -
    15  }
    -
    16  case sk::NetworkModes::SERVER: {
    -
    17  return std::make_unique<Server>();
    -
    18  }
    -
    19  default: {
    -
    20  return nullptr;
    -
    21  }
    -
    22  }
    -
    23 }
    -
    24 
    -
    25 } // namespace sk
    -
    - - - - diff --git a/docs/network__factory_8hpp.xml b/docs/network__factory_8hpp.xml new file mode 100644 index 0000000..f428bd0 --- /dev/null +++ b/docs/network__factory_8hpp.xml @@ -0,0 +1,127 @@ + + + + network_factory.hpp + client.hpp + dummy_network.hpp + network_config.hpp + server.hpp + memory + src/canvas.cpp + src/network_factory.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::NetworkFactory + sk + + + + + + + diff --git a/docs/network__factory_8hpp_source.html b/docs/network__factory_8hpp_source.html deleted file mode 100644 index 3d036bb..0000000 --- a/docs/network__factory_8hpp_source.html +++ /dev/null @@ -1,105 +0,0 @@ - - - - - - - -Skribble: src/network_factory.hpp Source File - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    network_factory.hpp
    -
    -
    -
    1 #ifndef NETWORK_FACTORY_HPP
    -
    2 #define NETWORK_FACTORY_HPP
    -
    3 #pragma once
    -
    4 
    -
    5 #include "client.hpp"
    -
    6 #include "dummy_network.hpp"
    -
    7 #include "network_config.hpp"
    -
    8 #include "server.hpp"
    -
    9 
    -
    10 #include <memory>
    -
    11 
    -
    12 namespace sk {
    -
    13 
    - -
    15 {
    -
    16 public:
    -
    17  static auto create(sk::NetworkModes const mode)
    -
    18  -> std::unique_ptr<AbstractNetwork>;
    -
    19 };
    -
    20 
    -
    21 } // namespace sk
    -
    22 
    -
    23 #endif // !NETWORK_FACTORY_HPP
    -
    - - - - - diff --git a/docs/open.png b/docs/open.png deleted file mode 100644 index 30f75c7..0000000 Binary files a/docs/open.png and /dev/null differ diff --git a/docs/pages.html b/docs/pages.html new file mode 100644 index 0000000..7bbe492 --- /dev/null +++ b/docs/pages.html @@ -0,0 +1,115 @@ + + + + + Skribble - Collaborative app made with Qt + + + + + + + +
    +
    +
    +
    +
    +

    Pages

    +
      +
    + +
    +
    +
    +
    + + + +
    + + diff --git a/docs/search-v1.js b/docs/search-v1.js new file mode 100644 index 0000000..a4f9a43 --- /dev/null +++ b/docs/search-v1.js @@ -0,0 +1,783 @@ +/* + This file is part of m.css. + + Copyright © 2017, 2018, 2019 Vladimír Vondruš + + Permission is hereby granted, free of charge, to any person obtaining a + copy of this software and associated documentation files (the "Software"), + to deal in the Software without restriction, including without limitation + the rights to use, copy, modify, merge, publish, distribute, sublicense, + and/or sell copies of the Software, and to permit persons to whom the + Software is furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included + in all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + DEALINGS IN THE SOFTWARE. +*/ + +"use strict"; /* it summons the Cthulhu in a proper way, they say */ + +var Search = { + formatVersion: 1, /* the data filename contains this number too */ + + dataSize: 0, /* used mainly by tests, not here */ + symbolCount: '…', + trie: null, + map: null, + typeMap: null, + maxResults: 0, + + /* Always contains at least the root node offset and then one node offset + per entered character */ + searchString: '', + searchStack: [], + + /* So items don't get selected right away when a cursor is over results but + only after mouse moves */ + mouseMovedSinceLastRender: false, + + /* Whether we can go back in history in order to hide the search box or + not. We can't do that if we arrived directly on #search from outside. */ + canGoBackToHideSearch: false, + + /* Autocompletion in the input field is whitelisted only for character + input (so not deletion, cut, or anything else). This is flipped in the + onkeypress event and reset after each oninput event. */ + autocompleteNextInputEvent: false, + + init: function(buffer, maxResults) { + let view = new DataView(buffer); + + /* The file is too short to contain at least the headers and empty + sections */ + if(view.byteLength < 26) { + console.error("Search data too short"); + return false; + } + + if(view.getUint8(0) != 'M'.charCodeAt(0) || + view.getUint8(1) != 'C'.charCodeAt(0) || + view.getUint8(2) != 'S'.charCodeAt(0)) { + console.error("Invalid search data signature"); + return false; + } + + if(view.getUint8(3) != this.formatVersion) { + console.error("Invalid search data version"); + return false; + } + + /* Separate the data into the trie and the result map */ + let mapOffset = view.getUint32(6, true); + let typeMapOffset = view.getUint32(10, true); + this.trie = new DataView(buffer, 14, mapOffset - 14); + this.map = new DataView(buffer, mapOffset, typeMapOffset - mapOffset); + this.typeMap = new DataView(buffer, typeMapOffset); + + /* Set initial properties */ + this.dataSize = buffer.byteLength; + this.symbolCount = view.getUint16(4, true) + " symbols (" + Math.round(this.dataSize/102.4)/10 + " kB)"; + this.maxResults = maxResults ? maxResults : 100; + this.searchString = ''; + this.searchStack = [this.trie.getUint32(0, true)]; + + /* istanbul ignore if */ + if(typeof document !== 'undefined') { + document.getElementById('search-symbolcount').innerHTML = this.symbolCount; + document.getElementById('search-input').disabled = false; + document.getElementById('search-input').placeholder = "Type something here …"; + document.getElementById('search-input').focus(); + + /* Search for the input value (there might be something already, + for example when going back in the browser) */ + let value = document.getElementById('search-input').value; + + /* Otherwise check the GET parameters for `q` and fill the input + with that */ + if(!value.length) { + var args = decodeURIComponent(window.location.search.substr(1)).trim().split('&'); + for(var i = 0; i != args.length; ++i) { + if(args[i].substring(0, 2) != 'q=') continue; + + value = document.getElementById('search-input').value = args[i].substring(2); + break; + } + } + + if(value.length) Search.searchAndRender(value); + } + + return true; + }, + + download: /* istanbul ignore next */ function(url) { + var req = window.XDomainRequest ? new XDomainRequest() : new XMLHttpRequest(); + if(!req) return; + + req.open("GET", url, true); + req.responseType = 'arraybuffer'; + req.onreadystatechange = function() { + if(req.readyState != 4) return; + + Search.init(req.response); + } + req.send(); + }, + + base85decode: function(base85string) { + function charValue(char) { + if(char >= 48 && char < 58) /* 0-9 -> 0-9 */ + return char - 48 + 0; + if(char >= 65 && char < 91) /* A-Z -> 10-35 */ + return char - 65 + 10; + if(char >= 97 && char < 123) /* a-z -> 36-61 */ + return char - 97 + 36; + if(char == 33) /* ! -> 62 */ + return 62; + /* skipping 34 (') */ + if(char >= 35 && char < 39) /* #-& -> 63-66 */ + return char - 35 + 63; + /* skipping 39 (") */ + if(char >= 40 && char < 44) /* (-+ -> 67-70 */ + return char - 40 + 67; + /* skipping 44 (,) */ + if(char == 45) /* - -> 71 */ + return 71; + if(char >= 59 && char < 65) /* ;-@ -> 72-77 */ + return char - 59 + 72; + if(char >= 94 && char < 97) /* ^-` -> 78-80 */ + return char - 94 + 78; + if(char >= 123 && char < 127) /* {-~ -> 81-84 */ + return char - 123 + 81; + + return 0; /* Interpret padding values as zeros */ + } + + /* Pad the string for easier decode later. We don't read past the file + end, so it doesn't matter what garbage is there. */ + if(base85string.length % 5) { + console.log("Expected properly padded base85 data"); + return; + } + + let buffer = new ArrayBuffer(base85string.length*4/5); + let data8 = new DataView(buffer); + for(let i = 0; i < base85string.length; i += 5) { + let char1 = charValue(base85string.charCodeAt(i + 0)); + let char2 = charValue(base85string.charCodeAt(i + 1)); + let char3 = charValue(base85string.charCodeAt(i + 2)); + let char4 = charValue(base85string.charCodeAt(i + 3)); + let char5 = charValue(base85string.charCodeAt(i + 4)); + + data8.setUint32(i*4/5, char5 + + char4*85 + + char3*85*85 + + char2*85*85*85 + + char1*85*85*85*85, false); /* BE, yes */ + } + + return buffer; + }, + + load: function(base85string) { + return this.init(this.base85decode(base85string)); + }, + + /* http://ecmanaut.blogspot.com/2006/07/encoding-decoding-utf8-in-javascript.html */ + toUtf8: function(string) { return unescape(encodeURIComponent(string)); }, + fromUtf8: function(string) { return decodeURIComponent(escape(string)); }, + + autocompletedCharsToUtf8: function(chars) { + /* Strip incomplete UTF-8 chars from the autocompletion end */ + for(let i = chars.length - 1; i >= 0; --i) { + let c = chars[i]; + + /* We're safe, finish */ + if( + /* ASCII value at the end */ + (c < 128 && i + 1 == chars.length) || + + /* Full two-byte character at the end */ + ((c & 0xe0) == 0xc0 && i + 2 == chars.length) || + + /* Full three-byte character at the end */ + ((c & 0xf0) == 0xe0 && i + 3 == chars.length) || + + /* Full four-byte character at the end */ + ((c & 0xf8) == 0xf0 && i + 4 == chars.length) + ) break; + + /* Continuing UTF-8 character, go further back */ + if((c & 0xc0) == 0x80) continue; + + /* Otherwise the character is not complete, drop it from the end */ + chars.length = i; + break; + } + + /* Convert the autocompleted UTF-8 sequence to a string */ + let suggestedTabAutocompletionString = ''; + for(let i = 0; i != chars.length; ++i) + suggestedTabAutocompletionString += String.fromCharCode(chars[i]); + return suggestedTabAutocompletionString; + }, + + /* Returns the values in UTF-8, but input is in whatever shitty 16bit + encoding JS has */ + search: function(searchString) { + /* Normalize the search string first, convert to UTF-8 and trim spaces + from the left. From the right they're trimmed only if nothing is + found, see below. */ + searchString = this.toUtf8(searchString.toLowerCase().replace(/^\s+/,'')); + + /* TODO: maybe i could make use of InputEvent.data and others here */ + + /* Find longest common prefix of previous and current value so we don't + need to needlessly search again */ + let max = Math.min(searchString.length, this.searchString.length); + let commonPrefix = 0; + for(; commonPrefix != max; ++commonPrefix) + if(searchString[commonPrefix] != this.searchString[commonPrefix]) break; + + /* Drop items off the stack if it has has more than is needed for the + common prefix (it needs to have at least one item, though) */ + if(commonPrefix + 1 < this.searchStack.length) + this.searchStack.splice(commonPrefix + 1, this.searchStack.length - commonPrefix - 1); + + /* Add new characters from the search string */ + let foundPrefix = commonPrefix; + for(; foundPrefix != searchString.length; ++foundPrefix) { + /* Calculate offset and count of children */ + let offset = this.searchStack[this.searchStack.length - 1]; + let relChildOffset = 2 + this.trie.getUint8(offset)*2; + + /* Calculate child count. If there's a lot of results, the count + "leaks over" to the child count storage. */ + let resultCount = this.trie.getUint8(offset); + let childCount = this.trie.getUint8(offset + 1); + if(resultCount & 0x80) { + resultCount = (resultCount & 0x7f) | ((childCount & 0xf0) << 3); + childCount = childCount & 0x0f; + } + + /* Go through all children and find the next offset */ + let childOffset = offset + relChildOffset; + let found = false; + for(let j = 0; j != childCount; ++j) { + if(String.fromCharCode(this.trie.getUint8(childOffset + j*4 + 3)) != searchString[foundPrefix]) + continue; + + this.searchStack.push(this.trie.getUint32(childOffset + j*4, true) & 0x007fffff); + found = true; + break; + } + + /* Character not found */ + if(!found) { + /* If we found everything except spaces at the end, pretend the + spaces aren't there. On the other hand, we *do* want to + try searching with the spaces first -- it can narrow down + the result list for page names or show subpages (which are + after a lookahead barrier that's a space). */ + if(!searchString.substr(foundPrefix).trim().length) + searchString = searchString.substr(0, foundPrefix); + + break; + } + } + + /* Save the whole found prefix for next time */ + this.searchString = searchString.substr(0, foundPrefix); + + /* If the whole thing was not found, return an empty result and offer + external search */ + if(foundPrefix != searchString.length) { + /* istanbul ignore if */ + if(typeof document !== 'undefined') { + let link = document.getElementById('search-external'); + if(link) + link.href = link.dataset.searchEngine.replace('{query}', encodeURIComponent(searchString)); + } + return [[], '']; + } + + /* Otherwise gather the results */ + let suggestedTabAutocompletionChars = []; + let results = []; + let leaves = [[this.searchStack[this.searchStack.length - 1], 0]]; + while(leaves.length) { + /* Pop offset from the queue */ + let current = leaves.shift(); + let offset = current[0]; + let suffixLength = current[1]; + + /* Calculate child count. If there's a lot of results, the count + "leaks over" to the child count storage. */ + /* TODO: hmmm. this is helluvalot duplicated code. hmm. */ + let resultCount = this.trie.getUint8(offset); + let childCount = this.trie.getUint8(offset + 1); + if(resultCount & 0x80) { + resultCount = (resultCount & 0x7f) | ((childCount & 0xf0) << 3); + childCount = childCount & 0x0f; + } + + /* Populate the results with all values associated with this node */ + for(let i = 0; i != resultCount; ++i) { + let index = this.trie.getUint16(offset + 2 + i*2, true); + results.push(this.gatherResult(index, suffixLength, 0xffffff)); /* should be enough haha */ + + /* 'nuff said. */ + if(results.length >= this.maxResults) + return [results, this.autocompletedCharsToUtf8(suggestedTabAutocompletionChars)]; + } + + /* Dig deeper */ + /* TODO: hmmm. this is helluvalot duplicated code. hmm. */ + let relChildOffset = 2 + this.trie.getUint8(offset)*2; + let childOffset = offset + relChildOffset; + for(let j = 0; j != childCount; ++j) { + let offsetBarrier = this.trie.getUint32(childOffset + j*4, true); + + /* Lookahead barrier, don't dig deeper */ + if(offsetBarrier & 0x00800000) continue; + + /* Append to the queue */ + leaves.push([offsetBarrier & 0x007fffff, suffixLength + 1]); + + /* We don't have anything yet and this is the only path + forward, add the char to suggested Tab autocompletion. Can't + extract it from the leftmost 8 bits of offsetBarrier because + that would make it negative, have to load as Uint8 instead. + Also can't use String.fromCharCode(), because later doing + str.charCodeAt() would give me back UTF-16 values, which is + absolutely unwanted when all I want is check for truncated + UTF-8. */ + if(!results.length && leaves.length == 1 && childCount == 1) + suggestedTabAutocompletionChars.push(this.trie.getUint8(childOffset + j*4 + 3)); + } + } + + return [results, this.autocompletedCharsToUtf8(suggestedTabAutocompletionChars)]; + }, + + gatherResult: function(index, suffixLength, maxUrlPrefix) { + let flags = this.map.getUint8(index*4 + 3); + let resultOffset = this.map.getUint32(index*4, true) & 0x00ffffff; + + /* The result is an alias, parse the aliased prefix */ + let aliasedIndex = null; + if((flags & 0xf0) == 0x00) { + aliasedIndex = this.map.getUint16(resultOffset, true); + resultOffset += 2; + } + + /* The result has a prefix, parse that first, recursively */ + let name = ''; + let url = ''; + if(flags & (1 << 3)) { + let prefixIndex = this.map.getUint16(resultOffset, true); + let prefixUrlPrefixLength = Math.min(this.map.getUint8(resultOffset + 2), maxUrlPrefix); + + let prefix = this.gatherResult(prefixIndex, 0 /*ignored*/, prefixUrlPrefixLength); + name = prefix.name; + url = prefix.url; + + resultOffset += 3; + } + + /* The result has a suffix, extract its length */ + let resultSuffixLength = 0; + if(flags & (1 << 0)) { + resultSuffixLength = this.map.getUint8(resultOffset); + ++resultOffset; + } + + let nextResultOffset = this.map.getUint32((index + 1)*4, true) & 0x00ffffff; + + /* Extract name */ + let j = resultOffset; + for(; j != nextResultOffset; ++j) { + let c = this.map.getUint8(j); + + /* End of null-delimited name */ + if(!c) { + ++j; + break; /* null-delimited */ + } + + name += String.fromCharCode(c); /* eheh. IS THIS FAST?! */ + } + + /* The result is an alias and we're not deep inside resolving a prefix, + extract the aliased name and URL */ + /* TODO: this abuses 0xffffff to guess how the call stack is deep and + that's just wrong, fix! */ + if(aliasedIndex != null && maxUrlPrefix == 0xffffff) { + let alias = this.gatherResult(aliasedIndex, 0 /* ignored */, 0xffffff); /* should be enough haha */ + + /* Keeping in UTF-8, as we need that for proper slicing (and concatenating) */ + return {name: name, + alias: alias.name, + url: alias.url, + flags: alias.flags, + cssClass: alias.cssClass, + typeName: alias.typeName, + suffixLength: suffixLength + resultSuffixLength}; + } + + /* Otherwise extract URL from here */ + let max = Math.min(j + maxUrlPrefix - url.length, nextResultOffset); + for(; j != max; ++j) { + url += String.fromCharCode(this.map.getUint8(j)); + } + + /* This is an alias, return what we have, without parsed CSS class and + type name as those are retrieved from the final target type */ + if(!(flags >> 4)) + return {name: name, + url: url, + flags: flags & 0x0f, + suffixLength: suffixLength + resultSuffixLength}; + + /* Otherwise, get CSS class and type name for the result label */ + let typeMapIndex = (flags >> 4) - 1; + let cssClass = [ + /* Keep in sync with _search.py */ + 'm-default', + 'm-primary', + 'm-success', + 'm-warning', + 'm-danger', + 'm-info', + 'm-dim' + ][this.typeMap.getUint8(typeMapIndex*2)]; + let typeNameOffset = this.typeMap.getUint8(typeMapIndex*2 + 1); + let nextTypeNameOffset = this.typeMap.getUint8((typeMapIndex + 1)*2 + 1); + let typeName = ''; + for(let j = typeNameOffset; j != nextTypeNameOffset; ++j) + typeName += String.fromCharCode(this.typeMap.getUint8(j)); + + /* Keeping in UTF-8, as we need that for proper slicing (and + concatenating). Strip the type from the flags, as it's now expressed + directly. */ + return {name: name, + url: url, + flags: flags & 0x0f, + cssClass: cssClass, + typeName: typeName, + suffixLength: suffixLength + resultSuffixLength}; + }, + + escape: function(name) { + return name.replace(/[\"&<>]/g, function (a) { + return { '"': '"', '&': '&', '<': '<', '>': '>' }[a]; + }); + }, + escapeForRtl: function(name) { + /* Besides the obvious escaping of HTML entities we also need + to escape punctuation, because due to the RTL hack to cut + text off on left side the punctuation characters get + reordered (of course). Prepending ‎ works for most + characters, parentheses we need to *soak* in it. But only + the right ones. And that for some reason needs to be also for &. + Huh. https://en.wikipedia.org/wiki/Right-to-left_mark */ + return this.escape(name).replace(/[:=]/g, '‎$&').replace(/(\)|>|&|\/)/g, '‎$&‎'); + }, + + renderResults: /* istanbul ignore next */ function(resultsSuggestedTabAutocompletion) { + if(!this.searchString.length) { + document.getElementById('search-help').style.display = 'block'; + document.getElementById('search-results').style.display = 'none'; + document.getElementById('search-notfound').style.display = 'none'; + return; + } + + document.getElementById('search-help').style.display = 'none'; + + /* Results found */ + if(resultsSuggestedTabAutocompletion[0].length) { + let results = resultsSuggestedTabAutocompletion[0]; + + document.getElementById('search-results').style.display = 'block'; + document.getElementById('search-notfound').style.display = 'none'; + + let list = ''; + for(let i = 0; i != results.length; ++i) { + /* Labels + */ + list += '
    ' + results[i].typeName + '
    ' + (results[i].flags & 2 ? '
    deprecated
    ' : '') + (results[i].flags & 4 ? '
    deleted
    ' : ''); + + /* Render the alias (cut off from the right) */ + if(results[i].alias) { + list += '
    ' + this.escape(results[i].name.substr(0, results[i].name.length - this.searchString.length - results[i].suffixLength)) + '' + this.escape(results[i].name.substr(results[i].name.length - this.searchString.length - results[i].suffixLength, this.searchString.length)) + '' + this.escapeForRtl(results[i].name.substr(results[i].name.length - results[i].suffixLength)) + ': ' + this.escape(results[i].alias) + ''; + + /* Render the normal thing (cut off from the left, have to + escape for RTL) */ + } else { + list += '
    ' + this.escapeForRtl(results[i].name.substr(0, results[i].name.length - this.searchString.length - results[i].suffixLength)) + '' + this.escapeForRtl(results[i].name.substr(results[i].name.length - this.searchString.length - results[i].suffixLength, this.searchString.length)) + '' + this.escapeForRtl(results[i].name.substr(results[i].name.length - results[i].suffixLength)); + } + + /* The closing */ + list += '
    '; + } + document.getElementById('search-results').innerHTML = this.fromUtf8(list); + document.getElementById('search-current').scrollIntoView(true); + + /* Append the suggested tab autocompletion, if any, and if the user + didn't just delete it */ + let searchInput = document.getElementById('search-input'); + if(this.autocompleteNextInputEvent && resultsSuggestedTabAutocompletion[1].length && searchInput.selectionEnd == searchInput.value.length) { + let suggestedTabAutocompletion = this.fromUtf8(resultsSuggestedTabAutocompletion[1]); + + let lengthBefore = searchInput.value.length; + searchInput.value += suggestedTabAutocompletion; + searchInput.setSelectionRange(lengthBefore, searchInput.value.length); + } + + /* Nothing found */ + } else { + document.getElementById('search-results').innerHTML = ''; + document.getElementById('search-results').style.display = 'none'; + document.getElementById('search-notfound').style.display = 'block'; + } + + /* Don't allow things to be selected just by motionless mouse cursor + suddenly appearing over a search result */ + this.mouseMovedSinceLastRender = false; + + /* Reset autocompletion, if it was allowed. It'll get whitelisted next + time a character gets inserted. */ + this.autocompleteNextInputEvent = false; + }, + + searchAndRender: /* istanbul ignore next */ function(value) { + let prev = performance.now(); + let results = this.search(value); + let after = performance.now(); + this.renderResults(results); + if(this.searchString.length) { + document.getElementById('search-symbolcount').innerHTML = + results[0].length + (results[0].length >= this.maxResults ? '+' : '') + " results (" + Math.round((after - prev)*10)/10 + " ms)"; + } else + document.getElementById('search-symbolcount').innerHTML = this.symbolCount; + }, +}; + +/* istanbul ignore next */ +function selectResult(event) { + if(!Search.mouseMovedSinceLastRender) return; + + if(event.currentTarget.parentNode.id == 'search-current') return; + + let current = document.getElementById('search-current'); + current.removeAttribute('id'); + event.currentTarget.parentNode.id = 'search-current'; +} + +/* This is separated from showSearch() because we need non-destructive behavior + when appearing directly on a URL with #search */ /* istanbul ignore next */ +function updateForSearchVisible() { + /* Prevent accidental scrolling of the body, prevent page layout jumps */ + let scrolledBodyWidth = document.body.offsetWidth; + document.body.style.overflow = 'hidden'; + document.body.style.paddingRight = (document.body.offsetWidth - scrolledBodyWidth) + 'px'; + + document.getElementById('search-input').value = ''; + document.getElementById('search-input').focus(); + document.getElementById('search-results').style.display = 'none'; + document.getElementById('search-notfound').style.display = 'none'; + document.getElementById('search-help').style.display = 'block'; +} + +/* istanbul ignore next */ +function showSearch() { + window.location.hash = '#search'; + Search.canGoBackToHideSearch = true; + + updateForSearchVisible(); + document.getElementById('search-symbolcount').innerHTML = Search.symbolCount; + return false; +} + +/* istanbul ignore next */ +function hideSearch() { + /* If the search box was opened using showSearch(), we can go back in the + history. Otherwise (for example when we landed to #search from a + bookmark or another server), going back would not do the right thing and + in that case we simply replace the current history state. */ + if(Search.canGoBackToHideSearch) { + Search.canGoBackToHideSearch = false; + window.history.back(); + } else { + window.location.hash = '#!'; + window.history.replaceState('', '', window.location.pathname); + } + + /* Restore scrollbar, prevent page layout jumps */ + document.body.style.overflow = 'auto'; + document.body.style.paddingRight = '0'; + + return false; +} + +/* istanbul ignore next */ +function copyToKeyboard(text) { + /* Append to the popup, appending to document.body would cause it to + scroll when focused */ + let searchPopup = document.getElementsByClassName('m-doc-search')[0]; + let textarea = document.createElement("textarea"); + textarea.value = text; + searchPopup.appendChild(textarea); + textarea.focus(); + textarea.select(); + + document.execCommand('copy'); + + searchPopup.removeChild(textarea); + document.getElementById('search-input').focus(); +} + +/* Only in case we're running in a browser. Why a simple if(document) doesn't + work is beyond me. */ /* istanbul ignore if */ +if(typeof document !== 'undefined') { + document.getElementById('search-input').oninput = function(event) { + Search.searchAndRender(document.getElementById('search-input').value); + }; + + document.onkeydown = function(event) { + /* Search shown */ + if(window.location.hash == '#search') { + /* Close the search */ + if(event.key == 'Escape') { + hideSearch(); + + /* Focus the search input, if not already, using T or Tab */ + } else if((!document.activeElement || document.activeElement.id != 'search-input') && (event.key.toLowerCase() == 't' || event.key == 'Tab') && !event.shiftKey && !event.ctrlKey && !event.altKey && !event.metaKey) { + document.getElementById('search-input').focus(); + return false; /* so T doesn't get entered into the box */ + + /* Fill in the autocompleted selection */ + } else if(event.key == 'Tab' && !event.shiftKey && !event.ctrlKey && !event.altKey && !event.metaKey) { + /* But only if the input has selection at the end */ + let input = document.getElementById('search-input'); + if(input.selectionEnd == input.value.length && input.selectionStart != input.selectionEnd) + input.setSelectionRange(input.value.length, input.value.length); + + /* Select next item */ + } else if(event.key == 'ArrowDown') { + let current = document.getElementById('search-current'); + if(current) { + let next = current.nextSibling; + if(next) { + current.id = ''; + next.id = 'search-current'; + next.scrollIntoView(false); + } + } + return false; /* so the keypress doesn't affect input cursor */ + + /* Select prev item */ + } else if(event.key == 'ArrowUp') { + let current = document.getElementById('search-current'); + if(current) { + let prev = current.previousSibling; + if(prev) { + current.id = ''; + prev.id = 'search-current'; + prev.scrollIntoView(false); + } + } + return false; /* so the keypress doesn't affect input cursor */ + + /* Go to result (if any) */ + } else if(event.key == 'Enter') { + let result = document.getElementById('search-current'); + if(result) { + result.firstElementChild.click(); + + /* We might be staying on the same page, so restore scrollbar, + and prevent page layout jumps */ + document.body.style.overflow = 'auto'; + document.body.style.paddingRight = '0'; + } + + return false; /* so the form doesn't get sent */ + + /* Copy (Markdown) link to keyboard */ + } else if((event.key.toLowerCase() == 'l' || event.key.toLowerCase() == 'm') && event.metaKey) { + let result = document.getElementById('search-current'); + if(result) { + let plain = event.key.toLowerCase() == 'l'; + let link = plain ? result.firstElementChild.href : + '[' + result.firstElementChild.dataset.mdLinkTitle + '](' + result.firstElementChild.href + ')'; + + copyToKeyboard(link); + + /* Add CSS class to the element for visual feedback (this + will get removed on keyup), but only if it's not already + there (in case of key repeat, e.g.) */ + if(result.className.indexOf('m-doc-search-copied') == -1) + result.className += ' m-doc-search-copied'; + console.log("Copied " + (plain ? "link" : "Markdown link") + " to " + result.firstElementChild.dataset.mdLinkTitle); + } + + return false; /* so L doesn't get entered into the box */ + + /* Looks like the user is inserting some text (and not cutting, + copying or whatever), allow autocompletion for the new + character. The oninput event resets this back to false, so this + basically whitelists only keyboard input, including Shift-key + and special chars using right Alt (or equivalent on Mac), but + excluding Ctrl-key, which is usually not for text input. In the + worst case the autocompletion won't be allowed ever, which is + much more acceptable behavior than having no ability to disable + it and annoying the users. See also this WONTFIX Android bug: + https://bugs.chromium.org/p/chromium/issues/detail?id=118639 */ + } else if(event.key != 'Backspace' && event.key != 'Delete' && !event.metaKey && (!event.ctrlKey || event.altKey)) { + Search.autocompleteNextInputEvent = true; + /* Otherwise reset the flag, because when the user would press e.g. + the 'a' key and then e.g. ArrowRight (which doesn't trigger + oninput), a Backspace after would still result in + autocompleteNextInputEvent, because nothing reset it back. */ + } else { + Search.autocompleteNextInputEvent = false; + } + + /* Search hidden */ + } else { + /* Open the search on the T or Tab key */ + if((event.key.toLowerCase() == 't' || event.key == 'Tab') && !event.shiftKey && !event.ctrlKey && !event.altKey && !event.metaKey) { + showSearch(); + return false; /* so T doesn't get entered into the box */ + } + } + }; + + document.onkeyup = function(event) { + /* Remove highlight after key is released after a link copy */ + if((event.key.toLowerCase() == 'l' || event.key.toLowerCase() == 'm') && event.metaKey) { + let result = document.getElementById('search-current'); + if(result) result.className = result.className.replace(' m-doc-search-copied', ''); + } + }; + + /* Allow selecting items by mouse hover only after it moves once the + results are populated. This prevents a random item getting selected if + the cursor is left motionless over the result area. */ + document.getElementById('search-results').onmousemove = function() { + Search.mouseMovedSinceLastRender = true; + }; + + /* If #search is already present in the URL, hide the scrollbar etc. for a + consistent experience */ + if(window.location.hash == '#search') updateForSearchVisible(); +} + +/* For Node.js testing */ /* istanbul ignore else */ +if(typeof module !== 'undefined') { module.exports = { Search: Search }; } diff --git a/docs/search/all_0.html b/docs/search/all_0.html deleted file mode 100644 index 26dd244..0000000 --- a/docs/search/all_0.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/all_0.js b/docs/search/all_0.js deleted file mode 100644 index 2c55331..0000000 --- a/docs/search/all_0.js +++ /dev/null @@ -1,6 +0,0 @@ -var searchData= -[ - ['abstractnetwork_0',['AbstractNetwork',['../classsk_1_1AbstractNetwork.html',1,'sk']]], - ['anonymous_5fnamespace_7bcached_5fresource_5ftest_2ecpp_7d_1',['anonymous_namespace{cached_resource_test.cpp}',['../namespaceanonymous__namespace_02cached__resource__test_8cpp_03.html',1,'']]], - ['anonymous_5fnamespace_7bfcached_5fresource_5ftest_2ecpp_7d_2',['anonymous_namespace{fcached_resource_test.cpp}',['../namespaceanonymous__namespace_02fcached__resource__test_8cpp_03.html',1,'']]] -]; diff --git a/docs/search/all_1.html b/docs/search/all_1.html deleted file mode 100644 index 8eb215b..0000000 --- a/docs/search/all_1.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/all_1.js b/docs/search/all_1.js deleted file mode 100644 index 60ce825..0000000 --- a/docs/search/all_1.js +++ /dev/null @@ -1,4 +0,0 @@ -var searchData= -[ - ['brushmode_3',['BrushMode',['../classsk_1_1BrushMode.html',1,'sk']]] -]; diff --git a/docs/search/all_2.html b/docs/search/all_2.html deleted file mode 100644 index b26d916..0000000 --- a/docs/search/all_2.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/all_2.js b/docs/search/all_2.js deleted file mode 100644 index 8ee0256..0000000 --- a/docs/search/all_2.js +++ /dev/null @@ -1,8 +0,0 @@ -var searchData= -[ - ['cachedlayers_4',['CachedLayers',['../classsk_1_1impl_1_1CachedLayers.html',1,'sk::impl']]], - ['cachedresource_5',['CachedResource',['../classsk_1_1CachedResource.html',1,'sk']]], - ['cachedresource_3c_20sk_3a_3aimpl_3a_3acachedlayers_20_3e_6',['CachedResource< sk::impl::CachedLayers >',['../classsk_1_1CachedResource.html',1,'sk']]], - ['canvas_7',['Canvas',['../classsk_1_1Canvas.html',1,'sk']]], - ['client_8',['Client',['../classsk_1_1Client.html',1,'sk']]] -]; diff --git a/docs/search/all_3.html b/docs/search/all_3.html deleted file mode 100644 index b61b96f..0000000 --- a/docs/search/all_3.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/all_3.js b/docs/search/all_3.js deleted file mode 100644 index 37dff5d..0000000 --- a/docs/search/all_3.js +++ /dev/null @@ -1,7 +0,0 @@ -var searchData= -[ - ['drawhistory_9',['DrawHistory',['../classsk_1_1DrawHistory.html',1,'sk']]], - ['drawmode_10',['DrawMode',['../classsk_1_1DrawMode.html',1,'sk']]], - ['dummy_11',['Dummy',['../classDummy.html',1,'']]], - ['dummynetwork_12',['DummyNetwork',['../classsk_1_1DummyNetwork.html',1,'sk']]] -]; diff --git a/docs/search/all_4.html b/docs/search/all_4.html deleted file mode 100644 index 06de155..0000000 --- a/docs/search/all_4.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/all_4.js b/docs/search/all_4.js deleted file mode 100644 index 4ff2483..0000000 --- a/docs/search/all_4.js +++ /dev/null @@ -1,10 +0,0 @@ -var searchData= -[ - ['fcachedresource_13',['FCachedResource',['../classsk_1_1FCachedResource.html',1,'sk']]], - ['fcachedresource_3c_20qpixmap_20_3e_14',['FCachedResource< QPixmap >',['../classsk_1_1FCachedResource.html',1,'sk']]], - ['frestraits_15',['FResTraits',['../structsk_1_1FResTraits.html',1,'sk']]], - ['frestraits_3c_20qpixmap_20_3e_16',['FResTraits< QPixmap >',['../structsk_1_1FResTraits.html',1,'sk']]], - ['ftrait2_17',['FTrait2',['../structFTrait2.html',1,'']]], - ['ftraits_18',['FTraits',['../structFTraits.html',1,'']]], - ['ftraits3_19',['FTraits3',['../structFTraits3.html',1,'']]] -]; diff --git a/docs/search/all_5.html b/docs/search/all_5.html deleted file mode 100644 index 2544c4e..0000000 --- a/docs/search/all_5.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/all_5.js b/docs/search/all_5.js deleted file mode 100644 index 344aa20..0000000 --- a/docs/search/all_5.js +++ /dev/null @@ -1,4 +0,0 @@ -var searchData= -[ - ['networkfactory_20',['NetworkFactory',['../classsk_1_1NetworkFactory.html',1,'sk']]] -]; diff --git a/docs/search/all_6.html b/docs/search/all_6.html deleted file mode 100644 index 43f14ea..0000000 --- a/docs/search/all_6.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/all_6.js b/docs/search/all_6.js deleted file mode 100644 index 1e14618..0000000 --- a/docs/search/all_6.js +++ /dev/null @@ -1,5 +0,0 @@ -var searchData= -[ - ['penmode_21',['PenMode',['../classsk_1_1PenMode.html',1,'sk']]], - ['proxy_22',['Proxy',['../structTestBase_1_1Proxy.html',1,'TestBase']]] -]; diff --git a/docs/search/all_7.html b/docs/search/all_7.html deleted file mode 100644 index af52f82..0000000 --- a/docs/search/all_7.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/all_7.js b/docs/search/all_7.js deleted file mode 100644 index a1b0f61..0000000 --- a/docs/search/all_7.js +++ /dev/null @@ -1,6 +0,0 @@ -var searchData= -[ - ['redo_23',['redo',['../classsk_1_1CachedResource.html#aa0d083c1c8dead354f6d6576f533d84f',1,'sk::CachedResource']]], - ['resourcetraits_24',['ResourceTraits',['../structsk_1_1ResourceTraits.html',1,'sk']]], - ['resourcetraits_3c_20sk_3a_3aimpl_3a_3acachedlayers_20_3e_25',['ResourceTraits< sk::impl::CachedLayers >',['../structsk_1_1ResourceTraits.html',1,'sk']]] -]; diff --git a/docs/search/all_8.html b/docs/search/all_8.html deleted file mode 100644 index cf2b5df..0000000 --- a/docs/search/all_8.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/all_8.js b/docs/search/all_8.js deleted file mode 100644 index 78bf80c..0000000 --- a/docs/search/all_8.js +++ /dev/null @@ -1,6 +0,0 @@ -var searchData= -[ - ['anonymous_5fnamespace_7babstract_5fnetwork_2ecpp_7d_26',['anonymous_namespace{abstract_network.cpp}',['../namespacesk_1_1anonymous__namespace_02abstract__network_8cpp_03.html',1,'sk']]], - ['anonymous_5fnamespace_7bmessage_5fparser_2ecpp_7d_27',['anonymous_namespace{message_parser.cpp}',['../namespacesk_1_1anonymous__namespace_02message__parser_8cpp_03.html',1,'sk']]], - ['server_28',['Server',['../classsk_1_1Server.html',1,'sk']]] -]; diff --git a/docs/search/all_9.html b/docs/search/all_9.html deleted file mode 100644 index 690785a..0000000 --- a/docs/search/all_9.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/all_9.js b/docs/search/all_9.js deleted file mode 100644 index 802f346..0000000 --- a/docs/search/all_9.js +++ /dev/null @@ -1,6 +0,0 @@ -var searchData= -[ - ['testbase_29',['TestBase',['../classTestBase.html',1,'']]], - ['trait2_30',['Trait2',['../structTrait2.html',1,'']]], - ['traits3_31',['Traits3',['../structTraits3.html',1,'']]] -]; diff --git a/docs/search/all_a.html b/docs/search/all_a.html deleted file mode 100644 index f2f3d3a..0000000 --- a/docs/search/all_a.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/all_a.js b/docs/search/all_a.js deleted file mode 100644 index 2ff5964..0000000 --- a/docs/search/all_a.js +++ /dev/null @@ -1,4 +0,0 @@ -var searchData= -[ - ['undo_32',['undo',['../classsk_1_1CachedResource.html#a5170bedab3b28e24b51b6ac9092006d7',1,'sk::CachedResource::undo()'],['../classsk_1_1impl_1_1CachedLayers.html#abf3cc642d50ee9f80e6e2f1559494e77',1,'sk::impl::CachedLayers::undo()']]] -]; diff --git a/docs/search/classes_0.html b/docs/search/classes_0.html deleted file mode 100644 index f7e4c14..0000000 --- a/docs/search/classes_0.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/classes_0.js b/docs/search/classes_0.js deleted file mode 100644 index 8515810..0000000 --- a/docs/search/classes_0.js +++ /dev/null @@ -1,4 +0,0 @@ -var searchData= -[ - ['abstractnetwork_33',['AbstractNetwork',['../classsk_1_1AbstractNetwork.html',1,'sk']]] -]; diff --git a/docs/search/classes_1.html b/docs/search/classes_1.html deleted file mode 100644 index c7ff4b3..0000000 --- a/docs/search/classes_1.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/classes_1.js b/docs/search/classes_1.js deleted file mode 100644 index 0591e43..0000000 --- a/docs/search/classes_1.js +++ /dev/null @@ -1,4 +0,0 @@ -var searchData= -[ - ['brushmode_34',['BrushMode',['../classsk_1_1BrushMode.html',1,'sk']]] -]; diff --git a/docs/search/classes_2.html b/docs/search/classes_2.html deleted file mode 100644 index 0d1e8a0..0000000 --- a/docs/search/classes_2.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/classes_2.js b/docs/search/classes_2.js deleted file mode 100644 index ea87630..0000000 --- a/docs/search/classes_2.js +++ /dev/null @@ -1,8 +0,0 @@ -var searchData= -[ - ['cachedlayers_35',['CachedLayers',['../classsk_1_1impl_1_1CachedLayers.html',1,'sk::impl']]], - ['cachedresource_36',['CachedResource',['../classsk_1_1CachedResource.html',1,'sk']]], - ['cachedresource_3c_20sk_3a_3aimpl_3a_3acachedlayers_20_3e_37',['CachedResource< sk::impl::CachedLayers >',['../classsk_1_1CachedResource.html',1,'sk']]], - ['canvas_38',['Canvas',['../classsk_1_1Canvas.html',1,'sk']]], - ['client_39',['Client',['../classsk_1_1Client.html',1,'sk']]] -]; diff --git a/docs/search/classes_3.html b/docs/search/classes_3.html deleted file mode 100644 index 2102545..0000000 --- a/docs/search/classes_3.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/classes_3.js b/docs/search/classes_3.js deleted file mode 100644 index 508a1bf..0000000 --- a/docs/search/classes_3.js +++ /dev/null @@ -1,7 +0,0 @@ -var searchData= -[ - ['drawhistory_40',['DrawHistory',['../classsk_1_1DrawHistory.html',1,'sk']]], - ['drawmode_41',['DrawMode',['../classsk_1_1DrawMode.html',1,'sk']]], - ['dummy_42',['Dummy',['../classDummy.html',1,'']]], - ['dummynetwork_43',['DummyNetwork',['../classsk_1_1DummyNetwork.html',1,'sk']]] -]; diff --git a/docs/search/classes_4.html b/docs/search/classes_4.html deleted file mode 100644 index 095ab59..0000000 --- a/docs/search/classes_4.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/classes_4.js b/docs/search/classes_4.js deleted file mode 100644 index 4c7b013..0000000 --- a/docs/search/classes_4.js +++ /dev/null @@ -1,10 +0,0 @@ -var searchData= -[ - ['fcachedresource_44',['FCachedResource',['../classsk_1_1FCachedResource.html',1,'sk']]], - ['fcachedresource_3c_20qpixmap_20_3e_45',['FCachedResource< QPixmap >',['../classsk_1_1FCachedResource.html',1,'sk']]], - ['frestraits_46',['FResTraits',['../structsk_1_1FResTraits.html',1,'sk']]], - ['frestraits_3c_20qpixmap_20_3e_47',['FResTraits< QPixmap >',['../structsk_1_1FResTraits.html',1,'sk']]], - ['ftrait2_48',['FTrait2',['../structFTrait2.html',1,'']]], - ['ftraits_49',['FTraits',['../structFTraits.html',1,'']]], - ['ftraits3_50',['FTraits3',['../structFTraits3.html',1,'']]] -]; diff --git a/docs/search/classes_5.html b/docs/search/classes_5.html deleted file mode 100644 index fc9cdc9..0000000 --- a/docs/search/classes_5.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/classes_5.js b/docs/search/classes_5.js deleted file mode 100644 index 52e67be..0000000 --- a/docs/search/classes_5.js +++ /dev/null @@ -1,4 +0,0 @@ -var searchData= -[ - ['networkfactory_51',['NetworkFactory',['../classsk_1_1NetworkFactory.html',1,'sk']]] -]; diff --git a/docs/search/classes_6.html b/docs/search/classes_6.html deleted file mode 100644 index 1ecfddd..0000000 --- a/docs/search/classes_6.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/classes_6.js b/docs/search/classes_6.js deleted file mode 100644 index 847933d..0000000 --- a/docs/search/classes_6.js +++ /dev/null @@ -1,5 +0,0 @@ -var searchData= -[ - ['penmode_52',['PenMode',['../classsk_1_1PenMode.html',1,'sk']]], - ['proxy_53',['Proxy',['../structTestBase_1_1Proxy.html',1,'TestBase']]] -]; diff --git a/docs/search/classes_7.html b/docs/search/classes_7.html deleted file mode 100644 index 0fc6fc3..0000000 --- a/docs/search/classes_7.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/classes_7.js b/docs/search/classes_7.js deleted file mode 100644 index 070566a..0000000 --- a/docs/search/classes_7.js +++ /dev/null @@ -1,5 +0,0 @@ -var searchData= -[ - ['resourcetraits_54',['ResourceTraits',['../structsk_1_1ResourceTraits.html',1,'sk']]], - ['resourcetraits_3c_20sk_3a_3aimpl_3a_3acachedlayers_20_3e_55',['ResourceTraits< sk::impl::CachedLayers >',['../structsk_1_1ResourceTraits.html',1,'sk']]] -]; diff --git a/docs/search/classes_8.html b/docs/search/classes_8.html deleted file mode 100644 index ac8af7d..0000000 --- a/docs/search/classes_8.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/classes_8.js b/docs/search/classes_8.js deleted file mode 100644 index c2249cb..0000000 --- a/docs/search/classes_8.js +++ /dev/null @@ -1,4 +0,0 @@ -var searchData= -[ - ['server_56',['Server',['../classsk_1_1Server.html',1,'sk']]] -]; diff --git a/docs/search/classes_9.html b/docs/search/classes_9.html deleted file mode 100644 index 86cad04..0000000 --- a/docs/search/classes_9.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/classes_9.js b/docs/search/classes_9.js deleted file mode 100644 index fb1edc6..0000000 --- a/docs/search/classes_9.js +++ /dev/null @@ -1,6 +0,0 @@ -var searchData= -[ - ['testbase_57',['TestBase',['../classTestBase.html',1,'']]], - ['trait2_58',['Trait2',['../structTrait2.html',1,'']]], - ['traits3_59',['Traits3',['../structTraits3.html',1,'']]] -]; diff --git a/docs/search/close.png b/docs/search/close.png deleted file mode 100644 index 9342d3d..0000000 Binary files a/docs/search/close.png and /dev/null differ diff --git a/docs/search/functions_0.html b/docs/search/functions_0.html deleted file mode 100644 index e17c711..0000000 --- a/docs/search/functions_0.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/functions_0.js b/docs/search/functions_0.js deleted file mode 100644 index e2fcdd8..0000000 --- a/docs/search/functions_0.js +++ /dev/null @@ -1,4 +0,0 @@ -var searchData= -[ - ['redo_64',['redo',['../classsk_1_1CachedResource.html#aa0d083c1c8dead354f6d6576f533d84f',1,'sk::CachedResource']]] -]; diff --git a/docs/search/functions_1.html b/docs/search/functions_1.html deleted file mode 100644 index 0ddac0a..0000000 --- a/docs/search/functions_1.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/functions_1.js b/docs/search/functions_1.js deleted file mode 100644 index cbdba0e..0000000 --- a/docs/search/functions_1.js +++ /dev/null @@ -1,4 +0,0 @@ -var searchData= -[ - ['undo_65',['undo',['../classsk_1_1CachedResource.html#a5170bedab3b28e24b51b6ac9092006d7',1,'sk::CachedResource::undo()'],['../classsk_1_1impl_1_1CachedLayers.html#abf3cc642d50ee9f80e6e2f1559494e77',1,'sk::impl::CachedLayers::undo()']]] -]; diff --git a/docs/search/mag_sel.png b/docs/search/mag_sel.png deleted file mode 100644 index 39c0ed5..0000000 Binary files a/docs/search/mag_sel.png and /dev/null differ diff --git a/docs/search/namespaces_0.html b/docs/search/namespaces_0.html deleted file mode 100644 index 76996d1..0000000 --- a/docs/search/namespaces_0.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/namespaces_0.js b/docs/search/namespaces_0.js deleted file mode 100644 index 0cf580b..0000000 --- a/docs/search/namespaces_0.js +++ /dev/null @@ -1,5 +0,0 @@ -var searchData= -[ - ['anonymous_5fnamespace_7bcached_5fresource_5ftest_2ecpp_7d_60',['anonymous_namespace{cached_resource_test.cpp}',['../namespaceanonymous__namespace_02cached__resource__test_8cpp_03.html',1,'']]], - ['anonymous_5fnamespace_7bfcached_5fresource_5ftest_2ecpp_7d_61',['anonymous_namespace{fcached_resource_test.cpp}',['../namespaceanonymous__namespace_02fcached__resource__test_8cpp_03.html',1,'']]] -]; diff --git a/docs/search/namespaces_1.html b/docs/search/namespaces_1.html deleted file mode 100644 index c69e366..0000000 --- a/docs/search/namespaces_1.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - -
    -
    Loading...
    -
    - -
    Searching...
    -
    No Matches
    - -
    - - diff --git a/docs/search/namespaces_1.js b/docs/search/namespaces_1.js deleted file mode 100644 index e6825d9..0000000 --- a/docs/search/namespaces_1.js +++ /dev/null @@ -1,5 +0,0 @@ -var searchData= -[ - ['anonymous_5fnamespace_7babstract_5fnetwork_2ecpp_7d_62',['anonymous_namespace{abstract_network.cpp}',['../namespacesk_1_1anonymous__namespace_02abstract__network_8cpp_03.html',1,'sk']]], - ['anonymous_5fnamespace_7bmessage_5fparser_2ecpp_7d_63',['anonymous_namespace{message_parser.cpp}',['../namespacesk_1_1anonymous__namespace_02message__parser_8cpp_03.html',1,'sk']]] -]; diff --git a/docs/search/nomatches.html b/docs/search/nomatches.html deleted file mode 100644 index 4377320..0000000 --- a/docs/search/nomatches.html +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - -
    -
    No Matches
    -
    - - diff --git a/docs/search/search.css b/docs/search/search.css deleted file mode 100644 index 3cf9df9..0000000 --- a/docs/search/search.css +++ /dev/null @@ -1,271 +0,0 @@ -/*---------------- Search Box */ - -#FSearchBox { - float: left; -} - -#MSearchBox { - white-space : nowrap; - float: none; - margin-top: 8px; - right: 0px; - width: 170px; - height: 24px; - z-index: 102; -} - -#MSearchBox .left -{ - display:block; - position:absolute; - left:10px; - width:20px; - height:19px; - background:url('search_l.png') no-repeat; - background-position:right; -} - -#MSearchSelect { - display:block; - position:absolute; - width:20px; - height:19px; -} - -.left #MSearchSelect { - left:4px; -} - -.right #MSearchSelect { - right:5px; -} - -#MSearchField { - display:block; - position:absolute; - height:19px; - background:url('search_m.png') repeat-x; - border:none; - width:115px; - margin-left:20px; - padding-left:4px; - color: #909090; - outline: none; - font: 9pt Arial, Verdana, sans-serif; - -webkit-border-radius: 0px; -} - -#FSearchBox #MSearchField { - margin-left:15px; -} - -#MSearchBox .right { - display:block; - position:absolute; - right:10px; - top:8px; - width:20px; - height:19px; - background:url('search_r.png') no-repeat; - background-position:left; -} - -#MSearchClose { - display: none; - position: absolute; - top: 4px; - background : none; - border: none; - margin: 0px 4px 0px 0px; - padding: 0px 0px; - outline: none; -} - -.left #MSearchClose { - left: 6px; -} - -.right #MSearchClose { - right: 2px; -} - -.MSearchBoxActive #MSearchField { - color: #000000; -} - -/*---------------- Search filter selection */ - -#MSearchSelectWindow { - display: none; - position: absolute; - left: 0; top: 0; - border: 1px solid #90A5CE; - background-color: #F9FAFC; - z-index: 10001; - padding-top: 4px; - padding-bottom: 4px; - -moz-border-radius: 4px; - -webkit-border-top-left-radius: 4px; - -webkit-border-top-right-radius: 4px; - -webkit-border-bottom-left-radius: 4px; - -webkit-border-bottom-right-radius: 4px; - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); -} - -.SelectItem { - font: 8pt Arial, Verdana, sans-serif; - padding-left: 2px; - padding-right: 12px; - border: 0px; -} - -span.SelectionMark { - margin-right: 4px; - font-family: monospace; - outline-style: none; - text-decoration: none; -} - -a.SelectItem { - display: block; - outline-style: none; - color: #000000; - text-decoration: none; - padding-left: 6px; - padding-right: 12px; -} - -a.SelectItem:focus, -a.SelectItem:active { - color: #000000; - outline-style: none; - text-decoration: none; -} - -a.SelectItem:hover { - color: #FFFFFF; - background-color: #3D578C; - outline-style: none; - text-decoration: none; - cursor: pointer; - display: block; -} - -/*---------------- Search results window */ - -iframe#MSearchResults { - width: 60ex; - height: 15em; -} - -#MSearchResultsWindow { - display: none; - position: absolute; - left: 0; top: 0; - border: 1px solid #000; - background-color: #EEF1F7; - z-index:10000; -} - -/* ----------------------------------- */ - - -#SRIndex { - clear:both; - padding-bottom: 15px; -} - -.SREntry { - font-size: 10pt; - padding-left: 1ex; -} - -.SRPage .SREntry { - font-size: 8pt; - padding: 1px 5px; -} - -body.SRPage { - margin: 5px 2px; -} - -.SRChildren { - padding-left: 3ex; padding-bottom: .5em -} - -.SRPage .SRChildren { - display: none; -} - -.SRSymbol { - font-weight: bold; - color: #425E97; - font-family: Arial, Verdana, sans-serif; - text-decoration: none; - outline: none; -} - -a.SRScope { - display: block; - color: #425E97; - font-family: Arial, Verdana, sans-serif; - text-decoration: none; - outline: none; -} - -a.SRSymbol:focus, a.SRSymbol:active, -a.SRScope:focus, a.SRScope:active { - text-decoration: underline; -} - -span.SRScope { - padding-left: 4px; -} - -.SRPage .SRStatus { - padding: 2px 5px; - font-size: 8pt; - font-style: italic; -} - -.SRResult { - display: none; -} - -DIV.searchresults { - margin-left: 10px; - margin-right: 10px; -} - -/*---------------- External search page results */ - -.searchresult { - background-color: #F0F3F8; -} - -.pages b { - color: white; - padding: 5px 5px 3px 5px; - background-image: url("../tab_a.png"); - background-repeat: repeat-x; - text-shadow: 0 1px 1px #000000; -} - -.pages { - line-height: 17px; - margin-left: 4px; - text-decoration: none; -} - -.hl { - font-weight: bold; -} - -#searchresults { - margin-bottom: 20px; -} - -.searchpages { - margin-top: 10px; -} - diff --git a/docs/search/search.js b/docs/search/search.js deleted file mode 100644 index a554ab9..0000000 --- a/docs/search/search.js +++ /dev/null @@ -1,814 +0,0 @@ -/* - @licstart The following is the entire license notice for the - JavaScript code in this file. - - Copyright (C) 1997-2017 by Dimitri van Heesch - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License along - with this program; if not, write to the Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - - @licend The above is the entire license notice - for the JavaScript code in this file - */ -function convertToId(search) -{ - var result = ''; - for (i=0;i do a search - { - this.Search(); - } - } - - this.OnSearchSelectKey = function(evt) - { - var e = (evt) ? evt : window.event; // for IE - if (e.keyCode==40 && this.searchIndex0) // Up - { - this.searchIndex--; - this.OnSelectItem(this.searchIndex); - } - else if (e.keyCode==13 || e.keyCode==27) - { - this.OnSelectItem(this.searchIndex); - this.CloseSelectionWindow(); - this.DOMSearchField().focus(); - } - return false; - } - - // --------- Actions - - // Closes the results window. - this.CloseResultsWindow = function() - { - this.DOMPopupSearchResultsWindow().style.display = 'none'; - this.DOMSearchClose().style.display = 'none'; - this.Activate(false); - } - - this.CloseSelectionWindow = function() - { - this.DOMSearchSelectWindow().style.display = 'none'; - } - - // Performs a search. - this.Search = function() - { - this.keyTimeout = 0; - - // strip leading whitespace - var searchValue = this.DOMSearchField().value.replace(/^ +/, ""); - - var code = searchValue.toLowerCase().charCodeAt(0); - var idxChar = searchValue.substr(0, 1).toLowerCase(); - if ( 0xD800 <= code && code <= 0xDBFF && searchValue > 1) // surrogate pair - { - idxChar = searchValue.substr(0, 2); - } - - var resultsPage; - var resultsPageWithSearch; - var hasResultsPage; - - var idx = indexSectionsWithContent[this.searchIndex].indexOf(idxChar); - if (idx!=-1) - { - var hexCode=idx.toString(16); - resultsPage = this.resultsPath + '/' + indexSectionNames[this.searchIndex] + '_' + hexCode + '.html'; - resultsPageWithSearch = resultsPage+'?'+escape(searchValue); - hasResultsPage = true; - } - else // nothing available for this search term - { - resultsPage = this.resultsPath + '/nomatches.html'; - resultsPageWithSearch = resultsPage; - hasResultsPage = false; - } - - window.frames.MSearchResults.location = resultsPageWithSearch; - var domPopupSearchResultsWindow = this.DOMPopupSearchResultsWindow(); - - if (domPopupSearchResultsWindow.style.display!='block') - { - var domSearchBox = this.DOMSearchBox(); - this.DOMSearchClose().style.display = 'inline'; - if (this.insideFrame) - { - var domPopupSearchResults = this.DOMPopupSearchResults(); - domPopupSearchResultsWindow.style.position = 'relative'; - domPopupSearchResultsWindow.style.display = 'block'; - var width = document.body.clientWidth - 8; // the -8 is for IE :-( - domPopupSearchResultsWindow.style.width = width + 'px'; - domPopupSearchResults.style.width = width + 'px'; - } - else - { - var domPopupSearchResults = this.DOMPopupSearchResults(); - var left = getXPos(domSearchBox) + 150; // domSearchBox.offsetWidth; - var top = getYPos(domSearchBox) + 20; // domSearchBox.offsetHeight + 1; - domPopupSearchResultsWindow.style.display = 'block'; - left -= domPopupSearchResults.offsetWidth; - domPopupSearchResultsWindow.style.top = top + 'px'; - domPopupSearchResultsWindow.style.left = left + 'px'; - } - } - - this.lastSearchValue = searchValue; - this.lastResultsPage = resultsPage; - } - - // -------- Activation Functions - - // Activates or deactivates the search panel, resetting things to - // their default values if necessary. - this.Activate = function(isActive) - { - if (isActive || // open it - this.DOMPopupSearchResultsWindow().style.display == 'block' - ) - { - this.DOMSearchBox().className = 'MSearchBoxActive'; - - var searchField = this.DOMSearchField(); - - if (searchField.value == this.searchLabel) // clear "Search" term upon entry - { - searchField.value = ''; - this.searchActive = true; - } - } - else if (!isActive) // directly remove the panel - { - this.DOMSearchBox().className = 'MSearchBoxInactive'; - this.DOMSearchField().value = this.searchLabel; - this.searchActive = false; - this.lastSearchValue = '' - this.lastResultsPage = ''; - } - } -} - -// ----------------------------------------------------------------------- - -// The class that handles everything on the search results page. -function SearchResults(name) -{ - // The number of matches from the last run of . - this.lastMatchCount = 0; - this.lastKey = 0; - this.repeatOn = false; - - // Toggles the visibility of the passed element ID. - this.FindChildElement = function(id) - { - var parentElement = document.getElementById(id); - var element = parentElement.firstChild; - - while (element && element!=parentElement) - { - if (element.nodeName == 'DIV' && element.className == 'SRChildren') - { - return element; - } - - if (element.nodeName == 'DIV' && element.hasChildNodes()) - { - element = element.firstChild; - } - else if (element.nextSibling) - { - element = element.nextSibling; - } - else - { - do - { - element = element.parentNode; - } - while (element && element!=parentElement && !element.nextSibling); - - if (element && element!=parentElement) - { - element = element.nextSibling; - } - } - } - } - - this.Toggle = function(id) - { - var element = this.FindChildElement(id); - if (element) - { - if (element.style.display == 'block') - { - element.style.display = 'none'; - } - else - { - element.style.display = 'block'; - } - } - } - - // Searches for the passed string. If there is no parameter, - // it takes it from the URL query. - // - // Always returns true, since other documents may try to call it - // and that may or may not be possible. - this.Search = function(search) - { - if (!search) // get search word from URL - { - search = window.location.search; - search = search.substring(1); // Remove the leading '?' - search = unescape(search); - } - - search = search.replace(/^ +/, ""); // strip leading spaces - search = search.replace(/ +$/, ""); // strip trailing spaces - search = search.toLowerCase(); - search = convertToId(search); - - var resultRows = document.getElementsByTagName("div"); - var matches = 0; - - var i = 0; - while (i < resultRows.length) - { - var row = resultRows.item(i); - if (row.className == "SRResult") - { - var rowMatchName = row.id.toLowerCase(); - rowMatchName = rowMatchName.replace(/^sr\d*_/, ''); // strip 'sr123_' - - if (search.length<=rowMatchName.length && - rowMatchName.substr(0, search.length)==search) - { - row.style.display = 'block'; - matches++; - } - else - { - row.style.display = 'none'; - } - } - i++; - } - document.getElementById("Searching").style.display='none'; - if (matches == 0) // no results - { - document.getElementById("NoMatches").style.display='block'; - } - else // at least one result - { - document.getElementById("NoMatches").style.display='none'; - } - this.lastMatchCount = matches; - return true; - } - - // return the first item with index index or higher that is visible - this.NavNext = function(index) - { - var focusItem; - while (1) - { - var focusName = 'Item'+index; - focusItem = document.getElementById(focusName); - if (focusItem && focusItem.parentNode.parentNode.style.display=='block') - { - break; - } - else if (!focusItem) // last element - { - break; - } - focusItem=null; - index++; - } - return focusItem; - } - - this.NavPrev = function(index) - { - var focusItem; - while (1) - { - var focusName = 'Item'+index; - focusItem = document.getElementById(focusName); - if (focusItem && focusItem.parentNode.parentNode.style.display=='block') - { - break; - } - else if (!focusItem) // last element - { - break; - } - focusItem=null; - index--; - } - return focusItem; - } - - this.ProcessKeys = function(e) - { - if (e.type == "keydown") - { - this.repeatOn = false; - this.lastKey = e.keyCode; - } - else if (e.type == "keypress") - { - if (!this.repeatOn) - { - if (this.lastKey) this.repeatOn = true; - return false; // ignore first keypress after keydown - } - } - else if (e.type == "keyup") - { - this.lastKey = 0; - this.repeatOn = false; - } - return this.lastKey!=0; - } - - this.Nav = function(evt,itemIndex) - { - var e = (evt) ? evt : window.event; // for IE - if (e.keyCode==13) return true; - if (!this.ProcessKeys(e)) return false; - - if (this.lastKey==38) // Up - { - var newIndex = itemIndex-1; - var focusItem = this.NavPrev(newIndex); - if (focusItem) - { - var child = this.FindChildElement(focusItem.parentNode.parentNode.id); - if (child && child.style.display == 'block') // children visible - { - var n=0; - var tmpElem; - while (1) // search for last child - { - tmpElem = document.getElementById('Item'+newIndex+'_c'+n); - if (tmpElem) - { - focusItem = tmpElem; - } - else // found it! - { - break; - } - n++; - } - } - } - if (focusItem) - { - focusItem.focus(); - } - else // return focus to search field - { - parent.document.getElementById("MSearchField").focus(); - } - } - else if (this.lastKey==40) // Down - { - var newIndex = itemIndex+1; - var focusItem; - var item = document.getElementById('Item'+itemIndex); - var elem = this.FindChildElement(item.parentNode.parentNode.id); - if (elem && elem.style.display == 'block') // children visible - { - focusItem = document.getElementById('Item'+itemIndex+'_c0'); - } - if (!focusItem) focusItem = this.NavNext(newIndex); - if (focusItem) focusItem.focus(); - } - else if (this.lastKey==39) // Right - { - var item = document.getElementById('Item'+itemIndex); - var elem = this.FindChildElement(item.parentNode.parentNode.id); - if (elem) elem.style.display = 'block'; - } - else if (this.lastKey==37) // Left - { - var item = document.getElementById('Item'+itemIndex); - var elem = this.FindChildElement(item.parentNode.parentNode.id); - if (elem) elem.style.display = 'none'; - } - else if (this.lastKey==27) // Escape - { - parent.searchBox.CloseResultsWindow(); - parent.document.getElementById("MSearchField").focus(); - } - else if (this.lastKey==13) // Enter - { - return true; - } - return false; - } - - this.NavChild = function(evt,itemIndex,childIndex) - { - var e = (evt) ? evt : window.event; // for IE - if (e.keyCode==13) return true; - if (!this.ProcessKeys(e)) return false; - - if (this.lastKey==38) // Up - { - if (childIndex>0) - { - var newIndex = childIndex-1; - document.getElementById('Item'+itemIndex+'_c'+newIndex).focus(); - } - else // already at first child, jump to parent - { - document.getElementById('Item'+itemIndex).focus(); - } - } - else if (this.lastKey==40) // Down - { - var newIndex = childIndex+1; - var elem = document.getElementById('Item'+itemIndex+'_c'+newIndex); - if (!elem) // last child, jump to parent next parent - { - elem = this.NavNext(itemIndex+1); - } - if (elem) - { - elem.focus(); - } - } - else if (this.lastKey==27) // Escape - { - parent.searchBox.CloseResultsWindow(); - parent.document.getElementById("MSearchField").focus(); - } - else if (this.lastKey==13) // Enter - { - return true; - } - return false; - } -} - -function setKeyActions(elem,action) -{ - elem.setAttribute('onkeydown',action); - elem.setAttribute('onkeypress',action); - elem.setAttribute('onkeyup',action); -} - -function setClassAttr(elem,attr) -{ - elem.setAttribute('class',attr); - elem.setAttribute('className',attr); -} - -function createResults() -{ - var results = document.getElementById("SRResults"); - for (var e=0; e<{AdI10_0s#g92mpWqfG7X~h5-O{00EEz0A&FH4FCWEoB;qS0RapEpaFm=00E`}0B-;Rt^ojK00FcC0A&CK9034jbO8W$mH_}~x&Z)k00F=O06GBy4gk^tfI0vH*Z}}#00H0u0Am0F<^ce500Ha)0CfNX@&N#E00H;`0CNBV{s91G009I70CE5U3IYIR009sJ0A&CH76Jfh00A5V0Am0FA_4$m0RSWb00Axn0A&CHG6Dc_00B4x0C@lbJ^}!A00Be-0CE5UN&*0700B?}0B!&QRssNN00CSA0ATuk00F=P0CWHW#sUCo00GPb0ATR4*&oGC<6d_00Arm0CE5UG6Mi_00B4y0CWHWJ_7(_00Be;0AT?DC;$NgD*#Xf0CNBVR09BI00CSB0Av6GVgmqg00K$_0A^?d0BryPZUX>o00DRd0CE5Ueggn+00D#p0CxZZiUR<200EE#0A&FH5C8xHoC5%800E!_0CWHWrUL+E00FE60BHdL5dZ)IxB~!m00F!M0B8UK!UF(j00GDY0BHaL&I15t00OcD0C&^_0B8UK+5-SO0Ra*KA00H;|0A>II{sRDR0RS=p009aF04V_hF#rw(fG7X~6a)Zt00A5X0B!&QA_M?w00Afj0AT?DGynhrGz0)C0Rb}rI0S$w00BM(0Av6GMg#z500B${0A~OJQUm~Q00CG80AT6*00D>u0CNBVjsyU20RT1t00Ei=04V_hH2|IjfG7X~qyzwD00FE70A&CHvIGEg00FoJ0ATRH~;_v_yhnc0RcAv`~-j~009C80B-;R3IzaU009sM0B!*QIsgCx90dR=0RcGxAO(OZ00AZi0B-;RE(HK&00A@w0A&FHJOBUzKm`CP0RcMzLv0BHaLjs*Z^00EQ*0Am0Fngsx500E!{0CE5UrUd|Q0RTP#00FWE04V_hJpi@^fG7X~yafPq00G1W0B-;R$^`&y00Gbi0B->RKmY&%+ywwB0RcY%;01sv00HI&0B8UK?gapJ00Hy`0Av6G`UL=K00Pzp0Am0K0CxZZ1_l6S009sN0A~OJ76t%r00A5Z0AT10B`^Sss;dU0RU7000FiJ04V_hQvkXKfG7X~zy<(i00GDb0B8UK&ISNu00Gnn0ATIVRC00Hm^0CNBV_6GoE00I050CE5U0tf(P009UH0A&CH4hR5f00LqL0B#fr0Am3FM*si;BnSX00Rct;C0BivO6aWALpa=kP00E>30AT=d00F!R0Am0F!UzCi0RR;M00GVj0CWHW(g*-<00Gzt0CfNX-UtA100HC(0Am0F>IeXM00Hm_0AT00B4&0Am0FJ_!JF00Be^0CfNXN(lgO00B@50CNBVRtW%Q0RR{P00CkN04V_h7XW4nfG7X~YzY8p00DFf0CWHWdI0CE5Uo(TYN00E>40BisOstEvZ0RSKX00FiM04V_h9{{=ufG7X~zzG0y00GDe0B-;R&Itf)00Gnq0B->RA^-pZ;0XXJ0RbTZ00B4(0CWHWMhXCB0RS2R00B}804V_h830xafG7X~TnYea00CqQ0CWHWY6<{k00D3c0BHdL9smFVd00HI-04V_hNdW2!fG7X~@CpEO00H<40A&CH{t5tj009IG0AT60AT$00Arv0B-;RG7JE700B4*0CWHWJ`4b500Be{0A~OJN(=xx0Rd$0BryPjtl^800IIG0CJQJ0CfQXCjbBeqznLV00F2B0B-;Rt_%Qa00FcN0CWHWx(one00F=Z0CE5U#tZ;u00GPl0B`{SDgXch*bD%000G<#0BHaL;tT*^00HO>0CWHW?hF8P00Hz20B->RLI3~(01W_T009II0Av6G3Jm~n009sU0BryP77YMs00A5g0CNBVA`Jj_00Afs0CE8UL;wH*Gz|bL0Rck*I1PX(00BM?0CWHWMhyUE00B%50BZmNQVjrO00CGH0B-;RUJU?q00CqT0CWHWY7GEo00D3f0A~OJb`1bJ0Rcq-d<}p)00Dvx0CE5UiVXl|00EE<0CoTYmJI-M00Ep00A&FHVgLXEs0{!q0RdqEtPOxD00FWM0CWHWx(xtj00F=a0BZmN#ti^t00GPm0B-;R(hUG}00Gzy0CWHW-VFd{0RUtG00HU^04V_hV*u_AfG7X~^bG)I00I0B0A~OJ0uBIS009UN0CNBV4h{fw009&Z0A&CH8V&$$00AHl0Av6GCJq2)00Arx0CoTYG7bP~00B4-0A&CHJ`Mn500Be}0A&CI90CWHWsty2i00FQL0Ac_PS^xlW&Hw;u8Up}kmIDB8k_Z4}TnPYjnhXGB(hLA^`V0VQE)4);q749ZwhjPc00F!X06GBxU;qFC^bP=J00H<80BisO{tf_Q009IK0Ac_E3J(Bj0Rk`p?hb%D5Dx%y00O280CbiO0CE8UPyhe{EDr#100A%$0B`^SHV*(}00BG?04@LlLJt6L00Br30BHaLP7eTK00C4F0BryPS`UCP00CeR0Am0H77qYxA`bv%W)A>z0Rk}q4g`QGUJC$Y00DXr0CWHWh7SO400K?`0CJ2E0BHaOAOHYmFaQ8=k`Dl3E(-v40sv9~0{{R4t`7hy0s&C~0syoRfG7X~x(@(r00G1g0Am0F$`1fx00Gbs0Ac_E)(-$>00G<&0Am0F;tv2}00HO^0BisO?hgQP00Hz50Br&QS^xzA0096H04V|iSpWn81`vQK009gT0B-;R77zer00A5j0B!&QA`k#|00Afv0CEEWH~?G#3jhECG!OtO0|7SxTL20GJP?2=00J%$0A)fD0B-;RP7nZO00CGK0B!^TL;yzsX8>XV00CqW04W3kLjXnqW&mLTZV-Sd00DFm0CWHWf)D^@00D>)0BZmNjt~H200EQ`0B-^Y1^@^EfB}Fgh6w<7un7QTG711>nh*eU@&*8G00E#70CWHWz7POq0{}VzUH}aM00GJn04W0jIRIS%3;@y)fG7Y0*bo43G6w*400ZO@0Ax@J0CPSL0Am0F?hpWF00Q^}0A^wW0CWHW0ucai00M*n0BrmR0CE5V5)lAost5pQ00A5k0A&CHCJ_K=00Jx#0ApeX0B!&T3=sftG7$h_A_f3xj0ga100Pbf0A=(H0B-^SB>)uw00CGL0CWHWUJ(Fp00CqX0CfNXY7qc$00D3j0Am0Gb`b!0NDlyM00Mjw0AcI|0B-;T;0ge3>e0I8-A0I8}E0IA^*0IB5<07w@Q01zq=0I6;e0I6~i0I9kV0I9wZ07&u>0I4<+0I50=07z&N001xm06IEQWo}JxWMu$jY+-YAb8BBQUolW+ZcT4wWiDuRZEP?A3pzS!ZE$P=Uol@XX>D+9E@*UZYz_b)5;{6%ZE$R1V`V~NV{0f>b08)rATBO0DIhIAAXFeG03%^zF*Z0bW;bIwIWb~3Gcq}4IWlErHDNX|IAt?1WMX9k06`EA03R7TI(2SjWpY(+WN#=bAY*TCb95kXZ)JF6WpH#LEj}P(Z*Ob>BVjc+F*IgjH#lWtF*!3aWHmQsIAdirV=*~qF*##5HZ%kPK^G1H9}+q`XJvFKDIjidWq4y{aC9IoJ|I*eCIBO0GiEYnW;bFpG+{YnVPZEoWiewhW@a=pVm4toV`61E1^_`24gen>Iyz@%bSNnxV{dMAbRceTWq4y{aC9IoJ|I*eV{dMAbRZ@GBVjXUF*h+aH8W;nVq{@7V`gGyFfuYXGBhC5nH)S$6Vr4loW;ilrG%z(102(?vXk}?b8a{yy(VRLhHYhN*6F==gZY+o^7F+*WvXk}zfVR>b8b1rCfZEO|*A38c?VPj}zM`3UPBVl4NV`MWiI5;>tG-G5iF=aD3H)LctGGjI|G%{plHDVS3A38d1VR%Dtb#8P3BVjmVV=*=}WMMR9He@(uVlp&lGc;m2H(@t4IW%QqHfAsY06IESWpi(Ja${vwa$#w7a{zO6a&=>Lb8BBQUolc;b8mHWV`WrwVQF-8E@*UZY$E^|7&N1?BVjmYI5IS0VP#`EWHDhjWi~irGc`44GB`D5FgIp5HZ>OjIu;`U7#un}b7gc_X=HS0C~0nVAY*TCb95;nZf|9HV`Xr3AT2&1c5i8903%^zFk>@iWiVqhIAb+rWo2SyW;0}CIASz2W-~BhFgY<906H2Y02muOI%j2cLvL(vawsVvV{dMAbRceTWq4y{aC9IoJ|Iy;Z)|UJ03%^BI5Rb3WHB)`Wo2PEWH4oBHZ)^4He)hjFflnYVKihL06G~X02m-TI&)=oLvL(vawt(lZ)|UJAY*TCb95#tAZ~AEcw=R7bRaE0Aa-wQWB?;!G-5V1G%z?bF*#u{GcjReGBss2H!@{6W-~ZtH#B539RNBWBLEl`Iyz@%bVOxlVRdYDLvL(vawsVvZf|9HV`Xr3AT2&1QA2NRZ*l-5VP#`uIWjk6Gcq`1V=^@~WHUE2WH&Q3GG$~kHexq6FdqOq6C(f^5;{6(WpqSkW?^+~bXRF)bZ96kAZ~AEcw=R7bRaE0AZc!N03%^!WHLE5H)CUFF)?B@W@a@uW@a%tI51{7H)c39VK_G-06Gvb0025VL~>zwO>bmn0Ap-nb8~ZRUol@XL~>zwO>bmnE@*UZY$gC3IyysdZggR3Ze?;*d2nR_BVl7PF=I0`VKQbnVqrEgV>2;hG-Eb0VKOr}G&yEvH#sH%8#+2|VR%Dtb#8P3BVl4PGBh$ZWieqgHZ?Y5H!@{0FkxmgWiT@{IbmTpI502(06IEGQe|^ga$#w7a{zO6a&=>Lb8BBQUol2fWph+=VQF-8E@*UZY%l;2Iyz5qWpZJ3X>V=-BVjlDtiG-WX`V>K`U5IQ<=Z*p`1BVlD@VlZPeGdVV6Vlpu^VPRrqHZe41VqrNoIW}TqIc6{b5IQ<&Z*z2CX>b4|VP<7GWHmQ6W@R;FV>LKtWHx3vVq`gFVP!ZrVL4(nW-tH{Iy!D;ba!uZYfW!tWdI{#W-&EkVKFu{VPj)tI51%_WjACpFgIm6HfA_EW??d8FaQuOIyz==a&2LBC}U`0av)=GZgX@XC?+XePF*Y@RC6FECLk^@E-4@_J|J^+WI8%?baH8KX8MmAV{dMAbS5bvEj}P~bYwa@bailSWjr8HaAk5~bZKvHEFfuabSxlgZgealX>N2ZAZc!NAU*&iVP<7EHe_aHGh${mH8(jhIWsahVKFc@Fl9M1H#1{6I4%G(L33*WZeeX@b8ul}WpisTXmo9CK>!vLIy!J+X>N2VQBYxNZggdGDk&f>J|K2)X=DH+VPiKjVl_BpGdN^nW-~W6IA&ruVK+8qGGjP5F=8<|V=(|Y5kUYJ4>~$+Z*_BJP;YZ-bZKvHLug@cXJuq4QBZGbZge1HZ*FsRCMf_TVKHK5GB#y2Vm356Vl!c3G-5SmV`XJDF)%k|V=-oCIWqt_4M6}F0y;WvZ*_BJQe|vqVRL0vNqVmD?rG&eFfG&o{nGBp4=K>!v4Iy!Z3WN#=b03%^!G&p58F)%PRI5s&kFgav7V=*!`HZeIjGi5SjF=9A3060Ma76Ljta%E(1C@BCVVPrI8Gh#F~FfwIjH8C||GdX5qIAJ(qF*#v0H90jlWjO#iK>!vIIy!G|Qe|UhX?A5~O=WX)VP|D1QB!nsX>MmAV{dMAbS5bPBVl1PWo0!pGGQ`gHZe9fHZnFeW;SDGHa2EsW@9vCW@0-4I1WJo77sc)V`yP+XJtcgY;STXQA2NRZ*m}GZ*FsRCMf_TVPa-BG&wOfGBsvlVP#`6WidA}H8f*0GiGBpWn^JBVLbpi4M6}F3pzSuXkl(=WmjorbZ97JZ*FsRAZc!NDF7p3IWah5VP$4vVKFl{IA&oqIWaUhV=*>mHf1V{Bn_b8~B7F<&u5VQzL|b1rCfZEP?A06IECa&>cPO>bmn0Ap-nb8~ZRUol@XLUMI;XiaZqWiDuRZEQsV77{u-XJvF#Z)0m^bSNnxEj}PoRAX>cZ)0m^bRa4KBVjW!W@KYxGGaG5VPrNrV=^%|IA%03VmD9fa8qw%Yh`pGDgYy4WH~W7VPj-DHZ?FeIW#z9G%+w_F)}ncG%++ZV=^>lMgTYvFaQ8LIzwz}Wo~o;V{Bn_b8~B7F<&u5Y-wd~bS`LgZEQ~f8x%S^aCLKNPGxsYVR>b8C}MAKY#?KAZgX@gAT2&1c5i8903%^GWi>N0W-~G{V`5=uVL4(rWjHowHaKEsHaIn6G&D6y06h{<02>%OI&fiWZgfLoZgydFC{a*hX>N37aw=nQZgX@gAT2&1c5i8903%^DG-5VpIWb`}W??pEWo9;EVP-gDIWsUcVmV}FF=I1J06i8@02?kkI%INTcR_S0QBZGbZge1HZ*FsRCM+OCa$$E(Z)9aAEFfZUZ)_lAZ*FsRDIhIAAa-wQWB?;!IAvouGdMYAI5=T8H928pG-WeoVqr34Wj8Q1GB!40O#nSCFaQ8LIz)0|cSvb-bZ>Hb0Ap-nb8~ZRUol@XL~>zwNNIC)Z*qAqXmo9Cb8=%ZZDDC{E@N2F*r9iIAvotIbmWrV=!ShV^IJ=5MKZu5;{6(Wpqqob96&tV`yb4DIjidWq4y{aC9IoJ|I*eDgYy4I5}cvGd3_bGh$*jGBz|YW-&8jWH324VKihoG-YCDQvg5^UjQBqIy!P?WOZX@RBtF$CMh5-J|K2)X=DH+VK+1}I5A~nWi)0rH#ab4H!?OfHexa~Wo9yFGGsY3GgSaU3SR&o3_3b;Wn^_@WmIn{MlvZNEj}Q2Z)s!zBVlDSWH&Z5GdDD0H8L_VG&nbAFfubaVKO%`F*qhHeq8qFgY?XFg9d2TL3@^UjQBoIy!P?WN#=bAT2&1VsCG303%^xFk~<|Gh;DhIAmpEWHU81W;SFtH8(b9H8V40I5cKm06+*Z0025VLt$fRWn@xib8mHWV`TtiY+-YAb8BBQUok^rV`yb$Qe|^*b#h~6E@*UZY*TA;X<}k*WdLbzWMz0RXmo9CWdI)%Iyz@%bW?9*Yh`pODIhIAAW>9fa8qw%Yh`pGDgYy4V`61CIAk(nW;SLvFgP|hWMyJvFkv`2Vl^^mI5uW7VE{o8WdI)#Iy!P?V`XV}Wn@idb8}&5WhhZobaH8KXCPy5ZgX@dDF7p3VKz4~H!?OgF<~|{WHmQAWn^YzH)LcpH)UiuH!wD3V*o)8FaQ8LIzeJ{baG*1bWUY-cW-iQ0Ap-nb8~ZRUol@XL1J@sa$#e1PGxj=Z*prcXmo9CXaF1%Iyz@%bW?9*Yh`pODIhIAAW>9fa8qw%Yh`pGDgYy4G-fwBWM(&JW@0j9Hexb0Ib&fnH#0LZWHn*ba!uZYXD*ba!uZYc6PXZEOM_0U`n`0WbkI0XqRe14jc&1x^K00ayTB0Av7XaA9X + + + server.cpp + server.hpp + network_config.hpp + QDebug + QString + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk + + + + + + + diff --git a/docs/server_8cpp_source.html b/docs/server_8cpp_source.html deleted file mode 100644 index 2900e60..0000000 --- a/docs/server_8cpp_source.html +++ /dev/null @@ -1,125 +0,0 @@ - - - - - - - -Skribble: src/server.cpp Source File - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    server.cpp
    -
    -
    -
    1 #include "server.hpp"
    -
    2 #include "network_config.hpp"
    -
    3 
    -
    4 #include <QDebug>
    -
    5 #include <QString>
    -
    6 
    -
    7 namespace sk {
    -
    8 
    -
    9 Server::Server()
    -
    10 {
    -
    11  m_server = std::make_unique<QTcpServer>(this);
    -
    12  m_server->listen(QHostAddress::Any, sk::port);
    -
    13 
    -
    14  connect(m_server.get(), &QTcpServer::newConnection, [this] {
    -
    15  m_socket = m_server->nextPendingConnection();
    -
    16 
    -
    17  if(m_socket == nullptr) {
    -
    18  qDebug() << "[Server] Could't create socket for pending connection";
    -
    19  }
    -
    20 
    -
    21  m_socket->write("Hello from server");
    -
    22 
    -
    23  connect(m_socket, &QTcpSocket::readyRead, [this] {
    -
    24  QString str{ m_socket->readAll() };
    -
    25  qDebug() << "Server received: " << str;
    -
    26  emit receivedMessage(str);
    -
    27  });
    -
    28  });
    -
    29 }
    -
    30 
    -
    31 Server::~Server() noexcept
    -
    32 {
    -
    33  if(m_socket != nullptr) {
    -
    34  m_socket->disconnectFromHost();
    -
    35  }
    -
    36  m_server->disconnect();
    -
    37 }
    -
    38 
    -
    39 auto Server::getSocket() -> QTcpSocket*
    -
    40 {
    -
    41  return m_socket;
    -
    42 }
    -
    43 
    -
    44 } // namespace sk
    -
    - - - - diff --git a/docs/server_8hpp.xml b/docs/server_8hpp.xml new file mode 100644 index 0000000..f267dfb --- /dev/null +++ b/docs/server_8hpp.xml @@ -0,0 +1,101 @@ + + + + server.hpp + abstract_network.hpp + QTcpServer + QTcpSocket + memory + src/network_factory.hpp + src/canvas.cpp + src/server.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sk::Server + sk + + + + + + + diff --git a/docs/server_8hpp_source.html b/docs/server_8hpp_source.html deleted file mode 100644 index 7afd31f..0000000 --- a/docs/server_8hpp_source.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - - -Skribble: src/server.hpp Source File - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    server.hpp
    -
    -
    -
    1 #ifndef SERVER_HPP
    -
    2 #define SERVER_HPP
    -
    3 #pragma once
    -
    4 
    -
    5 #include "abstract_network.hpp"
    -
    6 
    -
    7 #include <QTcpServer>
    -
    8 #include <QTcpSocket>
    -
    9 
    -
    10 #include <memory>
    -
    11 
    -
    12 namespace sk {
    -
    13 
    -
    14 class Server final : public AbstractNetwork
    -
    15 {
    -
    16 private:
    -
    17  std::unique_ptr<QTcpServer> m_server{ nullptr };
    -
    18  QTcpSocket* m_socket{ nullptr };
    -
    19 
    -
    20 public:
    -
    21  explicit Server();
    -
    22  Server(Server const&) = delete;
    -
    23  Server(Server&&) = delete;
    -
    24  ~Server() noexcept override;
    -
    25 
    -
    26  auto operator=(Server const&) -> Server& = delete;
    -
    27  auto operator=(Server &&) -> Server& = delete;
    -
    28 
    -
    29  auto getSocket() -> QTcpSocket* override;
    -
    30 };
    -
    31 
    -
    32 } // namespace sk
    -
    33 
    -
    34 #endif // !SERVER_HPP
    -
    - - - - - - diff --git a/docs/splitbar.png b/docs/splitbar.png deleted file mode 100644 index fe895f2..0000000 Binary files a/docs/splitbar.png and /dev/null differ diff --git a/docs/src_2CMakeLists_8txt.xml b/docs/src_2CMakeLists_8txt.xml new file mode 100644 index 0000000..2da3c5c --- /dev/null +++ b/docs/src_2CMakeLists_8txt.xml @@ -0,0 +1,30 @@ + + + + CMakeLists.txt + + + + qt5_add_resources + (QT_RESOURCES ${CMAKE_CURRENT_SOURCE_DIR}/icons.qrc ${CMAKE_CURRENT_SOURCE_DIR}/qml.qrc) set(SOURCE_FILES $ + qt5_add_resources + + QT_RESOURCES ${CMAKE_CURRENT_SOURCE_DIR}/icons.qrc ${CMAKE_CURRENT_SOURCE_DIR}/qml. + qrc + + + + + + + + + + + + + + + + + diff --git a/docs/structFTrait2-members.html b/docs/structFTrait2-members.html deleted file mode 100644 index 8bb1ca8..0000000 --- a/docs/structFTrait2-members.html +++ /dev/null @@ -1,82 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    -
    -
    FTrait2< T > Member List
    -
    -
    - -

    This is the complete list of members for FTrait2< T >, including all inherited members.

    - - - -
    ContainerType typedef (defined in FTrait2< T >)FTrait2< T >
    maxCount (defined in FTrait2< T >)FTrait2< T >static
    - - - - diff --git a/docs/structFTrait2.html b/docs/structFTrait2.html deleted file mode 100644 index 85d52e9..0000000 --- a/docs/structFTrait2.html +++ /dev/null @@ -1,103 +0,0 @@ - - - - - - - -Skribble: FTrait2< T > Struct Template Reference - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    - -
    -
    FTrait2< T > Struct Template Reference
    -
    -
    - - - - -

    -Public Types

    -using ContainerType = std::deque< T >
     
    - - - -

    -Static Public Attributes

    -static constexpr int maxCount = 10
     
    -

    Detailed Description

    -

    template<typename T>
    -struct FTrait2< T >

    - - -

    Definition at line 82 of file fcached_resource_test.cpp.

    -

    The documentation for this struct was generated from the following file: -
    - - - - diff --git a/docs/structFTrait2.xml b/docs/structFTrait2.xml new file mode 100644 index 0000000..048897e --- /dev/null +++ b/docs/structFTrait2.xml @@ -0,0 +1,51 @@ + + + + FTrait2 + + + typename T + + + + + std::deque< T > + using FTrait2< T >::ContainerType = std::deque<T> + + ContainerType + + + + + + + + + + + + constexpr int + constexpr int FTrait2< T >::maxCount + + maxCount + = 10 + + + + + + + + + + + + + + + + FTrait2ContainerType + FTrait2maxCount + + + diff --git a/docs/structFTraits-members.html b/docs/structFTraits-members.html deleted file mode 100644 index 3b25a8f..0000000 --- a/docs/structFTraits-members.html +++ /dev/null @@ -1,84 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    -
    -
    FTraits< T > Member List
    -
    -
    - -

    This is the complete list of members for FTraits< T >, including all inherited members.

    - - - - - -
    cacheGap (defined in FTraits< T >)FTraits< T >static
    ContainerType typedef (defined in FTraits< T >)FTraits< T >
    ContainerType typedef (defined in FTraits< T >)FTraits< T >
    maxCount (defined in FTraits< T >)FTraits< T >static
    - - - - diff --git a/docs/structFTraits.html b/docs/structFTraits.html deleted file mode 100644 index b275e4c..0000000 --- a/docs/structFTraits.html +++ /dev/null @@ -1,110 +0,0 @@ - - - - - - - -Skribble: FTraits< T > Struct Template Reference - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    - -
    -
    FTraits< T > Struct Template Reference
    -
    -
    - - - - - - -

    -Public Types

    -using ContainerType = std::deque< T >
     
    -using ContainerType = std::deque< T >
     
    - - - - - -

    -Static Public Attributes

    -static constexpr int cacheGap = 3
     
    -static constexpr int maxCount = sk::ResourceTraits<T>::maxCount
     
    -

    Detailed Description

    -

    template<typename T>
    -struct FTraits< T >

    - - -

    Definition at line 13 of file cached_resource_test.cpp.

    -

    The documentation for this struct was generated from the following files: -
    - - - - diff --git a/docs/structFTraits.xml b/docs/structFTraits.xml new file mode 100644 index 0000000..5e5d6f2 --- /dev/null +++ b/docs/structFTraits.xml @@ -0,0 +1,80 @@ + + + + FTraits + + + typename T + + + + + std::deque< T > + using FTraits< T >::ContainerType = std::deque<T> + + ContainerType + + + + + + + + + + std::deque< T > + using FTraits< T >::ContainerType = std::deque<T> + + ContainerType + + + + + + + + + + + + constexpr int + constexpr int FTraits< T >::cacheGap + + cacheGap + = 3 + + + + + + + + + + constexpr int + static constexpr int FTraits< T >::maxCount + + maxCount + = sk::ResourceTraits<T>::maxCount + + + + + + + + + + + + + + + + FTraitscacheGap + FTraitsContainerType + FTraitsContainerType + FTraitsmaxCount + + + diff --git a/docs/structFTraits3-members.html b/docs/structFTraits3-members.html deleted file mode 100644 index dd093da..0000000 --- a/docs/structFTraits3-members.html +++ /dev/null @@ -1,82 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    -
    -
    FTraits3< T > Member List
    -
    -
    - -

    This is the complete list of members for FTraits3< T >, including all inherited members.

    - - - -
    ContainerType typedef (defined in FTraits3< T >)FTraits3< T >
    maxCount (defined in FTraits3< T >)FTraits3< T >static
    - - - - diff --git a/docs/structFTraits3.html b/docs/structFTraits3.html deleted file mode 100644 index 521b432..0000000 --- a/docs/structFTraits3.html +++ /dev/null @@ -1,103 +0,0 @@ - - - - - - - -Skribble: FTraits3< T > Struct Template Reference - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    - -
    -
    FTraits3< T > Struct Template Reference
    -
    -
    - - - - -

    -Public Types

    -using ContainerType = std::deque< T >
     
    - - - -

    -Static Public Attributes

    -static constexpr int maxCount = 3
     
    -

    Detailed Description

    -

    template<typename T>
    -struct FTraits3< T >

    - - -

    Definition at line 129 of file fcached_resource_test.cpp.

    -

    The documentation for this struct was generated from the following file: -
    - - - - diff --git a/docs/structFTraits3.xml b/docs/structFTraits3.xml new file mode 100644 index 0000000..b5f560e --- /dev/null +++ b/docs/structFTraits3.xml @@ -0,0 +1,51 @@ + + + + FTraits3 + + + typename T + + + + + std::deque< T > + using FTraits3< T >::ContainerType = std::deque<T> + + ContainerType + + + + + + + + + + + + constexpr int + constexpr int FTraits3< T >::maxCount + + maxCount + = 3 + + + + + + + + + + + + + + + + FTraits3ContainerType + FTraits3maxCount + + + diff --git a/docs/structTestBase_1_1Proxy-members.html b/docs/structTestBase_1_1Proxy-members.html deleted file mode 100644 index be6fe11..0000000 --- a/docs/structTestBase_1_1Proxy-members.html +++ /dev/null @@ -1,94 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    TestBase::Proxy Member List
    -
    -
    - -

    This is the complete list of members for TestBase::Proxy, including all inherited members.

    - - - - - - - - - - - -
    operator!=(T const &other) -> Proxy & (defined in TestBase::Proxy)TestBase::Proxyinline
    operator+(T const &arg) -> Proxy & (defined in TestBase::Proxy)TestBase::Proxyinline
    operator=(Proxy const &)=delete (defined in TestBase::Proxy)TestBase::Proxy
    operator=(Proxy &&)=delete (defined in TestBase::Proxy)TestBase::Proxy
    operator==(T const &other) -> Proxy & (defined in TestBase::Proxy)TestBase::Proxyinline
    Proxy()=default (defined in TestBase::Proxy)TestBase::Proxy
    Proxy(Proxy const &)=delete (defined in TestBase::Proxy)TestBase::Proxy
    Proxy(Proxy &&)=delete (defined in TestBase::Proxy)TestBase::Proxy
    str (defined in TestBase::Proxy)TestBase::Proxy
    ~Proxy()=default (defined in TestBase::Proxy)TestBase::Proxy
    - - - - diff --git a/docs/structTestBase_1_1Proxy.html b/docs/structTestBase_1_1Proxy.html deleted file mode 100644 index 3decc6f..0000000 --- a/docs/structTestBase_1_1Proxy.html +++ /dev/null @@ -1,125 +0,0 @@ - - - - - - - -Skribble: TestBase::Proxy Struct Reference - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    - -
    -
    TestBase::Proxy Struct Reference
    -
    -
    - - - - - - - - - - - - - - - - - - - -

    -Public Member Functions

    Proxy (Proxy const &)=delete
     
    Proxy (Proxy &&)=delete
     
    -auto operator= (Proxy const &)=delete
     
    -auto operator= (Proxy &&)=delete
     
    -template<typename T >
    auto operator+ (T const &arg) -> Proxy &
     
    -template<typename T >
    auto operator== (T const &other) -> Proxy &
     
    -template<typename T >
    auto operator!= (T const &other) -> Proxy &
     
    - - - -

    -Public Attributes

    -std::string str {}
     
    -

    Detailed Description

    -
    -

    Definition at line 31 of file test.hpp.

    -

    The documentation for this struct was generated from the following file: -
    - - - - diff --git a/docs/structTestBase_1_1Proxy.xml b/docs/structTestBase_1_1Proxy.xml new file mode 100644 index 0000000..197f7a1 --- /dev/null +++ b/docs/structTestBase_1_1Proxy.xml @@ -0,0 +1,197 @@ + + + + TestBase::Proxy + + + std::string + std::string TestBase::Proxy::str + + str + {} + + + + + + + + + + + + + TestBase::Proxy::Proxy + ()=default + Proxy + + + + + + + + + + + TestBase::Proxy::Proxy + (Proxy const &)=delete + Proxy + + Proxy const & + + + + + + + + + + + + TestBase::Proxy::Proxy + (Proxy &&)=delete + Proxy + + Proxy && + + + + + + + + + + + + TestBase::Proxy::~Proxy + ()=default + ~Proxy + + + + + + + + + + auto + auto TestBase::Proxy::operator= + (Proxy const &)=delete + operator= + + Proxy const & + + + + + + + + + + + auto + auto TestBase::Proxy::operator= + (Proxy &&)=delete + operator= + + Proxy && + + + + + + + + + + + + + typename T + + + auto + auto TestBase::Proxy::operator+ + (T const &arg) -> Proxy & + operator+ + + T const & + arg + + + + + + + + + + + + + typename T + + + auto + auto TestBase::Proxy::operator== + (T const &other) -> Proxy & + operator== + + T const & + other + + + + + + + + + + + + + typename T + + + auto + auto TestBase::Proxy::operator!= + (T const &other) -> Proxy & + operator!= + + T const & + other + + + + + + + + + + + + + + + + + TestBase::Proxyoperator!= + TestBase::Proxyoperator+ + TestBase::Proxyoperator= + TestBase::Proxyoperator= + TestBase::Proxyoperator== + TestBase::ProxyProxy + TestBase::ProxyProxy + TestBase::ProxyProxy + TestBase::Proxystr + TestBase::Proxy~Proxy + + + diff --git a/docs/structTrait2-members.html b/docs/structTrait2-members.html deleted file mode 100644 index 06af4fb..0000000 --- a/docs/structTrait2-members.html +++ /dev/null @@ -1,83 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    -
    -
    Trait2< T > Member List
    -
    -
    - -

    This is the complete list of members for Trait2< T >, including all inherited members.

    - - - - -
    cacheGap (defined in Trait2< T >)Trait2< T >static
    ContainerType typedef (defined in Trait2< T >)Trait2< T >
    maxCount (defined in Trait2< T >)Trait2< T >static
    - - - - diff --git a/docs/structTrait2.html b/docs/structTrait2.html deleted file mode 100644 index d1770df..0000000 --- a/docs/structTrait2.html +++ /dev/null @@ -1,106 +0,0 @@ - - - - - - - -Skribble: Trait2< T > Struct Template Reference - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    - -
    -
    Trait2< T > Struct Template Reference
    -
    -
    - - - - -

    -Public Types

    -using ContainerType = std::deque< T >
     
    - - - - - -

    -Static Public Attributes

    -static constexpr int cacheGap = 5
     
    -static constexpr int maxCount = sk::ResourceTraits<T>::maxCount
     
    -

    Detailed Description

    -

    template<typename T>
    -struct Trait2< T >

    - - -

    Definition at line 98 of file cached_resource_test.cpp.

    -

    The documentation for this struct was generated from the following file: -
    - - - - diff --git a/docs/structTrait2.xml b/docs/structTrait2.xml new file mode 100644 index 0000000..5158bcd --- /dev/null +++ b/docs/structTrait2.xml @@ -0,0 +1,66 @@ + + + + Trait2 + + + typename T + + + + + std::deque< T > + using Trait2< T >::ContainerType = std::deque<T> + + ContainerType + + + + + + + + + + + + constexpr int + constexpr int Trait2< T >::cacheGap + + cacheGap + = 5 + + + + + + + + + + constexpr int + constexpr int Trait2< T >::maxCount + + maxCount + = sk::ResourceTraits<T>::maxCount + + + + + + + + + + + + + + + + Trait2cacheGap + Trait2ContainerType + Trait2maxCount + + + diff --git a/docs/structTraits3-members.html b/docs/structTraits3-members.html deleted file mode 100644 index 1c30cfb..0000000 --- a/docs/structTraits3-members.html +++ /dev/null @@ -1,83 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    -
    -
    Traits3< T > Member List
    -
    -
    - -

    This is the complete list of members for Traits3< T >, including all inherited members.

    - - - - -
    cacheGap (defined in Traits3< T >)Traits3< T >static
    ContainerType typedef (defined in Traits3< T >)Traits3< T >
    maxCount (defined in Traits3< T >)Traits3< T >static
    - - - - diff --git a/docs/structTraits3.html b/docs/structTraits3.html deleted file mode 100644 index 84e0085..0000000 --- a/docs/structTraits3.html +++ /dev/null @@ -1,106 +0,0 @@ - - - - - - - -Skribble: Traits3< T > Struct Template Reference - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - -
    -
    - -
    -
    Traits3< T > Struct Template Reference
    -
    -
    - - - - -

    -Public Types

    -using ContainerType = std::deque< T >
     
    - - - - - -

    -Static Public Attributes

    -static constexpr int maxCount = 2
     
    -static constexpr int cacheGap = 3
     
    -

    Detailed Description

    -

    template<typename T>
    -struct Traits3< T >

    - - -

    Definition at line 155 of file cached_resource_test.cpp.

    -

    The documentation for this struct was generated from the following file: -
    - - - - diff --git a/docs/structTraits3.xml b/docs/structTraits3.xml new file mode 100644 index 0000000..1170374 --- /dev/null +++ b/docs/structTraits3.xml @@ -0,0 +1,66 @@ + + + + Traits3 + + + typename T + + + + + std::deque< T > + using Traits3< T >::ContainerType = std::deque<T> + + ContainerType + + + + + + + + + + + + constexpr int + constexpr int Traits3< T >::maxCount + + maxCount + = 2 + + + + + + + + + + constexpr int + constexpr int Traits3< T >::cacheGap + + cacheGap + = 3 + + + + + + + + + + + + + + + + Traits3cacheGap + Traits3ContainerType + Traits3maxCount + + + diff --git a/docs/structsk_1_1DrawHistory_1_1Traits.xml b/docs/structsk_1_1DrawHistory_1_1Traits.xml new file mode 100644 index 0000000..af7ac85 --- /dev/null +++ b/docs/structsk_1_1DrawHistory_1_1Traits.xml @@ -0,0 +1,61 @@ + + + + sk::DrawHistory::Traits + + + std::deque< impl::CachedLayers > + using sk::DrawHistory::Traits::ContainerType = std::deque<impl::CachedLayers> + + ContainerType + + + + + + + + + + + + constexpr int + constexpr int sk::DrawHistory::Traits::cacheGap + + cacheGap + = 3 + + + + + + + + + + constexpr int + constexpr int sk::DrawHistory::Traits::maxCount + + maxCount + = 10 + + + + + + + + + + + + + + + + sk::DrawHistory::TraitscacheGap + sk::DrawHistory::TraitsContainerType + sk::DrawHistory::TraitsmaxCount + + + diff --git a/docs/structsk_1_1FResTraits-members.html b/docs/structsk_1_1FResTraits-members.html deleted file mode 100644 index 0820a4a..0000000 --- a/docs/structsk_1_1FResTraits-members.html +++ /dev/null @@ -1,86 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    sk::FResTraits< T > Member List
    -
    -
    - -

    This is the complete list of members for sk::FResTraits< T >, including all inherited members.

    - - - -
    ContainerType typedef (defined in sk::FResTraits< T >)sk::FResTraits< T >
    maxCount (defined in sk::FResTraits< T >)sk::FResTraits< T >static
    - - - - diff --git a/docs/structsk_1_1FResTraits.html b/docs/structsk_1_1FResTraits.html index 4af0194..0686147 100644 --- a/docs/structsk_1_1FResTraits.html +++ b/docs/structsk_1_1FResTraits.html @@ -1,107 +1,155 @@ - - + + - - - - -Skribble: sk::FResTraits< T > Struct Template Reference - - - - - - - + + sk::FResTraits struct | Skribble - Collaborative app made with Qt + + + + + -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    +
    +
    +
    +
    +
    +

    +
    template<typename T>
    + sk::FResTraits struct +

    +

    Parameters for FCachedResource.

    +
    +

    Contents

    + +
    +
    +

    Public types

    +
    +
    + using ContainerType = std::list<T> +
    +
    +
    +
    +
    +

    Public static variables

    +
    +
    + static int maxCount constexpr +
    +
    +
    +
    +
    +

    Typedef documentation

    +
    +

    +
    + template<typename T> +
    + using sk::FResTraits<T>::ContainerType = std::list<T> +

    +

    With what to store the layers with, by default std::list.

    +
    +
    +
    +

    Variable documentation

    +
    +

    +
    + template<typename T> +
    + static int sk::FResTraits<T>::maxCount constexpr +

    +

    History limit.

    +
    +
    +
    +
    +
    +
    + - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    - -
    -
    sk::FResTraits< T > Struct Template Reference
    -
    -
    - - - - -

    -Public Types

    -using ContainerType = std::list< T >
     
    - - - -

    -Static Public Attributes

    -static constexpr int maxCount = 100
     
    -

    Detailed Description

    -

    template<typename T>
    -struct sk::FResTraits< T >

    - - -

    Definition at line 15 of file fixed_cached_resource.hpp.

    -

    The documentation for this struct was generated from the following file: -
    - - + + +
    diff --git a/docs/structsk_1_1FResTraits.xml b/docs/structsk_1_1FResTraits.xml new file mode 100644 index 0000000..d5e6862 --- /dev/null +++ b/docs/structsk_1_1FResTraits.xml @@ -0,0 +1,55 @@ + + + + sk::FResTraits + fixed_cached_resource.hpp + + + typename T + + + + + std::list< T > + using sk::FResTraits< T >::ContainerType = std::list<T> + + ContainerType + + + +With what to store the layers with, by default std::list. + + + + + + + + + constexpr int + constexpr int sk::FResTraits< T >::maxCount + + maxCount + = 100 + + + +History limit. + + + + + + + +Parameters for FCachedResource. + + + + + + sk::FResTraitsContainerType + sk::FResTraitsmaxCount + + + diff --git a/docs/structsk_1_1ResourceTraits-members.html b/docs/structsk_1_1ResourceTraits-members.html deleted file mode 100644 index 1b9b3f9..0000000 --- a/docs/structsk_1_1ResourceTraits-members.html +++ /dev/null @@ -1,87 +0,0 @@ - - - - - - - -Skribble: Member List - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    sk::ResourceTraits< T > Member List
    -
    -
    - -

    This is the complete list of members for sk::ResourceTraits< T >, including all inherited members.

    - - - - -
    cacheGap (defined in sk::ResourceTraits< T >)sk::ResourceTraits< T >static
    ContainerType typedef (defined in sk::ResourceTraits< T >)sk::ResourceTraits< T >
    maxCount (defined in sk::ResourceTraits< T >)sk::ResourceTraits< T >static
    - - - - diff --git a/docs/structsk_1_1ResourceTraits.html b/docs/structsk_1_1ResourceTraits.html index d8d304d..7e96491 100644 --- a/docs/structsk_1_1ResourceTraits.html +++ b/docs/structsk_1_1ResourceTraits.html @@ -1,110 +1,146 @@ - - + + - - - - -Skribble: sk::ResourceTraits< T > Struct Template Reference - - - - - - - + + sk::ResourceTraits struct | Skribble - Collaborative app made with Qt + + + + + -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    +
    +
    +
    +
    +
    +

    +
    template<typename T>
    + sk::ResourceTraits struct +

    +

    Parameters for CachedResource.

    +
    +

    Contents

    + +
    +
    +

    Public static variables

    +
    +
    + static int cacheGap constexpr +
    +
    +
    + static int maxCount constexpr +
    +
    +
    +
    +
    +

    Variable documentation

    +
    +

    +
    + template<typename T> +
    + static int sk::ResourceTraits<T>::cacheGap constexpr +

    +

    When to store a new cache.

    +
    +
    +

    +
    + template<typename T> +
    + static int sk::ResourceTraits<T>::maxCount constexpr +

    +

    History limit.

    +
    +
    +
    +
    +
    +
    + - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    - -
    -
    sk::ResourceTraits< T > Struct Template Reference
    -
    -
    - - - - -

    -Public Types

    -using ContainerType = std::deque< T >
     
    - - - - - -

    -Static Public Attributes

    -static constexpr int cacheGap = 5
     
    -static constexpr int maxCount = 20
     
    -

    Detailed Description

    -

    template<typename T>
    -struct sk::ResourceTraits< T >

    - - -

    Definition at line 15 of file cached_resource.hpp.

    -

    The documentation for this struct was generated from the following file: -
    - - + + +
    diff --git a/docs/structsk_1_1ResourceTraits.xml b/docs/structsk_1_1ResourceTraits.xml new file mode 100644 index 0000000..360fd00 --- /dev/null +++ b/docs/structsk_1_1ResourceTraits.xml @@ -0,0 +1,70 @@ + + + + sk::ResourceTraits + cached_resource.hpp + + + typename T + + + + + std::deque< T > + using sk::ResourceTraits< T >::ContainerType = std::deque<T> + + ContainerType + + + + + + + + + + + + constexpr int + constexpr int sk::ResourceTraits< T >::cacheGap + + cacheGap + = 5 + + + +When to store a new cache. + + + + + + + constexpr int + constexpr int sk::ResourceTraits< T >::maxCount + + maxCount + = 20 + + + +History limit. + + + + + + + +Parameters for CachedResource. + + + + + + sk::ResourceTraitscacheGap + sk::ResourceTraitsContainerType + sk::ResourceTraitsmaxCount + + + diff --git a/docs/sync_off.png b/docs/sync_off.png deleted file mode 100644 index 3b443fc..0000000 Binary files a/docs/sync_off.png and /dev/null differ diff --git a/docs/sync_on.png b/docs/sync_on.png deleted file mode 100644 index e08320f..0000000 Binary files a/docs/sync_on.png and /dev/null differ diff --git a/docs/tab_a.png b/docs/tab_a.png deleted file mode 100644 index 3b725c4..0000000 Binary files a/docs/tab_a.png and /dev/null differ diff --git a/docs/tab_b.png b/docs/tab_b.png deleted file mode 100644 index e2b4a86..0000000 Binary files a/docs/tab_b.png and /dev/null differ diff --git a/docs/tab_h.png b/docs/tab_h.png deleted file mode 100644 index fd5cb70..0000000 Binary files a/docs/tab_h.png and /dev/null differ diff --git a/docs/tab_s.png b/docs/tab_s.png deleted file mode 100644 index ab478c9..0000000 Binary files a/docs/tab_s.png and /dev/null differ diff --git a/docs/tabs.css b/docs/tabs.css deleted file mode 100644 index 7d45d36..0000000 --- a/docs/tabs.css +++ /dev/null @@ -1 +0,0 @@ -.sm{position:relative;z-index:9999}.sm,.sm ul,.sm li{display:block;list-style:none;margin:0;padding:0;line-height:normal;direction:ltr;text-align:left;-webkit-tap-highlight-color:rgba(0,0,0,0)}.sm-rtl,.sm-rtl ul,.sm-rtl li{direction:rtl;text-align:right}.sm>li>h1,.sm>li>h2,.sm>li>h3,.sm>li>h4,.sm>li>h5,.sm>li>h6{margin:0;padding:0}.sm ul{display:none}.sm li,.sm a{position:relative}.sm a{display:block}.sm a.disabled{cursor:not-allowed}.sm:after{content:"\00a0";display:block;height:0;font:0px/0 serif;clear:both;visibility:hidden;overflow:hidden}.sm,.sm *,.sm *:before,.sm *:after{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.sm-dox{background-image:url("tab_b.png")}.sm-dox a,.sm-dox a:focus,.sm-dox a:hover,.sm-dox a:active{padding:0px 12px;padding-right:43px;font-family:"Lucida Grande","Geneva","Helvetica",Arial,sans-serif;font-size:13px;font-weight:bold;line-height:36px;text-decoration:none;text-shadow:0px 1px 1px rgba(255,255,255,0.9);color:#283A5D;outline:none}.sm-dox a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox a.current{color:#D23600}.sm-dox a.disabled{color:#bbb}.sm-dox a span.sub-arrow{position:absolute;top:50%;margin-top:-14px;left:auto;right:3px;width:28px;height:28px;overflow:hidden;font:bold 12px/28px monospace !important;text-align:center;text-shadow:none;background:rgba(255,255,255,0.5);border-radius:5px}.sm-dox a.highlighted span.sub-arrow:before{display:block;content:'-'}.sm-dox>li:first-child>a,.sm-dox>li:first-child>:not(ul) a{border-radius:5px 5px 0 0}.sm-dox>li:last-child>a,.sm-dox>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul{border-radius:0 0 5px 5px}.sm-dox>li:last-child>a.highlighted,.sm-dox>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted{border-radius:0}.sm-dox ul{background:rgba(162,162,162,0.1)}.sm-dox ul a,.sm-dox ul a:focus,.sm-dox ul a:hover,.sm-dox ul a:active{font-size:12px;border-left:8px solid transparent;line-height:36px;text-shadow:none;background-color:white;background-image:none}.sm-dox ul a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox ul ul a,.sm-dox ul ul a:hover,.sm-dox ul ul a:focus,.sm-dox ul ul a:active{border-left:16px solid transparent}.sm-dox ul ul ul a,.sm-dox ul ul ul a:hover,.sm-dox ul ul ul a:focus,.sm-dox ul ul ul a:active{border-left:24px solid transparent}.sm-dox ul ul ul ul a,.sm-dox ul ul ul ul a:hover,.sm-dox ul ul ul ul a:focus,.sm-dox ul ul ul ul a:active{border-left:32px solid transparent}.sm-dox ul ul ul ul ul a,.sm-dox ul ul ul ul ul a:hover,.sm-dox ul ul ul ul ul a:focus,.sm-dox ul ul ul ul ul a:active{border-left:40px solid transparent}@media (min-width: 768px){.sm-dox ul{position:absolute;width:12em}.sm-dox li{float:left}.sm-dox.sm-rtl li{float:right}.sm-dox ul li,.sm-dox.sm-rtl ul li,.sm-dox.sm-vertical li{float:none}.sm-dox a{white-space:nowrap}.sm-dox ul a,.sm-dox.sm-vertical a{white-space:normal}.sm-dox .sm-nowrap>li>a,.sm-dox .sm-nowrap>li>:not(ul) a{white-space:nowrap}.sm-dox{padding:0 10px;background-image:url("tab_b.png");line-height:36px}.sm-dox a span.sub-arrow{top:50%;margin-top:-2px;right:12px;width:0;height:0;border-width:4px;border-style:solid dashed dashed dashed;border-color:#283A5D transparent transparent transparent;background:transparent;border-radius:0}.sm-dox a,.sm-dox a:focus,.sm-dox a:active,.sm-dox a:hover,.sm-dox a.highlighted{padding:0px 12px;background-image:url("tab_s.png");background-repeat:no-repeat;background-position:right;border-radius:0 !important}.sm-dox a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox a:hover span.sub-arrow{border-color:#fff transparent transparent transparent}.sm-dox a.has-submenu{padding-right:24px}.sm-dox li{border-top:0}.sm-dox>li>ul:before,.sm-dox>li>ul:after{content:'';position:absolute;top:-18px;left:30px;width:0;height:0;overflow:hidden;border-width:9px;border-style:dashed dashed solid dashed;border-color:transparent transparent #bbb transparent}.sm-dox>li>ul:after{top:-16px;left:31px;border-width:8px;border-color:transparent transparent #fff transparent}.sm-dox ul{border:1px solid #bbb;padding:5px 0;background:#fff;border-radius:5px !important;box-shadow:0 5px 9px rgba(0,0,0,0.2)}.sm-dox ul a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-color:transparent transparent transparent #555;border-style:dashed dashed dashed solid}.sm-dox ul a,.sm-dox ul a:hover,.sm-dox ul a:focus,.sm-dox ul a:active,.sm-dox ul a.highlighted{color:#555;background-image:none;border:0 !important;color:#555;background-image:none}.sm-dox ul a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox ul a:hover span.sub-arrow{border-color:transparent transparent transparent #fff}.sm-dox span.scroll-up,.sm-dox span.scroll-down{position:absolute;display:none;visibility:hidden;overflow:hidden;background:#fff;height:36px}.sm-dox span.scroll-up:hover,.sm-dox span.scroll-down:hover{background:#eee}.sm-dox span.scroll-up:hover span.scroll-up-arrow,.sm-dox span.scroll-up:hover span.scroll-down-arrow{border-color:transparent transparent #D23600 transparent}.sm-dox span.scroll-down:hover span.scroll-down-arrow{border-color:#D23600 transparent transparent transparent}.sm-dox span.scroll-up-arrow,.sm-dox span.scroll-down-arrow{position:absolute;top:0;left:50%;margin-left:-6px;width:0;height:0;overflow:hidden;border-width:6px;border-style:dashed dashed solid dashed;border-color:transparent transparent #555 transparent}.sm-dox span.scroll-down-arrow{top:8px;border-style:solid dashed dashed dashed;border-color:#555 transparent transparent transparent}.sm-dox.sm-rtl a.has-submenu{padding-right:12px;padding-left:24px}.sm-dox.sm-rtl a span.sub-arrow{right:auto;left:12px}.sm-dox.sm-rtl.sm-vertical a.has-submenu{padding:10px 20px}.sm-dox.sm-rtl.sm-vertical a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-rtl>li>ul:before{left:auto;right:30px}.sm-dox.sm-rtl>li>ul:after{left:auto;right:31px}.sm-dox.sm-rtl ul a.has-submenu{padding:10px 20px !important}.sm-dox.sm-rtl ul a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-vertical{padding:10px 0;border-radius:5px}.sm-dox.sm-vertical a{padding:10px 20px}.sm-dox.sm-vertical a:hover,.sm-dox.sm-vertical a:focus,.sm-dox.sm-vertical a:active,.sm-dox.sm-vertical a.highlighted{background:#fff}.sm-dox.sm-vertical a.disabled{background-image:url("tab_b.png")}.sm-dox.sm-vertical a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-style:dashed dashed dashed solid;border-color:transparent transparent transparent #555}.sm-dox.sm-vertical>li>ul:before,.sm-dox.sm-vertical>li>ul:after{display:none}.sm-dox.sm-vertical ul a{padding:10px 20px}.sm-dox.sm-vertical ul a:hover,.sm-dox.sm-vertical ul a:focus,.sm-dox.sm-vertical ul a:active,.sm-dox.sm-vertical ul a.highlighted{background:#eee}.sm-dox.sm-vertical ul a.disabled{background:#fff}} diff --git a/docs/test_8hpp.xml b/docs/test_8hpp.xml new file mode 100644 index 0000000..5dfe149 --- /dev/null +++ b/docs/test_8hpp.xml @@ -0,0 +1,271 @@ + + + + test.hpp + format.hpp + atomic + cstdlib + fstream + string + type_traits + vector + tests/cached_resource_test.cpp + tests/fcached_resource_test.cpp + tests/format_test.cpp + tests/message_parser_test.cpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + TestBase + TestBase::Proxy + + + PASTE_2 + a + b + a##b + + + + + + + + + + PASTE_1 + a + b + PASTE_2(a, b) + + + + + + + + + + PASTE + a + b + PASTE_1(a, b) + + + + + + + + + + RAND + PASTE(tmp_class_name___, __LINE__) + + + + + + + + + + RAND2 + PASTE(tmp_var_name___, __LINE__) + + + + + + + + + + ASSERT + ... + do { \ + if(!(__VA_ARGS__)) { \ + sk::printlnTo( \ + m_output, \ + "Assertion failed in %1[%2]:\n\t\t%3\n\tExpanded to:\n\t\t%4", \ + __FILE__, \ + __LINE__, \ + #__VA_ARGS__, \ + (Proxy{} + __VA_ARGS__).str); \ + successful.store(EXIT_FAILURE); \ + return; \ + } \ + } while(false) + + + + + + + + + + TEST + name + namespace { \ + class RAND : public TestBase \ + { \ + public: \ + RAND() \ + : TestBase{ name, __FILE__, __LINE__ } \ + { \ + } \ + RAND(RAND const&) = delete; \ + RAND(RAND&&) = delete; \ + ~RAND() noexcept override = default; \ + \ + auto operator=(RAND const&) -> RAND& = delete; \ + auto operator=(RAND &&) -> RAND& = delete; \ + \ + auto run(std::atomic<int>& successful) -> void override; \ + }; \ + \ + static RAND RAND2; \ + } \ + \ + auto RAND::run(std::atomic<int>& successful)->void + + + + + + + + + + + + auto + auto getTestId + () -> int + getTestId + + + + + + + + + + auto + auto getTests + () -> std::vector< TestBase * > & + getTests + + + + + + + + + + + + + + + + diff --git a/docs/test_8hpp_source.html b/docs/test_8hpp_source.html deleted file mode 100644 index 4455547..0000000 --- a/docs/test_8hpp_source.html +++ /dev/null @@ -1,473 +0,0 @@ - - - - - - - -Skribble: tests/helper/test.hpp Source File - - - - - - - - - -
    -
    - - - - - - -
    -
    Skribble -
    -
    Collaborative app made with Qt
    -
    -
    - - - - - - - - -
    -
    - - -
    - -
    - - -
    -
    -
    -
    test.hpp
    -
    -
    -
    1 #ifndef HELPER_TEST_HPP
    -
    2 #define HELPER_TEST_HPP
    -
    3 #pragma once
    -
    4 
    -
    5 #define PASTE_2(a, b) a##b
    -
    6 #define PASTE_1(a, b) PASTE_2(a, b)
    -
    7 #define PASTE(a, b) PASTE_1(a, b)
    -
    8 #define RAND PASTE(tmp_class_name___, __LINE__)
    -
    9 #define RAND2 PASTE(tmp_var_name___, __LINE__)
    -
    10 
    -
    11 #include "format.hpp"
    -
    12 
    -
    13 #include <atomic>
    -
    14 #include <cstdlib>
    -
    15 #include <fstream>
    -
    16 #include <string>
    -
    17 #include <type_traits>
    -
    18 #include <vector>
    -
    19 
    -
    20 auto getTestId() -> int;
    -
    21 
    -
    22 class TestBase
    -
    23 {
    -
    24 protected:
    -
    25  std::ofstream m_output{};
    -
    26  std::string m_name{};
    -
    27  std::string m_file{};
    -
    28  int m_line{ 0 };
    -
    29  int m_testId{ 0 };
    -
    30 
    -
    31  struct Proxy
    -
    32  {
    -
    33  std::string str{};
    -
    34 
    -
    35  Proxy() = default;
    -
    36  Proxy(Proxy const&) = delete;
    -
    37  Proxy(Proxy&&) = delete;
    -
    38  ~Proxy() = default;
    -
    39 
    -
    40  auto operator=(Proxy const&) = delete;
    -
    41  auto operator=(Proxy&&) = delete;
    -
    42 
    -
    43  template<typename T>
    -
    44  auto operator+(T const& arg) -> Proxy&
    -
    45  {
    -
    46  using TT = std::remove_cv_t<std::remove_reference_t<T>>;
    -
    47  if constexpr(std::is_same_v<TT, Proxy>) {
    -
    48  return *this;
    -
    49  }
    -
    50  str += sk::format("%1", arg);
    -
    51  return *this;
    -
    52  }
    -
    53 
    -
    54  template<typename T>
    -
    55  auto operator==(T const& other) -> Proxy&
    -
    56  {
    -
    57  str += sk::format(" == %1", other);
    -
    58  return *this;
    -
    59  }
    -
    60 
    -
    61  template<typename T>
    -
    62  auto operator!=(T const& other) -> Proxy&
    -
    63  {
    -
    64  str += sk::format(" != %1", other);
    -
    65  return *this;
    -
    66  }
    -
    67  };
    -
    68 
    -
    69 public:
    -
    70  TestBase() = delete;
    -
    71  TestBase(TestBase const&) = delete;
    -
    72  TestBase(TestBase&&) noexcept = default;
    -
    73  virtual ~TestBase() noexcept = default;
    -
    74 
    -
    75  TestBase(std::string testName, std::string file, int const line);
    -
    76 
    -
    77  auto operator=(TestBase const&) -> TestBase& = delete;
    -
    78  auto operator=(TestBase&&) noexcept -> TestBase& = default;
    -
    79 
    -
    80  virtual auto run(std::atomic<int>& successful) -> void = 0;
    -
    81 };
    -
    82 
    -
    83 #define ASSERT(...) \
    -
    84  do { \
    -
    85  if(!(__VA_ARGS__)) { \
    -
    86  sk::printlnTo( \
    -
    87  m_output, \
    -
    88  "Assertion failed in %1[%2]:\n\t\t%3\n\tExpanded to:\n\t\t%4", \
    -
    89  __FILE__, \
    -
    90  __LINE__, \
    -
    91  #__VA_ARGS__, \
    -
    92  (Proxy{} + __VA_ARGS__).str); \
    -
    93  successful.store(EXIT_FAILURE); \
    -
    94  return; \
    -
    95  } \
    -
    96  } while(false)
    -
    97 
    -
    98 #define TEST(name) \
    -
    99  namespace { \
    -
    100  class RAND : public TestBase \
    -
    101  { \
    -
    102  public: \
    -
    103  RAND() \
    -
    104  : TestBase{ name, __FILE__, __LINE__ } \
    -
    105  { \
    -
    106  } \
    -
    107  RAND(RAND const&) = delete; \
    -
    108  RAND(RAND&&) = delete; \
    -
    109  ~RAND() noexcept override = default; \
    -
    110  \
    -
    111  auto operator=(RAND const&) -> RAND& = delete; \
    -
    112  auto operator=(RAND &&) -> RAND& = delete; \
    -
    113  \
    -
    114  auto run(std::atomic<int>& successful) -> void override; \
    -
    115  }; \
    -
    116  \
    -
    117  static RAND RAND2; \
    -
    118  } \
    -
    119  \
    -
    120  auto RAND::run(std::atomic<int>& successful)->void
    -
    121 
    -
    122 auto getTests() -> std::vector<TestBase*>&;
    -
    123 
    -
    124 //#define MAIN_EXECUTABLE
    -
    125 #ifdef MAIN_EXECUTABLE
    -
    126 
    -
    127 #include <atomic>
    -
    128 #include <condition_variable>
    -
    129 #include <cstdlib>
    -
    130 #include <filesystem>
    -
    131 #include <functional>
    -
    132 #include <future>
    -
    133 #include <memory>
    -
    134 #include <queue>
    -
    135 #include <stdexcept>
    -
    136 #include <string>
    -
    137 #include <thread>
    -
    138 #include <utility>
    -
    139 
    -
    140 class TestException final : public std::exception
    -
    141 {
    -
    142 private:
    -
    143  std::string m_msg{};
    -
    144 
    -
    145 public:
    -
    146  TestException(TestException const&) = delete;
    -
    147  TestException(TestException&&) = delete;
    -
    148  ~TestException() noexcept override = default;
    -
    149 
    -
    150  auto operator=(TestException const&) -> TestException& = delete;
    -
    151  auto operator=(TestException&&) noexcept -> TestException& = delete;
    -
    152 
    -
    153  TestException()
    -
    154  : TestException{ "[TestHelper] Error in tests!" }
    -
    155  {
    -
    156  }
    -
    157  explicit TestException(std::string const& msg)
    -
    158  : m_msg{ "[TestHelper] " + msg }
    -
    159  {
    -
    160  }
    -
    161 
    -
    162  [[nodiscard]] auto what() const noexcept -> char const* override
    -
    163  {
    -
    164  return m_msg.c_str();
    -
    165  }
    -
    166 };
    -
    167 
    -
    168 class ThreadPool
    -
    169 {
    -
    170 private:
    -
    171  std::vector<std::thread> m_workers{};
    -
    172  std::queue<std::function<void()>> m_tasks{};
    -
    173  std::mutex m_mutex{};
    -
    174  std::condition_variable m_cv{};
    -
    175 
    -
    176  bool m_stop{ false };
    -
    177 
    -
    178 public:
    -
    179  ThreadPool(ThreadPool const&) = delete;
    -
    180  ThreadPool(ThreadPool&&) = delete;
    -
    181  ~ThreadPool() noexcept
    -
    182  {
    -
    183  {
    -
    184  std::unique_lock<std::mutex> lock{ m_mutex };
    -
    185  m_stop = true;
    -
    186  }
    -
    187 
    -
    188  m_cv.notify_all();
    -
    189 
    -
    190  for(auto& thread : m_workers) {
    -
    191  thread.join();
    -
    192  }
    -
    193  }
    -
    194 
    -
    195  explicit ThreadPool(
    -
    196  std::size_t const numThreads = std::thread::hardware_concurrency())
    -
    197  {
    -
    198  m_workers.reserve(numThreads);
    -
    199 
    -
    200  for(std::size_t i = 0; i < numThreads; ++i) {
    -
    201  m_workers.emplace_back([this]() -> void {
    -
    202  for(;;) {
    -
    203  std::function<void()> task{};
    -
    204  {
    -
    205  std::unique_lock<std::mutex> lock{ m_mutex };
    -
    206  m_cv.wait(lock, [this] {
    -
    207  return m_stop || !m_tasks.empty();
    -
    208  });
    -
    209 
    -
    210  if(m_stop && m_tasks.empty()) {
    -
    211  return;
    -
    212  }
    -
    213 
    -
    214  task = std::move(m_tasks.front());
    -
    215  m_tasks.pop();
    -
    216  }
    -
    217 
    -
    218  task();
    -
    219  }
    -
    220  });
    -
    221  }
    -
    222  }
    -
    223 
    -
    224  auto operator=(ThreadPool const&) -> ThreadPool& = delete;
    -
    225  auto operator=(ThreadPool &&) -> ThreadPool& = delete;
    -
    226 
    -
    227  template<typename F, typename... Args>
    -
    228  auto push(F&& f, Args&&... args)
    -
    229  -> std::future<std::invoke_result_t<F, Args...>>
    -
    230  {
    -
    231  using T = std::invoke_result_t<F, Args...>;
    -
    232 
    -
    233  auto task = std::make_shared<std::packaged_task<T()>>(
    -
    234  std::bind(std::forward<F>(f), std::forward<Args>(args)...));
    -
    235 
    -
    236  std::future<T> result = task->get_future();
    -
    237  {
    -
    238  std::unique_lock<std::mutex> lock{ m_mutex };
    -
    239 
    -
    240  if(m_stop) {
    -
    241  // throw std::runtime_error{
    -
    242  //"Attempted to push a thread to a terminated thread pool!"
    -
    243  //};
    -
    244  throw TestException{
    -
    245  "Attempted to push a thread to a terminated thread pool!"
    -
    246  };
    -
    247  }
    -
    248 
    -
    249  m_tasks.emplace([task] { (*task)(); });
    -
    250  }
    -
    251 
    -
    252  m_cv.notify_one();
    -
    253  return result;
    -
    254  }
    -
    255 };
    -
    256 
    -
    257 auto getTestId() -> int
    -
    258 {
    -
    259  static std::atomic<int> id{ 0 };
    -
    260  id.fetch_add(1);
    -
    261  return id.load();
    -
    262 }
    -
    263 
    -
    264 class TestSingleton
    -
    265 {
    -
    266 private:
    -
    267  TestSingleton() noexcept = default;
    -
    268 
    -
    269 public:
    -
    270  TestSingleton(TestSingleton const&) = delete;
    -
    271  TestSingleton(TestSingleton&&) = delete;
    -
    272  ~TestSingleton() noexcept = default;
    -
    273 
    -
    274  auto operator=(TestSingleton const&) -> TestSingleton& = delete;
    -
    275  auto operator=(TestSingleton&&) noexcept -> TestSingleton& = delete;
    -
    276 
    -
    277  static auto getInstance() -> std::vector<TestBase*>&
    -
    278  {
    -
    279  static std::vector<TestBase*> tests{};
    -
    280  return tests;
    -
    281  }
    -
    282 };
    -
    283 
    -
    284 auto operator+=(std::vector<TestBase*> tests, TestBase* test) -> void
    -
    285 {
    -
    286  tests.push_back(test);
    -
    287 }
    -
    288 
    -
    289 auto getTests() -> std::vector<TestBase*>&
    -
    290 {
    -
    291  return TestSingleton::getInstance();
    -
    292 }
    -
    293 
    -
    294 TestBase::TestBase(std::string testName, std::string file, int const line)
    -
    295  : m_name{ std::move(testName) }
    -
    296  , m_file{ std::move(file) }
    -
    297  , m_line{ line }
    -
    298 {
    -
    299  getTests() += this;
    -
    300  m_testId = getTestId();
    -
    301  m_output.open(sk::format("test_%1", m_testId));
    -
    302  sk::printlnTo(m_output, "%1\n%2\n%3", m_name, m_file, m_line);
    -
    303 }
    -
    304 
    -
    305 auto startsWith(std::string const& str, std::string const& pattern) -> bool
    -
    306 {
    -
    307  if(pattern.length() > str.length()) {
    -
    308  return false;
    -
    309  }
    -
    310 
    -
    311  for(std::size_t i = 0; i < pattern.length(); ++i) {
    -
    312  if(str[i] != pattern[i]) {
    -
    313  return false;
    -
    314  }
    -
    315  }
    -
    316 
    -
    317  return true;
    -
    318 }
    -
    319 
    -
    320 auto main(int, char*[]) noexcept -> int
    -
    321 {
    -
    322  int ret = EXIT_SUCCESS;
    -
    323  std::atomic<int> successful{ EXIT_SUCCESS };
    -
    324  {
    -
    325  ThreadPool pool{};
    -
    326  std::vector<std::future<void>> workers{};
    -
    327 
    -
    328  for(auto& test : getTests()) {
    -
    329 
    -
    330  try {
    -
    331  workers.emplace_back(
    -
    332  pool.push([&]() -> void { test->run(successful); }));
    -
    333  }
    -
    334  catch(std::exception const& e) {
    -
    335  sk::println("%1", e.what());
    -
    336  }
    -
    337  catch(...) {
    -
    338  sk::println("Uncaught exception!");
    -
    339  }
    -
    340  }
    -
    341 
    -
    342  for(auto& worker : workers) {
    -
    343  worker.get();
    -
    344  }
    -
    345  }
    -
    346  ret = successful.load();
    -
    347 
    -
    348  namespace fs = std::filesystem;
    -
    349 
    -
    350  auto currentDir = fs::path{ "." };
    -
    351  fs::directory_iterator dirIter{};
    -
    352 
    -
    353  sk::println("Report:");
    -
    354  for(fs::directory_iterator file(currentDir); file != dirIter; ++file) {
    -
    355  if(startsWith(file->path().string(), "./test_")) {
    -
    356  std::ifstream f{ file->path().string() };
    -
    357  std::string line{};
    -
    358 
    -
    359  std::getline(f, line);
    -
    360  sk::print("%1 defined at ", line);
    -
    361  std::getline(f, line);
    -
    362  sk::print("%1", line);
    -
    363  std::getline(f, line);
    -
    364  sk::println("[%1]:", line);
    -
    365 
    -
    366  bool allPassed = true;
    -
    367 
    -
    368  while(std::getline(f, line)) {
    -
    369  if(line.empty()) {
    -
    370  continue;
    -
    371  }
    -
    372  allPassed = false;
    -
    373  sk::println("%1", line);
    -
    374  }
    -
    375 
    -
    376  if(allPassed) {
    -
    377  sk::println("\t%1", "All tests here passed!");
    -
    378  }
    -
    379  else {
    -
    380  sk::println("");
    -
    381  }
    -
    382  }
    -
    383  }
    -
    384 
    -
    385  return ret;
    -
    386 }
    -
    387 
    -
    388 #endif
    -
    389 
    -
    390 #endif // !HELPER_TEST_HPP
    -
    - - - - - - diff --git a/docs/tests_2CMakeLists_8txt.xml b/docs/tests_2CMakeLists_8txt.xml new file mode 100644 index 0000000..abc58ba --- /dev/null +++ b/docs/tests_2CMakeLists_8txt.xml @@ -0,0 +1,30 @@ + + + + CMakeLists.txt + + + + add_executable + (SkribbleTests ${CMAKE_CURRENT_SOURCE_DIR}/cached_resource_test.cpp ${CMAKE_CURRENT_SOURCE_DIR}/fcached_resource_test.cpp ${CMAKE_CURRENT_SOURCE_DIR}/format_test.cpp ${CMAKE_CURRENT_SOURCE_DIR}/message_parser_test.cpp ${CMAKE_CURRENT_SOURCE_DIR}/../src/message_parser.cpp) target_include_directories(SkribbleTests PRIVATE $ + add_executable + + SkribbleTests ${CMAKE_CURRENT_SOURCE_DIR}/cached_resource_test.cpp ${CMAKE_CURRENT_SOURCE_DIR}/fcached_resource_test.cpp ${CMAKE_CURRENT_SOURCE_DIR}/format_test.cpp ${CMAKE_CURRENT_SOURCE_DIR}/message_parser_test.cpp ${CMAKE_CURRENT_SOURCE_DIR}/../src/message_parser. + cpp + + + + + + + + + + + + + + + + +