diff options
author | Sebastián Barschkis <sebbas@sebbas.org> | 2019-11-08 14:24:25 +0300 |
---|---|---|
committer | Sebastián Barschkis <sebbas@sebbas.org> | 2019-11-08 14:24:25 +0300 |
commit | 1cd70c4f090e6814594818a39fe0aefccfd78e8a (patch) | |
tree | f74ad661258d25d0fa5ddd158a113c4e1d90911a /doc | |
parent | ccbf9ea4901e09d681675630515a7b355011af1f (diff) | |
parent | 45a03057fa33e043b08027a8353d133948b85ca8 (diff) |
Merge branch 'master' into fluid-mantaflow
Diffstat (limited to 'doc')
-rw-r--r-- | doc/doxygen/Doxyfile | 54 | ||||
-rwxr-xr-x | doc/manpage/blender.1.py | 2 | ||||
-rw-r--r-- | doc/python_api/examples/bpy.app.timers.1.py | 2 | ||||
-rw-r--r-- | doc/python_api/examples/bpy.app.timers.2.py | 2 | ||||
-rw-r--r-- | doc/python_api/examples/bpy.app.timers.3.py | 2 | ||||
-rw-r--r-- | doc/python_api/examples/bpy.app.timers.4.py | 2 | ||||
-rw-r--r-- | doc/python_api/examples/bpy.types.Depsgraph.6.py | 2 | ||||
-rw-r--r-- | doc/python_api/examples/bpy.types.RenderEngine.py | 16 | ||||
-rwxr-xr-x | doc/python_api/sphinx_doc_update.py | 38 |
9 files changed, 77 insertions, 43 deletions
diff --git a/doc/doxygen/Doxyfile b/doc/doxygen/Doxyfile index 366d0b1b507..c07a80bf0d5 100644 --- a/doc/doxygen/Doxyfile +++ b/doc/doxygen/Doxyfile @@ -1,4 +1,4 @@ -# Doxyfile 1.8.15 +# Doxyfile 1.8.16 # This file describes the settings to be used by the documentation system # doxygen (www.doxygen.org) for a project. @@ -38,7 +38,7 @@ PROJECT_NAME = Blender # could be handy for archiving the generated documentation or if some version # control system is used. -PROJECT_NUMBER = "V2.81" +PROJECT_NUMBER = "V2.82" # Using the PROJECT_BRIEF tag one can provide an optional one line description # for a project that appears at the top of each page and should give viewer a @@ -197,6 +197,16 @@ SHORT_NAMES = NO JAVADOC_AUTOBRIEF = NO +# If the JAVADOC_BANNER tag is set to YES then doxygen will interpret a line +# such as +# /*************** +# as being the beginning of a Javadoc-style comment "banner". If set to NO, the +# Javadoc-style will behave just like regular comments and it will not be +# interpreted by doxygen. +# The default value is: NO. + +JAVADOC_BANNER = NO + # If the QT_AUTOBRIEF tag is set to YES then doxygen will interpret the first # line (until the first dot) of a Qt-style comment as the brief description. If # set to NO, the Qt-style will behave just like regular Qt-style comments (thus @@ -329,7 +339,7 @@ MARKDOWN_SUPPORT = YES # to that level are automatically included in the table of contents, even if # they do not have an id attribute. # Note: This feature currently applies only to Markdown headings. -# Minimum value: 0, maximum value: 99, default value: 0. +# Minimum value: 0, maximum value: 99, default value: 5. # This tag requires that the tag MARKDOWN_SUPPORT is set to YES. TOC_INCLUDE_HEADINGS = 0 @@ -465,6 +475,12 @@ EXTRACT_ALL = YES EXTRACT_PRIVATE = NO +# If the EXTRACT_PRIV_VIRTUAL tag is set to YES, documented private virtual +# methods of a class will be included in the documentation. +# The default value is: NO. + +EXTRACT_PRIV_VIRTUAL = NO + # If the EXTRACT_PACKAGE tag is set to YES, all members with package or internal # scope will be included in the documentation. # The default value is: NO. @@ -543,7 +559,7 @@ INTERNAL_DOCS = YES # names in lower-case letters. If set to YES, upper-case letters are also # allowed. This is useful if you have classes or files whose names only differ # in case and if your file system supports case sensitive file names. Windows -# and Mac users are advised to set this option to NO. +# (including Cygwin) ands Mac users are advised to set this option to NO. # The default value is: system dependent. CASE_SENSE_NAMES = YES @@ -1368,7 +1384,7 @@ QCH_FILE = # The QHP_NAMESPACE tag specifies the namespace to use when generating Qt Help # Project output. For more information please see Qt Help Project / Namespace -# (see: http://doc.qt.io/archives/qt-4.8/qthelpproject.html#namespace). +# (see: https://doc.qt.io/archives/qt-4.8/qthelpproject.html#namespace). # The default value is: org.doxygen.Project. # This tag requires that the tag GENERATE_QHP is set to YES. @@ -1376,7 +1392,7 @@ QHP_NAMESPACE = org.doxygen.Project # The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating Qt # Help Project output. For more information please see Qt Help Project / Virtual -# Folders (see: http://doc.qt.io/archives/qt-4.8/qthelpproject.html#virtual- +# Folders (see: https://doc.qt.io/archives/qt-4.8/qthelpproject.html#virtual- # folders). # The default value is: doc. # This tag requires that the tag GENERATE_QHP is set to YES. @@ -1385,7 +1401,7 @@ QHP_VIRTUAL_FOLDER = doc # If the QHP_CUST_FILTER_NAME tag is set, it specifies the name of a custom # filter to add. For more information please see Qt Help Project / Custom -# Filters (see: http://doc.qt.io/archives/qt-4.8/qthelpproject.html#custom- +# Filters (see: https://doc.qt.io/archives/qt-4.8/qthelpproject.html#custom- # filters). # This tag requires that the tag GENERATE_QHP is set to YES. @@ -1393,7 +1409,7 @@ QHP_CUST_FILTER_NAME = # The QHP_CUST_FILTER_ATTRS tag specifies the list of the attributes of the # custom filter to add. For more information please see Qt Help Project / Custom -# Filters (see: http://doc.qt.io/archives/qt-4.8/qthelpproject.html#custom- +# Filters (see: https://doc.qt.io/archives/qt-4.8/qthelpproject.html#custom- # filters). # This tag requires that the tag GENERATE_QHP is set to YES. @@ -1401,7 +1417,7 @@ QHP_CUST_FILTER_ATTRS = # The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this # project's filter section matches. Qt Help Project / Filter Attributes (see: -# http://doc.qt.io/archives/qt-4.8/qthelpproject.html#filter-attributes). +# https://doc.qt.io/archives/qt-4.8/qthelpproject.html#filter-attributes). # This tag requires that the tag GENERATE_QHP is set to YES. QHP_SECT_FILTER_ATTRS = @@ -1680,10 +1696,11 @@ LATEX_CMD_NAME = latex MAKEINDEX_CMD_NAME = makeindex # The LATEX_MAKEINDEX_CMD tag can be used to specify the command name to -# generate index for LaTeX. +# generate index for LaTeX. In case there is no backslash (\) as first character +# it will be automatically added in the LaTeX code. # Note: This tag is used in the generated output file (.tex). # See also: MAKEINDEX_CMD_NAME for the part in the Makefile / make.bat. -# The default value is: \makeindex. +# The default value is: makeindex. # This tag requires that the tag GENERATE_LATEX is set to YES. LATEX_MAKEINDEX_CMD = \makeindex @@ -2176,12 +2193,6 @@ EXTERNAL_GROUPS = YES EXTERNAL_PAGES = YES -# The PERL_PATH should be the absolute path and name of the perl script -# interpreter (i.e. the result of 'which perl'). -# The default file (with absolute path) is: /usr/bin/perl. - -PERL_PATH = /usr/bin/perl - #--------------------------------------------------------------------------- # Configuration options related to the dot tool #--------------------------------------------------------------------------- @@ -2195,15 +2206,6 @@ PERL_PATH = /usr/bin/perl CLASS_DIAGRAMS = NO -# You can define message sequence charts within doxygen comments using the \msc -# command. Doxygen will then run the mscgen tool (see: -# http://www.mcternan.me.uk/mscgen/)) to produce the chart and insert it in the -# documentation. The MSCGEN_PATH tag allows you to specify the directory where -# the mscgen tool resides. If left empty the tool is assumed to be found in the -# default search path. - -MSCGEN_PATH = - # You can include diagrams made with dia in doxygen documentation. Doxygen will # then run dia to produce the diagram and insert it in the documentation. The # DIA_PATH tag allows you to specify the directory where the dia binary resides. diff --git a/doc/manpage/blender.1.py b/doc/manpage/blender.1.py index fc2200ab859..da83abe8442 100755 --- a/doc/manpage/blender.1.py +++ b/doc/manpage/blender.1.py @@ -62,7 +62,7 @@ if blender_date is None: # Happens when built without WITH_BUILD_INFO e.g. date_string = time.strftime("%B %d, %Y", time.gmtime(int(os.environ.get('SOURCE_DATE_EPOCH', time.time())))) else: - blender_date = blender_date.strip().partition(" ")[2] # remove 'date:' prefix + blender_date = blender_date.strip().partition(" ")[2] # remove 'date:' prefix date_string = time.strftime("%B %d, %Y", time.strptime(blender_date, "%Y-%m-%d")) outfile = open(outfilename, "w") diff --git a/doc/python_api/examples/bpy.app.timers.1.py b/doc/python_api/examples/bpy.app.timers.1.py index bae3b94b24a..a8ce7fde552 100644 --- a/doc/python_api/examples/bpy.app.timers.1.py +++ b/doc/python_api/examples/bpy.app.timers.1.py @@ -4,7 +4,9 @@ Run a Function in x Seconds """ import bpy + def in_5_seconds(): print("Hello World") + bpy.app.timers.register(in_5_seconds, first_interval=5) diff --git a/doc/python_api/examples/bpy.app.timers.2.py b/doc/python_api/examples/bpy.app.timers.2.py index c663959c209..e17d43cccd8 100644 --- a/doc/python_api/examples/bpy.app.timers.2.py +++ b/doc/python_api/examples/bpy.app.timers.2.py @@ -4,8 +4,10 @@ Run a Function every x Seconds """ import bpy + def every_2_seconds(): print("Hello World") return 2.0 + bpy.app.timers.register(every_2_seconds) diff --git a/doc/python_api/examples/bpy.app.timers.3.py b/doc/python_api/examples/bpy.app.timers.3.py index 79daf6a7740..a738f9ca01c 100644 --- a/doc/python_api/examples/bpy.app.timers.3.py +++ b/doc/python_api/examples/bpy.app.timers.3.py @@ -6,6 +6,7 @@ import bpy counter = 0 + def run_10_times(): global counter counter += 1 @@ -14,4 +15,5 @@ def run_10_times(): return None return 0.1 + bpy.app.timers.register(run_10_times) diff --git a/doc/python_api/examples/bpy.app.timers.4.py b/doc/python_api/examples/bpy.app.timers.4.py index 6cdee564bb5..c14bc15166c 100644 --- a/doc/python_api/examples/bpy.app.timers.4.py +++ b/doc/python_api/examples/bpy.app.timers.4.py @@ -5,8 +5,10 @@ Assign parameters to functions import bpy import functools + def print_message(message): print("Message:", message) + bpy.app.timers.register(functools.partial(print_message, "Hello"), first_interval=2.0) bpy.app.timers.register(functools.partial(print_message, "World"), first_interval=3.0) diff --git a/doc/python_api/examples/bpy.types.Depsgraph.6.py b/doc/python_api/examples/bpy.types.Depsgraph.6.py index 56e028e8813..1f809356b13 100644 --- a/doc/python_api/examples/bpy.types.Depsgraph.6.py +++ b/doc/python_api/examples/bpy.types.Depsgraph.6.py @@ -29,7 +29,7 @@ class OBJECT_OT_simple_exporter(bpy.types.Operator): # Happens for non-geometry objects. continue print(f"Exporting mesh with {len(mesh.vertices)} vertices " - f"at {object_instance.matrix_world}") + f"at {object_instance.matrix_world}") object_instace.to_mesh_clear() return {'FINISHED'} diff --git a/doc/python_api/examples/bpy.types.RenderEngine.py b/doc/python_api/examples/bpy.types.RenderEngine.py index 86ab4b3097d..45910194244 100644 --- a/doc/python_api/examples/bpy.types.RenderEngine.py +++ b/doc/python_api/examples/bpy.types.RenderEngine.py @@ -101,7 +101,7 @@ class CustomRenderEngine(bpy.types.RenderEngine): # Bind shader that converts from scene linear to display space, bgl.glEnable(bgl.GL_BLEND) - bgl.glBlendFunc(bgl.GL_ONE, bgl.GL_ONE_MINUS_SRC_ALPHA); + bgl.glBlendFunc(bgl.GL_ONE, bgl.GL_ONE_MINUS_SRC_ALPHA) self.bind_display_space_shader(scene) if not self.draw_data or self.draw_data.dimensions != dimensions: @@ -135,18 +135,18 @@ class CustomDrawData: # Bind shader that converts from scene linear to display space, # use the scene's color management settings. shader_program = bgl.Buffer(bgl.GL_INT, 1) - bgl.glGetIntegerv(bgl.GL_CURRENT_PROGRAM, shader_program); + bgl.glGetIntegerv(bgl.GL_CURRENT_PROGRAM, shader_program) # Generate vertex array self.vertex_array = bgl.Buffer(bgl.GL_INT, 1) bgl.glGenVertexArrays(1, self.vertex_array) bgl.glBindVertexArray(self.vertex_array[0]) - texturecoord_location = bgl.glGetAttribLocation(shader_program[0], "texCoord"); - position_location = bgl.glGetAttribLocation(shader_program[0], "pos"); + texturecoord_location = bgl.glGetAttribLocation(shader_program[0], "texCoord") + position_location = bgl.glGetAttribLocation(shader_program[0], "pos") - bgl.glEnableVertexAttribArray(texturecoord_location); - bgl.glEnableVertexAttribArray(position_location); + bgl.glEnableVertexAttribArray(texturecoord_location) + bgl.glEnableVertexAttribArray(position_location) # Generate geometry buffers for drawing textured quad position = [0.0, 0.0, width, 0.0, width, height, 0.0, height] @@ -178,7 +178,7 @@ class CustomDrawData: bgl.glActiveTexture(bgl.GL_TEXTURE0) bgl.glBindTexture(bgl.GL_TEXTURE_2D, self.texture[0]) bgl.glBindVertexArray(self.vertex_array[0]) - bgl.glDrawArrays(bgl.GL_TRIANGLE_FAN, 0, 4); + bgl.glDrawArrays(bgl.GL_TRIANGLE_FAN, 0, 4) bgl.glBindVertexArray(0) bgl.glBindTexture(bgl.GL_TEXTURE_2D, 0) @@ -201,6 +201,7 @@ def get_panels(): return panels + def register(): # Register the RenderEngine bpy.utils.register_class(CustomRenderEngine) @@ -208,6 +209,7 @@ def register(): for panel in get_panels(): panel.COMPAT_ENGINES.add('CUSTOM') + def unregister(): bpy.utils.unregister_class(CustomRenderEngine) diff --git a/doc/python_api/sphinx_doc_update.py b/doc/python_api/sphinx_doc_update.py index 995991c4afd..78bfd3c85b8 100755 --- a/doc/python_api/sphinx_doc_update.py +++ b/doc/python_api/sphinx_doc_update.py @@ -94,10 +94,10 @@ def main(): rsync_base = "rsync://%s@%s:%s" % (args.user, args.rsync_server, args.rsync_root) - blenver = blenver_zip = "" + blenver = api_blenver = api_blenver_zip = "" api_name = "" branch = "" - is_release = False + is_release = is_beta = False # I) Update local mirror using rsync. rsync_mirror_cmd = ("rsync", "--delete-after", "-avzz", rsync_base, args.mirror_dir) @@ -118,11 +118,14 @@ def main(): "import sys, bpy\n" "with open(sys.argv[-1], 'w') as f:\n" " is_release = bpy.app.version_cycle in {'rc', 'release'}\n" + " is_beta = bpy.app.version_cycle in {'beta'}\n" " branch = bpy.app.build_branch.split()[0].decode()\n" " f.write('%d\\n' % is_release)\n" + " f.write('%d\\n' % is_beta)\n" " f.write('%s\\n' % branch)\n" + " f.write('%d.%d%s\\n' % (bpy.app.version[0], bpy.app.version[1], bpy.app.version_char))\n" " f.write('%d.%d%s\\n' % (bpy.app.version[0], bpy.app.version[1], bpy.app.version_char)\n" - " if is_release else '%s\\n' % branch)\n" + " if (is_release or is_beta) else '%s\\n' % branch)\n" " f.write('%d_%d%s_release' % (bpy.app.version[0], bpy.app.version[1], bpy.app.version_char)\n" " if is_release else '%d_%d_%d' % bpy.app.version)\n" ) @@ -130,8 +133,9 @@ def main(): "--python-expr", getver_script, "--", getver_file) subprocess.run(get_ver_cmd) with open(getver_file) as f: - is_release, branch, blenver, blenver_zip = f.read().split("\n") + is_release, is_beta, branch, blenver, api_blenver, api_blenver_zip = f.read().split("\n") is_release = bool(int(is_release)) + is_beta = bool(int(is_beta)) os.remove(getver_file) # IV) Build doc. @@ -143,14 +147,17 @@ def main(): os.chdir(curr_dir) # V) Cleanup existing matching dir in server mirror (if any), and copy new doc. - api_name = blenver + api_name = api_blenver api_dir = os.path.join(args.mirror_dir, api_name) if os.path.exists(api_dir): - shutil.rmtree(api_dir) + if os.path.islink(api_dir): + os.remove(api_dir) + else: + shutil.rmtree(api_dir) os.rename(os.path.join(tmp_dir, "sphinx-out"), api_dir) # VI) Create zip archive. - zip_name = "blender_python_reference_%s" % blenver_zip # We can't use 'release' postfix here... + zip_name = "blender_python_reference_%s" % api_blenver_zip # We can't use 'release' postfix here... zip_path = os.path.join(args.mirror_dir, zip_name) with zipfile.ZipFile(zip_path, 'w') as zf: for dirname, _, filenames in os.walk(api_dir): @@ -163,12 +170,27 @@ def main(): # VII) Create symlinks and html redirects. if is_release: symlink = os.path.join(args.mirror_dir, "current") - os.remove(symlink) + if os.path.exists(symlink): + if os.path.islink(symlink): + os.remove(symlink) + else: + shutil.rmtree(symlink) os.symlink("./%s" % api_name, symlink) with open(os.path.join(args.mirror_dir, "250PythonDoc/index.html"), 'w') as f: f.write("<html><head><title>Redirecting...</title><meta http-equiv=\"REFRESH\"" "content=\"0;url=../%s/\"></head><body>Redirecting...</body></html>" % api_name) + elif is_beta: + # We do not have any particular symlink for that stage. + pass elif branch == "master": + # Also create a symlink from version number to actual master api doc. + symlink = os.path.join(args.mirror_dir, blenver) + if os.path.exists(symlink): + if os.path.islink(symlink): + os.remove(symlink) + else: + shutil.rmtree(symlink) + os.symlink("./%s" % api_name, symlink) with open(os.path.join(args.mirror_dir, "blender_python_api/index.html"), 'w') as f: f.write("<html><head><title>Redirecting...</title><meta http-equiv=\"REFRESH\"" "content=\"0;url=../%s/\"></head><body>Redirecting...</body></html>" % api_name) |