Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sun_position')
-rw-r--r--sun_position/__init__.py13
-rw-r--r--sun_position/properties.py1
-rw-r--r--sun_position/translations.py82
-rw-r--r--sun_position/ui_sun.py8
4 files changed, 64 insertions, 40 deletions
diff --git a/sun_position/__init__.py b/sun_position/__init__.py
index 9a3e5b72..5b2a89ce 100644
--- a/sun_position/__init__.py
+++ b/sun_position/__init__.py
@@ -48,16 +48,13 @@ def register():
register_classes()
bpy.types.Scene.sun_pos_properties = (
bpy.props.PointerProperty(type=properties.SunPosProperties,
- name="Sun Position",
- description="Sun Position Settings"))
-
- bpy.app.translations.register(__name__, translations.translations_dict)
+ name="Sun Position",
+ description="Sun Position Settings"))
bpy.app.handlers.frame_change_post.append(sun_calc.sun_handler)
-
+ bpy.app.translations.register(__name__, translations.translations_dict)
def unregister():
- del bpy.types.Scene.sun_pos_properties
- unregister_classes()
-
bpy.app.translations.unregister(__name__)
bpy.app.handlers.frame_change_post.remove(sun_calc.sun_handler)
+ del bpy.types.Scene.sun_pos_properties
+ unregister_classes()
diff --git a/sun_position/properties.py b/sun_position/properties.py
index ac791d43..af2734a4 100644
--- a/sun_position/properties.py
+++ b/sun_position/properties.py
@@ -174,6 +174,7 @@ class SunPosProperties(PropertyGroup):
update=sun_update)
bind_to_sun: BoolProperty(
+ name="Bind Texture to Sun",
description="If true, Environment texture moves with sun",
default=False,
update=sun_update)
diff --git a/sun_position/translations.py b/sun_position/translations.py
index cd247ffd..c50b797c 100644
--- a/sun_position/translations.py
+++ b/sun_position/translations.py
@@ -1,11 +1,16 @@
# SPDX-License-Identifier: GPL-2.0-or-later
+# ##### BEGIN AUTOGENERATED I18N SECTION #####
+# NOTE: You can safely move around this auto-generated block (with the begin/end markers!),
+# and edit the translations by hand.
+# Just carefully respect the format of the tuple!
+
# Tuple of tuples:
# ((msgctxt, msgid), (sources, gen_comments), (lang, translation, (is_fuzzy, comments)), ...)
translations_tuple = (
(("*", ""),
((), ()),
- ("fr_FR", "Project-Id-Version: Sun Position 3.1.2 (0)\nReport-Msgid-Bugs-To: \nPOT-Creation-Date: 2022-06-30 15:02:06.261278\nPO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\nLast-Translator: FULL NAME <EMAIL@ADDRESS>\nLanguage-Team: LANGUAGE <LL@li.org>\nLanguage: __POT__\nMIME-Version: 1.0\nContent-Type: text/plain; charset=UTF-8\nContent-Transfer-Encoding: 8bit",
+ ("fr_FR", "Project-Id-Version: Sun Position 3.1.2 (0)\n",
(False,
("Blender's translation file (po format).",
"Copyright (C) 2022 The Blender Foundation.",
@@ -100,7 +105,8 @@ translations_tuple = (
),
(("*", "Sun Position"),
(("bpy.types.Scene.sun_pos_properties",
- "bpy.types.SUNPOS_PT_Panel"),
+ "bpy.types.SUNPOS_PT_Panel",
+ "Add-on Sun Position info: name"),
()),
("fr_FR", "Position du Soleil",
(False, ())),
@@ -117,10 +123,10 @@ translations_tuple = (
("fr_FR", "Préréglages de position du Soleil",
(False, ())),
),
- (("Operator", "Synchroniser Soleil et texture"),
+ (("Operator", "Sync Sun to Texture"),
(("bpy.types.WORLD_OT_sunpos_show_hdr",),
()),
- ("fr_FR", "",
+ ("fr_FR", "Synchroniser Soleil et texture",
(False, ())),
),
(("*", "UTC zone"),
@@ -135,6 +141,13 @@ translations_tuple = (
("fr_FR", "Fuseau horaire : différence avec Greenwich, Angleterre, en heures",
(False, ())),
),
+ (("*", "Bind Texture to Sun"),
+ (("bpy.types.SunPosProperties.bind_to_sun",
+ "scripts/addons/sun_position/ui_sun.py:119"),
+ ()),
+ ("fr_FR", "Lier la texture au Soleil",
+ (False, ())),
+ ),
(("*", "If true, Environment texture moves with sun"),
(("bpy.types.SunPosProperties.bind_to_sun",),
()),
@@ -186,7 +199,6 @@ translations_tuple = (
(("*", "Name of texture to use. World nodes must be enabled and color set to Environment Texture"),
(("bpy.types.SunPosProperties.hdr_texture",),
()),
- # TODO
("fr_FR", "Nom de la texture à utiliser. Les nœuds de shader du monde doivent être activés, et la couleur utiliser une texture d’environnement",
(False, ())),
),
@@ -287,12 +299,6 @@ translations_tuple = (
("fr_FR", "Objet soleil à utiliser dans la scène",
(False, ())),
),
- (("*", "Day Time"),
- (("bpy.types.SunPosProperties.UTC_zone",),
- ()),
- ("fr_FR", "Heure",
- (False, ())),
- ),
(("*", "Time of the day"),
(("bpy.types.SunPosProperties.time",),
()),
@@ -384,7 +390,7 @@ translations_tuple = (
(False, ())),
),
(("*", "Show options or labels:"),
- (("scripts/addons/sun_position/properties.py:241",),
+ (("scripts/addons/sun_position/properties.py:242",),
()),
("fr_FR", "Afficher les options et étiquettes :",
(False, ())),
@@ -414,42 +420,48 @@ translations_tuple = (
(False, ())),
),
(("*", "UTC:"),
- (("scripts/addons/sun_position/ui_sun.py:270",),
+ (("scripts/addons/sun_position/ui_sun.py:272",),
()),
("fr_FR", "UTC : ",
(False, ())),
),
- (("*", "Sunrise:"),
- (("scripts/addons/sun_position/ui_sun.py:285",),
- ()),
- ("fr_FR", "Lever : ",
- (False, ())),
- ),
- (("*", "Sunset:"),
- (("scripts/addons/sun_position/ui_sun.py:288",),
- ()),
- ("fr_FR", "Coucher : ",
- (False, ())),
- ),
(("*", "Please select World in the World panel."),
(("scripts/addons/sun_position/ui_sun.py:95",
"scripts/addons/sun_position/ui_sun.py:153"),
()),
- ("fr_FR", "Veuillez sélecttionner le monde dans le panneau Monde",
+ ("fr_FR", "Veuillez sélectionner le monde dans le panneau Monde",
+ (False, ())),
+ ),
+ (("*", "Release binding"),
+ (("scripts/addons/sun_position/ui_sun.py:116",),
+ ()),
+ ("fr_FR", "Annuler le lien",
(False, ())),
),
(("*", "Azimuth:"),
- (("scripts/addons/sun_position/ui_sun.py:206",),
+ (("scripts/addons/sun_position/ui_sun.py:205",),
()),
("fr_FR", "Azimut :",
(False, ())),
),
(("*", "Elevation:"),
- (("scripts/addons/sun_position/ui_sun.py:209",),
+ (("scripts/addons/sun_position/ui_sun.py:208",),
()),
("fr_FR", "Hauteur :",
(False, ())),
),
+ (("*", "Sunrise:"),
+ (("scripts/addons/sun_position/ui_sun.py:284",),
+ ()),
+ ("fr_FR", "Lever : ",
+ (False, ())),
+ ),
+ (("*", "Sunset:"),
+ (("scripts/addons/sun_position/ui_sun.py:287",),
+ ()),
+ ("fr_FR", "Coucher : ",
+ (False, ())),
+ ),
(("*", "Please activate Use Nodes in the World panel."),
(("scripts/addons/sun_position/ui_sun.py:92",
"scripts/addons/sun_position/ui_sun.py:150"),
@@ -457,6 +469,18 @@ translations_tuple = (
("fr_FR", "Veuillez activer Utiliser nœuds dans le panneau Monde",
(False, ())),
),
+ (("*", "World > Sun Position"),
+ (("Add-on Sun Position info: location",),
+ ()),
+ ("fr_FR", "Monde > Position du Soleil",
+ (False, ())),
+ ),
+ (("*", "Show sun position with objects and/or sky texture"),
+ (("Add-on Sun Position info: description",),
+ ()),
+ ("fr_FR", "Afficher la position du Soleil avec des objets ou une texture de ciel",
+ (False, ())),
+ ),
)
translations_dict = {}
@@ -465,3 +489,5 @@ for msg in translations_tuple:
for lang, trans, (is_fuzzy, comments) in msg[2:]:
if trans and not is_fuzzy:
translations_dict.setdefault(lang, {})[key] = trans
+
+# ##### END AUTOGENERATED I18N SECTION #####
diff --git a/sun_position/ui_sun.py b/sun_position/ui_sun.py
index 05f0dcab..c6eebc33 100644
--- a/sun_position/ui_sun.py
+++ b/sun_position/ui_sun.py
@@ -112,11 +112,11 @@ class SUNPOS_PT_Panel(bpy.types.Panel):
col = flow.column(align=True)
if sp.bind_to_sun:
- prop_text="Release binding"
+ col.prop(sp, "bind_to_sun", toggle=True, icon="CONSTRAINT",
+ text="Release binding")
else:
- prop_text="Bind Texture to Sun "
- col.prop(sp, "bind_to_sun", toggle=True, icon="CONSTRAINT",
- text=prop_text)
+ col.prop(sp, "bind_to_sun", toggle=True, icon="CONSTRAINT",
+ text="Bind Texture to Sun")
row = col.row(align=True)
row.enabled = not sp.bind_to_sun