poxy 0.18.0__py3-none-any.whl → 0.19.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. poxy/generated/poxy.css +2 -1
  2. poxy/main.py +8 -1
  3. poxy/mcss/CONTRIBUTING.rst +1 -1
  4. poxy/mcss/CREDITS.rst +2 -0
  5. poxy/mcss/css/m-components.css +1 -1
  6. poxy/mcss/css/m-debug.css +1 -1
  7. poxy/mcss/css/m-documentation.css +1 -1
  8. poxy/mcss/css/m-grid.css +1 -1
  9. poxy/mcss/css/m-layout.css +1 -1
  10. poxy/mcss/documentation/__init__.py +1 -1
  11. poxy/mcss/documentation/_search.py +1 -1
  12. poxy/mcss/documentation/doxygen.py +202 -25
  13. poxy/mcss/documentation/python.py +66 -22
  14. poxy/mcss/documentation/search.js +1 -1
  15. poxy/mcss/plugins/ansilexer.py +1 -1
  16. poxy/mcss/plugins/dot2svg.py +1 -1
  17. poxy/mcss/plugins/latex2svgextra.py +1 -1
  18. poxy/mcss/plugins/m/__init__.py +1 -1
  19. poxy/mcss/plugins/m/abbr.py +1 -1
  20. poxy/mcss/plugins/m/alias.py +1 -1
  21. poxy/mcss/plugins/m/code.py +4 -5
  22. poxy/mcss/plugins/m/components.py +1 -1
  23. poxy/mcss/plugins/m/dot.py +1 -1
  24. poxy/mcss/plugins/m/dox.py +1 -1
  25. poxy/mcss/plugins/m/filesize.py +1 -1
  26. poxy/mcss/plugins/m/gh.py +1 -1
  27. poxy/mcss/plugins/m/gl.py +1 -1
  28. poxy/mcss/plugins/m/htmlsanity.py +14 -6
  29. poxy/mcss/plugins/m/images.py +1 -1
  30. poxy/mcss/plugins/m/link.py +1 -1
  31. poxy/mcss/plugins/m/math.py +1 -1
  32. poxy/mcss/plugins/m/metadata.py +1 -1
  33. poxy/mcss/plugins/m/plots.py +1 -1
  34. poxy/mcss/plugins/m/qr.py +1 -1
  35. poxy/mcss/plugins/m/sphinx.py +1 -1
  36. poxy/mcss/plugins/m/vk.py +1 -1
  37. poxy/project.py +24 -4
  38. poxy/run.py +86 -13
  39. poxy/version.txt +1 -1
  40. {poxy-0.18.0.dist-info → poxy-0.19.0.dist-info}/METADATA +11 -3
  41. {poxy-0.18.0.dist-info → poxy-0.19.0.dist-info}/RECORD +46 -46
  42. {poxy-0.18.0.dist-info → poxy-0.19.0.dist-info}/WHEEL +1 -1
  43. {poxy-0.18.0.dist-info → poxy-0.19.0.dist-info}/LICENSE.txt +0 -0
  44. {poxy-0.18.0.dist-info → poxy-0.19.0.dist-info}/entry_points.txt +0 -0
  45. {poxy-0.18.0.dist-info → poxy-0.19.0.dist-info}/top_level.txt +0 -0
  46. {poxy-0.18.0.dist-info → poxy-0.19.0.dist-info}/zip-safe +0 -0
@@ -3,7 +3,7 @@
3
3
  #
4
4
  # This file is part of m.css.
5
5
  #
6
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
6
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
7
7
  # Vladimír Vondruš <mosra@centrum.cz>
8
8
  # Copyright © 2020 Sergei Izmailov <sergei.a.izmailov@gmail.com>
9
9
  #
@@ -278,25 +278,40 @@ def is_underscored_and_undocumented(state: State, type, path, docstring):
278
278
  # Builtin dunder functions have hardcoded docstrings. This is totally useless
279
279
  # to have in the docs, so filter them out. Uh... kinda ugly.
280
280
  _filtered_builtin_functions = set([
281
+ # https://github.com/python/cpython/blob/401fff7423ca3c8bf1d02e594edfd1412616a559/Objects/typeobject.c#L10470
282
+ # Matching the order there, be sure to follow it when updating
283
+ ('__repr__', "Return repr(self)."),
284
+ ('__hash__', "Return hash(self)."),
285
+ ('__call__', "Call self as a function."),
286
+ ('__str__', "Return str(self)."),
287
+ ('__getattribute__', "Return getattr(self, name)."),
288
+ ('__getattr__', "Implement getattr(self, name)."),
289
+ ('__setattr__', "Implement setattr(self, name, value)."),
281
290
  ('__delattr__', "Implement delattr(self, name)."),
291
+ ('__lt__', "Return self<value."),
292
+ ('__le__', "Return self<=value."),
282
293
  ('__eq__', "Return self==value."),
283
- ('__ge__', "Return self>=value."),
284
- ('__getattribute__', "Return getattr(self, name)."),
294
+ ('__ne__', "Return self!=value."),
285
295
  ('__gt__', "Return self>value."),
286
- ('__hash__', "Return hash(self)."),
287
- ('__init__', "Initialize self. See help(type(self)) for accurate signature."),
296
+ ('__ge__', "Return self>=value."),
297
+ ('__iter__', "Implement iter(self)."),
298
+ ('__next__', "Implement next(self)."),
299
+ ('__get__', "Return an attribute of instance, which is of type owner."),
300
+ ('__set__', "Set an attribute of instance to value."),
301
+ ('__delete__', "Delete an attribute of instance."),
302
+ ('__init__',
303
+ "Initialize self. See help(type(self)) for accurate signature."),
304
+ ('__new__',
305
+ "Create and return a new object. See help(type) for accurate signature."),
306
+ ('__del__', "Called when the instance is about to be destroyed."),
307
+ # TODO there's many more, maybe just add all?
308
+
309
+ # https://github.com/python/cpython/blob/401fff7423ca3c8bf1d02e594edfd1412616a559/Objects/typeobject.c#L7342
288
310
  ('__init_subclass__',
289
311
  "This method is called when a class is subclassed.\n\n"
290
312
  "The default implementation does nothing. It may be\n"
291
313
  "overridden to extend subclasses.\n"),
292
- ('__le__', "Return self<=value."),
293
- ('__lt__', "Return self<value."),
294
- ('__ne__', "Return self!=value."),
295
- ('__new__',
296
- "Create and return a new object. See help(type) for accurate signature."),
297
- ('__repr__', "Return repr(self)."),
298
- ('__setattr__', "Implement setattr(self, name, value)."),
299
- ('__str__', "Return str(self)."),
314
+ # https://github.com/python/cpython/blob/401fff7423ca3c8bf1d02e594edfd1412616a559/Objects/typeobject.c#L7328
300
315
  ('__subclasshook__',
301
316
  "Abstract classes can override this to customize issubclass().\n\n"
302
317
  "This is invoked early on by abc.ABCMeta.__subclasscheck__().\n"
@@ -329,8 +344,16 @@ if sys.version_info >= (3, 11):
329
344
  ('__getstate__', "Helper for pickle.")
330
345
  })
331
346
 
347
+ # Python 3.12 changes the __format__ docstring
348
+ if sys.version_info >= (3, 11):
349
+ _filtered_builtin_functions.update({
350
+ ('__format__', "Default object formatter.\n\nReturn str(self) if format_spec is empty. Raise TypeError otherwise.")
351
+ })
352
+
332
353
  _filtered_builtin_properties = set([
333
- ('__weakref__', "list of weak references to the object (if defined)")
354
+ # (if defined) is gone in https://github.com/python/cpython/issues/112266
355
+ # which is backported all the way to 3.11
356
+ ('__weakref__', "list of weak references to the object" if sys.version_info >= (3, 11) else "list of weak references to the object (if defined)")
334
357
  ])
335
358
 
336
359
  _automatically_created_by_attrs = """
@@ -472,10 +495,30 @@ def crawl_class(state: State, path: List[str], class_):
472
495
  # are added by typing.Generic on Py3.7+. Like above, can't
473
496
  # use isinstance(object, Generic) because "Class
474
497
  # typing.Generic cannot be used with class or instance
475
- # checks" and there's nothing else to catch on, so this
476
- # filters out all undocumented cases of these two
477
- if sys.version_info >= (3, 7) and name in ['__init_subclass__', '__class_getitem__'] and not object.__doc__:
478
- continue
498
+ # checks"
499
+ if sys.version_info >= (3, 7) and name == '__init_subclass__':
500
+ # Before 3.12 it's completely undocumented and there's
501
+ # nothing else to catch on, so this filters out all
502
+ # undocumented cases
503
+ if sys.version_info < (3, 12) and not object.__doc__:
504
+ continue
505
+ # https://github.com/python/cpython/blame/401fff7423ca3c8bf1d02e594edfd1412616a559/Objects/typevarobject.c#L2175
506
+ if object.__doc__ == "Function to initialize subclasses.":
507
+ continue
508
+ if sys.version_info >= (3, 7) and name == '__class_getitem__':
509
+ # Before 3.11 it's completely undocumented and there's
510
+ # nothing else to catch on, so this filters out all
511
+ # undocumented cases
512
+ if sys.version_info < (3, 11) and not object.__doc__:
513
+ continue
514
+ # In 3.11 they OTOH get something very unique,
515
+ # especially the markdown-like formatting
516
+ # https://github.com/python/cpython/pull/31021
517
+ # In 3.12 the extra spaces are removed
518
+ if sys.version_info >= (3, 12) and object.__doc__.startswith("Parameterizes a generic class.\n\nAt least, parameterizing a generic class is the *main* thing"):
519
+ continue
520
+ if sys.version_info >= (3, 11) and object.__doc__.startswith("Parameterizes a generic class.\n\n At least, parameterizing a generic class is the *main* thing"):
521
+ continue
479
522
  # ... or are auto-generated by attrs
480
523
  if state.config['ATTRS_COMPATIBILITY']:
481
524
  # All methods generated by attrs 20.1+ have a generic
@@ -1235,8 +1278,9 @@ def extract_annotation(state: State, referrer_path: List[str], annotation) -> Tu
1235
1278
  elif sys.version_info < (3, 7) and hasattr(annotation, '__name__'):
1236
1279
  name = 'typing.' + annotation.__name__
1237
1280
  args = annotation.__args__
1238
- # Any doesn't have __name__ in 3.6
1239
- elif sys.version_info < (3, 7) and annotation is typing.Any:
1281
+ # Any doesn't have __name__ in 3.6, and doesn't have anything in 3.11+
1282
+ # Not sure what commit caused that, probably https://github.com/python/cpython/pull/31841
1283
+ elif (sys.version_info < (3, 7) or sys.version_info >= (3, 11)) and annotation is typing.Any:
1240
1284
  name = 'typing.Any'
1241
1285
  args = None
1242
1286
  # Whoops, something we don't know yet. Warn and return a string
@@ -2188,7 +2232,7 @@ class ExtractImages(Transform):
2188
2232
 
2189
2233
  def apply(self):
2190
2234
  ExtractImages._external_data = set()
2191
- for image in self.document.traverse(docutils.nodes.image):
2235
+ for image in self.document.findall(docutils.nodes.image):
2192
2236
  # Skip absolute URLs
2193
2237
  if urllib.parse.urlparse(image['uri']).netloc: continue
2194
2238
 
@@ -2368,7 +2412,7 @@ def render_page(state: State, path, input_filename, env):
2368
2412
 
2369
2413
  # Extract metadata from the page
2370
2414
  metadata = {}
2371
- for docinfo in pub.document.traverse(docutils.nodes.docinfo):
2415
+ for docinfo in pub.document.findall(docutils.nodes.docinfo):
2372
2416
  for element in docinfo.children:
2373
2417
  if element.tagname == 'field':
2374
2418
  name_elem, body_elem = element.children
@@ -1,7 +1,7 @@
1
1
  /*
2
2
  This file is part of m.css.
3
3
 
4
- Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  Vladimír Vondruš <mosra@centrum.cz>
6
6
 
7
7
  Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  # Copyright © 2020 Blair Conrad <blair@blairconrad.com>
7
7
  #
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Loosely based on https://github.com/Nitron/pelican-alias,
@@ -1,8 +1,9 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
+ # Copyright © 2024 John Turner <7strbass@gmail.com>
6
7
  #
7
8
  # Permission is hereby granted, free of charge, to any person obtaining a
8
9
  # copy of this software and associated documentation files (the "Software"),
@@ -28,7 +29,6 @@ import os.path
28
29
  import docutils
29
30
  from docutils.parsers import rst
30
31
  from docutils.parsers.rst.roles import set_classes
31
- from docutils.utils.error_reporting import SafeString, ErrorString, locale_encoding
32
32
  from docutils.parsers.rst import Directive, directives
33
33
  import docutils.parsers.rst.directives.misc
34
34
  from docutils import io, nodes, utils, statemachine
@@ -188,7 +188,6 @@ class Include(docutils.parsers.rst.directives.misc.Include):
188
188
  path = os.path.join(self.standard_include_path, path[1:-1])
189
189
  path = os.path.normpath(os.path.join(source_dir, path))
190
190
  path = utils.relative_path(None, path)
191
- path = nodes.reprunicode(path)
192
191
  e_handler=self.state.document.settings.input_encoding_error_handler
193
192
  tab_width = self.options.get(
194
193
  'tab-width', self.state.document.settings.tab_width)
@@ -203,7 +202,7 @@ class Include(docutils.parsers.rst.directives.misc.Include):
203
202
  (self.name, SafeString(path)))
204
203
  except IOError as error:
205
204
  raise self.severe('Problems with "%s" directive path:\n%s.' %
206
- (self.name, ErrorString(error)))
205
+ (self.name, str(error)))
207
206
  startline = self.options.get('start-line', None)
208
207
  endline = self.options.get('end-line', None)
209
208
  try:
@@ -214,7 +213,7 @@ class Include(docutils.parsers.rst.directives.misc.Include):
214
213
  rawtext = include_file.read()
215
214
  except UnicodeError as error:
216
215
  raise self.severe('Problem with "%s" directive:\n%s' %
217
- (self.name, ErrorString(error)))
216
+ (self.name, str(error)))
218
217
  # start-after/end-before: no restrictions on newlines in match-text,
219
218
  # and no restrictions on matching inside lines vs. line boundaries
220
219
  after_text = self.options.get('start-after', None)
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
poxy/mcss/plugins/m/gh.py CHANGED
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
poxy/mcss/plugins/m/gl.py CHANGED
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -69,6 +69,14 @@ docutils_settings = {
69
69
  'embed_stylesheet': False
70
70
  }
71
71
 
72
+ # findall() is new in docutils 0.18, replacing traverse() because that one was
73
+ # attempted to be changed to return an iterator instead of a list, which broke
74
+ # Sphinx, so it instead got deprecated in favor of findall() which is the same
75
+ # as traverse() returning an iterator was. To retain compatibility with earlier
76
+ # versions, add an alias.
77
+ if not hasattr(docutils.nodes.Node, 'findall'):
78
+ setattr(docutils.nodes.Node, 'findall', docutils.nodes.Node.traverse)
79
+
72
80
  words_re = re.compile(r'\w+', re.UNICODE|re.X)
73
81
 
74
82
  def extract_document_language(document):
@@ -76,7 +84,7 @@ def extract_document_language(document):
76
84
  language = document.settings.language_code
77
85
 
78
86
  # Then try to find the :lang: metadata option
79
- for field in document.traverse(nodes.field):
87
+ for field in document.findall(nodes.field):
80
88
  assert isinstance(field[0], nodes.field_name)
81
89
  assert isinstance(field[1], nodes.field_body)
82
90
  # field_body -> paragraph -> text
@@ -137,7 +145,7 @@ class SmartQuotes(docutils.transforms.universal.SmartQuotes):
137
145
 
138
146
  # "Educate" quotes in normal text. Handle each block of text
139
147
  # (TextElement node) as a unit to keep context around inline nodes:
140
- for node in self.document.traverse(nodes.TextElement):
148
+ for node in self.document.findall(nodes.TextElement):
141
149
  # skip preformatted text blocks and special elements:
142
150
  if isinstance(node, (nodes.FixedTextElement, nodes.Special)):
143
151
  continue
@@ -148,7 +156,7 @@ class SmartQuotes(docutils.transforms.universal.SmartQuotes):
148
156
  # list of text nodes in the "text block":
149
157
  # Patched here to exclude more stuff.
150
158
  txtnodes = []
151
- for txtnode in node.traverse(nodes.Text):
159
+ for txtnode in node.findall(nodes.Text):
152
160
  if not can_apply_typography(txtnode): continue
153
161
  # Don't convert -- in option strings
154
162
  if isinstance(txtnode.parent, nodes.option_string): continue
@@ -204,12 +212,12 @@ class Pyphen(Transform):
204
212
  pyphen_for_lang = {}
205
213
 
206
214
  # Go through all text words and hyphenate them
207
- for node in self.document.traverse(nodes.TextElement):
215
+ for node in self.document.findall(nodes.TextElement):
208
216
  # Skip preformatted text blocks and special elements
209
217
  if isinstance(node, (nodes.FixedTextElement, nodes.Special)):
210
218
  continue
211
219
 
212
- for txtnode in node.traverse(nodes.Text):
220
+ for txtnode in node.findall(nodes.Text):
213
221
  if not can_apply_typography(txtnode): continue
214
222
 
215
223
  # Don't hyphenate document title. Not part of
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
poxy/mcss/plugins/m/qr.py CHANGED
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
@@ -3,7 +3,7 @@
3
3
  #
4
4
  # This file is part of m.css.
5
5
  #
6
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
6
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
7
7
  # Vladimír Vondruš <mosra@centrum.cz>
8
8
  #
9
9
  # Permission is hereby granted, free of charge, to any person obtaining a
poxy/mcss/plugins/m/vk.py CHANGED
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # This file is part of m.css.
3
3
  #
4
- # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023
4
+ # Copyright © 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024
5
5
  # Vladimír Vondruš <mosra@centrum.cz>
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a
poxy/project.py CHANGED
@@ -379,6 +379,7 @@ class Defaults(object):
379
379
  r'std::countr_zero(?:\(\))?': r'https://en.cppreference.com/w/cpp/numeric/countr_zero',
380
380
  r'std::enable_if(?:_t)?': r'https://en.cppreference.com/w/cpp/types/enable_if',
381
381
  r'std::exceptions?': r'https://en.cppreference.com/w/cpp/error/exception',
382
+ r'std::expecteds?': r'https://en.cppreference.com/w/cpp/utility/expected',
382
383
  r'std::floor[fl]?(?:\(\))?': r'https://en.cppreference.com/w/cpp/numeric/math/floor',
383
384
  r'std::fpos': r'https://en.cppreference.com/w/cpp/io/fpos',
384
385
  r'std::has_single_bit(?:\(\))?': r'https://en.cppreference.com/w/cpp/numeric/has_single_bit',
@@ -440,6 +441,8 @@ class Defaults(object):
440
441
  r'std::unordered_sets?': r'https://en.cppreference.com/w/cpp/container/unordered_set',
441
442
  r'std::vectors?': r'https://en.cppreference.com/w/cpp/container/vector',
442
443
  r'std::atomic[a-zA-Z_0-9]*': r'https://en.cppreference.com/w/cpp/atomic/atomic',
444
+ r'std::to_underlying(?:\(\))?': r'https://en.cppreference.com/w/cpp/utility/to_underlying',
445
+ r'std::move_only_functions?': r'https://en.cppreference.com/w/cpp/utility/functional/move_only_function',
443
446
  # named requirements
444
447
  r'Allocators?': r'https://en.cppreference.com/w/cpp/named_req/Allocator',
445
448
  r'AllocatorAwareContainers?': r'https://en.cppreference.com/w/cpp/named_req/AllocatorAwareContainer',
@@ -497,13 +500,13 @@ class Defaults(object):
497
500
  r'SeedSequences?': r'https://en.cppreference.com/w/cpp/named_req/SeedSequence',
498
501
  r'SequenceContainers?': r'https://en.cppreference.com/w/cpp/named_req/SequenceContainer',
499
502
  r'SharedLockables?': r'https://en.cppreference.com/w/cpp/named_req/SharedLockable',
500
- r'SharedMutexs?': r'https://en.cppreference.com/w/cpp/named_req/SharedMutex',
503
+ r'SharedMutexes?': r'https://en.cppreference.com/w/cpp/named_req/SharedMutex',
501
504
  r'SharedTimedLockables?': r'https://en.cppreference.com/w/cpp/named_req/SharedTimedLockable',
502
- r'SharedTimedMutexs?': r'https://en.cppreference.com/w/cpp/named_req/SharedTimedMutex',
505
+ r'SharedTimedMutexes?': r'https://en.cppreference.com/w/cpp/named_req/SharedTimedMutex',
503
506
  r'StandardLayoutTypes?': r'https://en.cppreference.com/w/cpp/named_req/StandardLayoutType',
504
507
  r'Swappables?': r'https://en.cppreference.com/w/cpp/named_req/Swappable',
505
508
  r'TimedLockables?': r'https://en.cppreference.com/w/cpp/named_req/TimedLockable',
506
- r'TimedMutexs?': r'https://en.cppreference.com/w/cpp/named_req/TimedMutex',
509
+ r'TimedMutexes?': r'https://en.cppreference.com/w/cpp/named_req/TimedMutex',
507
510
  r'TransformationTraits?': r'https://en.cppreference.com/w/cpp/named_req/TransformationTrait',
508
511
  r'TrivialClocks?': r'https://en.cppreference.com/w/cpp/named_req/TrivialClock',
509
512
  r'TriviallyCopyables?': r'https://en.cppreference.com/w/cpp/named_req/TriviallyCopyable',
@@ -514,6 +517,14 @@ class Defaults(object):
514
517
  r'UniformRandomBitGenerators?': r'https://en.cppreference.com/w/cpp/named_req/UniformRandomBitGenerator',
515
518
  r'UnorderedAssociativeContainers?': r'https://en.cppreference.com/w/cpp/named_req/UnorderedAssociativeContainer',
516
519
  r'ValueSwappables?': r'https://en.cppreference.com/w/cpp/named_req/ValueSwappable',
520
+ # other misc cppreference pages
521
+ r'(?:RAII|[Rr]esource[ -][Aa]cquisition[ -][Ii]s[ -][Ii]nitiali[sz]ation(?: \(RAII\))?)': r'https://en.cppreference.com/w/cpp/language/raii',
522
+ r'(?:CRTP|[Cc]uriously[ -][Rr]ecurring[ -][Tt]emplate[ -][Pp]attern(?: \(CRTP\))?)': r'https://en.wikipedia.org/wiki/Curiously_recurring_template_pattern',
523
+ r'(?:CTAD|[Cc]lass[ -][Tt]emplate[ -][Aa]rgument[ -][Dd]eduction(?: \(CTAD\))?)': r'https://en.cppreference.com/w/cpp/language/class_template_argument_deduction',
524
+ r'(?:EBC?O|[Ee]mpty[ -][Bb]ase[ -](?:[Cc]lass[ -])?[Oo]ptimi[sz]ations?(?: \(EBC?O\))?)': r'https://en.cppreference.com/w/cpp/language/ebo',
525
+ r'(?:UDLs?|[Uu]ser[ -][Dd]efined[ -][Ll]iterals?(?:[ -][Oo]perators?)?(?: \(UDLs?\))?)': r'https://en.cppreference.com/w/cpp/language/user_literal',
526
+ r'(?:N?RVO|[Cc]opy[ -][Ee]lision|(?:[Nn]amed[ -])?[Rr]eturn[ -][Vv]alue[ -][Oo]ptimi[sz]ations?(?: \(N?RVO\))?)': r'https://en.cppreference.com/w/cpp/language/copy_elision',
527
+ r'INVOKE(?:(?:<|&lt;)R(?:>|&gt;))?(?: [Ee]xpressions?)?': r'https://en.cppreference.com/w/cpp/utility/functional',
517
528
  # windows
518
529
  r'(?:L?P)?(?:'
519
530
  + r'D?WORD(?:32|64|_PTR)?|HANDLE|HMODULE|BOOL(?:EAN)?'
@@ -549,6 +560,8 @@ class Defaults(object):
549
560
  r'(?:::)?FPositionVertexBuffer(?:s)?': r'https://docs.unrealengine.com/4.27/en-US/API/Runtime/Engine/Rendering/FPositionVertexBuffer/',
550
561
  r'(?:::)?TArrayView(?:s)?': r'https://docs.unrealengine.com/4.27/en-US/API/Runtime/Core/Containers/TArrayView/',
551
562
  r'(?:::)?TArray(?:s)?': r'https://docs.unrealengine.com/4.27/en-US/API/Runtime/Core/Containers/TArray/',
563
+ # fmtlib
564
+ r'fmt::(?:v?format(?:_string|_to|ted_size|ter)?|memory_buffer|string_view|runtime|print|to_w?string|underlying|ptr|emphasis|styled)s?': 'https://fmt.dev/latest/api.html',
552
565
  }
553
566
  navbar = (r'files', r'groups', r'namespaces', r'classes', r'concepts')
554
567
  navbar_all = (r'pages', *navbar, r'repo', r'theme')
@@ -1253,7 +1266,11 @@ class Context(object):
1253
1266
  if config_path is not None:
1254
1267
  self.config_path = coerce_path(config_path).resolve()
1255
1268
  if self.config_path.is_dir():
1256
- self.config_path = Path(self.config_path, r'poxy.toml')
1269
+ for candidate in (r'poxy.toml', r'docs/poxy.toml', r'doc/poxy.toml', r'doxygen/poxy.toml'):
1270
+ candidate_path = self.config_path / candidate
1271
+ if candidate_path and candidate_path.is_file():
1272
+ self.config_path = candidate_path
1273
+ break
1257
1274
  if not self.config_path.is_file():
1258
1275
  raise Error(rf"Config '{self.config_path}' did not exist or was not a file")
1259
1276
  if copy_config_to is not None and self.config_path.is_file():
@@ -1282,8 +1299,11 @@ class Context(object):
1282
1299
 
1283
1300
  # temp xml output path used by doxygen
1284
1301
  self.temp_xml_dir = Path(self.temp_dir, r'xml')
1302
+ self.temp_original_xml_dir = Path(self.temp_dir, r'xml_original')
1285
1303
  self.verbose_value(r'Context.temp_xml_dir', self.temp_xml_dir)
1304
+ self.verbose_value(r'Context.temp_original_xml_dir', self.temp_original_xml_dir)
1286
1305
  assert self.temp_xml_dir.is_absolute()
1306
+ assert self.temp_original_xml_dir.is_absolute()
1287
1307
 
1288
1308
  # xml output path (--xml)
1289
1309
  self.xml_dir = Path(self.output_dir, r'xml')