kerykeion 5.0.0a8__py3-none-any.whl → 5.0.0a9__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.

Potentially problematic release.


This version of kerykeion might be problematic. Click here for more details.

@@ -430,6 +430,21 @@ def draw_first_circle(
430
430
  )
431
431
 
432
432
 
433
+ def draw_background_circle(r: Union[int, float], stroke_color: str, fill_color: str) -> str:
434
+ """
435
+ Draws the background circle.
436
+
437
+ Args:
438
+ - r (Union[int, float]): The value of r.
439
+ - stroke_color (str): The color of the stroke.
440
+ - fill_color (str): The color of the fill.
441
+
442
+ Returns:
443
+ str: The SVG path of the background circle.
444
+ """
445
+ return f'<circle cx="{r}" cy="{r}" r="{r}" style="fill: {fill_color}; stroke: {stroke_color}; stroke-width: 1px;" />'
446
+
447
+
433
448
  def draw_second_circle(
434
449
  r: Union[int, float], stroke_color: str, fill_color: str, chart_type: ChartType, c2: Union[int, float, None] = None
435
450
  ) -> str:
@@ -42,6 +42,7 @@ from kerykeion.charts.charts_utils import (
42
42
  draw_transit_ring_degree_steps,
43
43
  draw_degree_ring,
44
44
  draw_transit_ring,
45
+ draw_background_circle,
45
46
  draw_first_circle,
46
47
  draw_house_comparison_grid,
47
48
  draw_second_circle,
@@ -176,6 +177,7 @@ class KerykeionChartSVG:
176
177
  chart_language: KerykeionChartLanguage
177
178
  active_points: List[AstrologicalPoint]
178
179
  active_aspects: List[ActiveAspect]
180
+ transparent_background: bool
179
181
 
180
182
  # Internal properties
181
183
  fire: float
@@ -210,6 +212,7 @@ class KerykeionChartSVG:
210
212
  active_points: Optional[list[AstrologicalPoint]] = None,
211
213
  active_aspects: list[ActiveAspect]= DEFAULT_ACTIVE_ASPECTS,
212
214
  *,
215
+ transparent_background: bool = False,
213
216
  colors_settings: dict = DEFAULT_CHART_COLORS,
214
217
  celestial_points_settings: list[dict] = DEFAULT_CELESTIAL_POINTS_SETTINGS,
215
218
  aspects_settings: list[dict] = DEFAULT_CHART_ASPECTS_SETTINGS,
@@ -238,6 +241,8 @@ class KerykeionChartSVG:
238
241
  Celestial points to include in the chart visualization.
239
242
  active_aspects (List[ActiveAspect], optional):
240
243
  Aspects to calculate, each defined by name and orb.
244
+ transparent_background (bool, optional):
245
+ Whether to use a transparent background instead of the theme color. Defaults to False.
241
246
  """
242
247
  # --------------------
243
248
  # COMMON INITIALIZATION
@@ -248,6 +253,7 @@ class KerykeionChartSVG:
248
253
  self.active_aspects = active_aspects
249
254
  self.chart_type = chart_type
250
255
  self.double_chart_aspect_grid_type = double_chart_aspect_grid_type
256
+ self.transparent_background = transparent_background
251
257
  self.chart_colors_settings = colors_settings
252
258
  self.planets_settings = celestial_points_settings
253
259
  self.aspects_settings = aspects_settings
@@ -708,6 +714,12 @@ class KerykeionChartSVG:
708
714
  template_dict["paper_color_0"] = self.chart_colors_settings["paper_0"]
709
715
  template_dict["paper_color_1"] = self.chart_colors_settings["paper_1"]
710
716
 
717
+ # Set background color based on transparent_background setting
718
+ if self.transparent_background:
719
+ template_dict["background_color"] = "transparent"
720
+ else:
721
+ template_dict["background_color"] = self.chart_colors_settings["paper_1"]
722
+
711
723
  # Set planet colors
712
724
  for planet in self.planets_settings:
713
725
  planet_id = planet["id"]
@@ -769,6 +781,11 @@ class KerykeionChartSVG:
769
781
  self.first_obj.seventh_house.abs_pos,
770
782
  self.chart_colors_settings["paper_0"],
771
783
  )
784
+ template_dict["background_circle"] = draw_background_circle(
785
+ self.main_radius,
786
+ self.chart_colors_settings["paper_1"],
787
+ self.chart_colors_settings["paper_1"],
788
+ )
772
789
  template_dict["first_circle"] = draw_first_circle(
773
790
  self.main_radius,
774
791
  self.chart_colors_settings["zodiac_radix_ring_2"],
@@ -894,6 +911,11 @@ class KerykeionChartSVG:
894
911
  self.first_obj.seventh_house.abs_pos,
895
912
  self.chart_colors_settings["paper_0"],
896
913
  )
914
+ template_dict["background_circle"] = draw_background_circle(
915
+ self.main_radius,
916
+ self.chart_colors_settings["paper_1"],
917
+ self.chart_colors_settings["paper_1"],
918
+ )
897
919
  template_dict["first_circle"] = draw_first_circle(
898
920
  self.main_radius,
899
921
  self.chart_colors_settings["zodiac_radix_ring_2"],
@@ -1054,6 +1076,11 @@ class KerykeionChartSVG:
1054
1076
  self.chart_colors_settings["zodiac_transit_ring_3"],
1055
1077
  )
1056
1078
  template_dict["degreeRing"] = draw_transit_ring_degree_steps(self.main_radius, self.first_obj.seventh_house.abs_pos)
1079
+ template_dict["background_circle"] = draw_background_circle(
1080
+ self.main_radius,
1081
+ self.chart_colors_settings["paper_1"],
1082
+ self.chart_colors_settings["paper_1"],
1083
+ )
1057
1084
  template_dict["first_circle"] = draw_first_circle(
1058
1085
  self.main_radius,
1059
1086
  self.chart_colors_settings["zodiac_transit_ring_2"],
@@ -1224,6 +1251,11 @@ class KerykeionChartSVG:
1224
1251
  self.chart_colors_settings["zodiac_transit_ring_3"],
1225
1252
  )
1226
1253
  template_dict["degreeRing"] = draw_transit_ring_degree_steps(self.main_radius, self.first_obj.seventh_house.abs_pos)
1254
+ template_dict["background_circle"] = draw_background_circle(
1255
+ self.main_radius,
1256
+ self.chart_colors_settings["paper_1"],
1257
+ self.chart_colors_settings["paper_1"],
1258
+ )
1227
1259
  template_dict["first_circle"] = draw_first_circle(
1228
1260
  self.main_radius,
1229
1261
  self.chart_colors_settings["zodiac_transit_ring_2"],
@@ -1365,6 +1397,11 @@ class KerykeionChartSVG:
1365
1397
  self.chart_colors_settings["zodiac_transit_ring_3"],
1366
1398
  )
1367
1399
  template_dict["degreeRing"] = draw_transit_ring_degree_steps(self.main_radius, self.first_obj.seventh_house.abs_pos)
1400
+ template_dict["background_circle"] = draw_background_circle(
1401
+ self.main_radius,
1402
+ self.chart_colors_settings["paper_1"],
1403
+ self.chart_colors_settings["paper_1"],
1404
+ )
1368
1405
  template_dict["first_circle"] = draw_first_circle(
1369
1406
  self.main_radius,
1370
1407
  self.chart_colors_settings["zodiac_transit_ring_2"],
@@ -1547,6 +1584,11 @@ class KerykeionChartSVG:
1547
1584
  self.first_obj.seventh_house.abs_pos,
1548
1585
  self.chart_colors_settings["paper_0"],
1549
1586
  )
1587
+ template_dict["background_circle"] = draw_background_circle(
1588
+ self.main_radius,
1589
+ self.chart_colors_settings["paper_1"],
1590
+ self.chart_colors_settings["paper_1"],
1591
+ )
1550
1592
  template_dict["first_circle"] = draw_first_circle(
1551
1593
  self.main_radius,
1552
1594
  self.chart_colors_settings["zodiac_radix_ring_2"],
@@ -7,7 +7,7 @@
7
7
  height="100%"
8
8
  viewBox="28 20 255 250"
9
9
  preserveAspectRatio="xMidYMid"
10
- style="background-color: $paper_color_1"
10
+ style="background-color: $background_color"
11
11
  >
12
12
 
13
13
  <!-- Colors -->
@@ -7,7 +7,7 @@
7
7
  height="100%"
8
8
  viewBox="$viewbox"
9
9
  preserveAspectRatio="xMidYMid"
10
- style="background-color: $paper_color_1"
10
+ style="background-color: $background_color"
11
11
  >
12
12
  <title>$stringTitle</title>
13
13
 
@@ -60,6 +60,12 @@
60
60
 
61
61
  <!-- Full Wheel -->
62
62
  <g kr:node="Full_Wheel" transform="translate(100,50)">
63
+
64
+ <!-- Background Circle -->
65
+ <g kr:node='Background_Circle'>
66
+ $background_circle
67
+ </g>
68
+
63
69
  <!-- Zodiac -->
64
70
  <g kr:node="Zodiac">
65
71
  $makeZodiac
@@ -5,9 +5,9 @@
5
5
  xmlns:kr="https://www.kerykeion.net/"
6
6
  width="100%"
7
7
  height="100%"
8
- viewBox="40 40 500 500"
8
+ viewBox="85 40 500 500"
9
9
  preserveAspectRatio="xMidYMid"
10
- style="background-color: $paper_color_1"
10
+ style="background-color: $background_color"
11
11
  >
12
12
  <title>$stringTitle | Kerykeion</title>
13
13
 
@@ -21,6 +21,12 @@
21
21
 
22
22
  <!-- Full Wheel -->
23
23
  <g kr:node="Full_Wheel" transform="translate(100,50)">
24
+
25
+ <!-- Background Circle -->
26
+ <g kr:node='Background_Circle'>
27
+ $background_circle
28
+ </g>
29
+
24
30
  <!-- Zodiac -->
25
31
  <g kr:node="Zodiac">
26
32
  $makeZodiac
@@ -4,6 +4,7 @@ from typing_extensions import TypedDict
4
4
  class ChartTemplateDictionary(TypedDict):
5
5
  transitRing: str
6
6
  degreeRing: str
7
+ background_circle: str
7
8
  first_circle: str
8
9
  second_circle: str
9
10
  third_circle: str
@@ -31,6 +32,8 @@ class ChartTemplateDictionary(TypedDict):
31
32
  paper_color_0: str
32
33
  # Background color of the chart
33
34
  paper_color_1: str
35
+ # Dynamic background color (can be transparent or theme color)
36
+ background_color: str
34
37
 
35
38
  # Planets colors, from 0 to 16 (0 is the Sun)
36
39
  planets_color_0: str
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: kerykeion
3
- Version: 5.0.0a8
3
+ Version: 5.0.0a9
4
4
  Summary: A python library for astrology.
5
5
  Project-URL: Homepage, https://www.kerykeion.net/
6
6
  Project-URL: Repository, https://github.com/g-battaglia/kerykeion
@@ -15,14 +15,14 @@ kerykeion/aspects/natal_aspects.py,sha256=SfI3ferjtyV47fBG6q3q1aczc-GFOwN4P7WpyZ
15
15
  kerykeion/aspects/synastry_aspects.py,sha256=4ZBiFrbyyXxclnyaEIBeLJQO3uQVnpsqvI5Kj3-ijuI,5979
16
16
  kerykeion/aspects/transits_time_range.py,sha256=E03BJYcNK3kO30EC96Ys2EaH-EDyZF2nj4C7_LcFrOk,1182
17
17
  kerykeion/charts/__init__.py,sha256=i9NMZ7LdkllPlqQSi1or9gTobHbROGDKmJhBDO4R0mA,128
18
- kerykeion/charts/charts_utils.py,sha256=GCC20W4qHQXXKdUMlt72THHJxqp6ytj4X61oLONMSt4,62450
18
+ kerykeion/charts/charts_utils.py,sha256=mzYO_MYht9Gur8hMm2TbIZ1NfvNdl3FsBy4fl1qPOek,62948
19
19
  kerykeion/charts/draw_planets.py,sha256=dbVCA4MFs7ChZKH4w1eErBiF_mluuxAD4fouBrXs-x0,17696
20
20
  kerykeion/charts/draw_planets_v2.py,sha256=ft0KjngCIfYKNGlZ4cv7apX9V6uyHetIVOxbNRzEmWU,28210
21
21
  kerykeion/charts/draw_planets_v3.py,sha256=3nrpef56qBsc0hfCOGdfCOr-61C2c5aWcRSiBcQiAuo,25811
22
- kerykeion/charts/kerykeion_chart_svg.py,sha256=2Xhe2XvZLdoAIRxYh1MYceencbYJKxWXRoZZ30Kgra4,95638
23
- kerykeion/charts/templates/aspect_grid_only.xml,sha256=goTM5zXKZMZCZPxsJAk80PQvQCgo2QccJLyH4HHpguo,70052
24
- kerykeion/charts/templates/chart.xml,sha256=ZNfA19u1objUui1vCGJTvvwdE_Sg9R9O3LNdcNHEuaI,79800
25
- kerykeion/charts/templates/wheel_only.xml,sha256=zR2EJBy6Io69enkuRfHWZxYdyeQsXGpl9_BkY2f4L2c,71248
22
+ kerykeion/charts/kerykeion_chart_svg.py,sha256=VHrTJZY8ETAiWPnhjCKGtRmhoa4f6-M5vLBgI14Jx20,97622
23
+ kerykeion/charts/templates/aspect_grid_only.xml,sha256=lBHBj5bS5klGnv7QMuFxQjhlE6VZRaOgW93akLgRjX4,70055
24
+ kerykeion/charts/templates/chart.xml,sha256=r3a_csMqcoqeOnDA3YCD-iUxdqgRw5GV1GOf1Cp0e_E,79940
25
+ kerykeion/charts/templates/wheel_only.xml,sha256=0P8kpdsmKdFFso892v5r5WTp4GZSZApgh4mj4BTDNkg,71388
26
26
  kerykeion/charts/themes/classic.css,sha256=LYYYWQHNG7-vuPCq8F2EPl3LauWXVrY3Q_tpwM0klgo,4660
27
27
  kerykeion/charts/themes/dark-high-contrast.css,sha256=YW5X5-M0dz5Vy2oz-JyDNXJYHSmV83lYCodydC-KS1A,7506
28
28
  kerykeion/charts/themes/dark.css,sha256=XVspznDRNMXsFzk7hY7IB7AI58alPAV_-CgV3gCKyzg,7581
@@ -33,7 +33,7 @@ kerykeion/house_comparison/house_comparison_factory.py,sha256=R3O3R786yH6W2c8cKm
33
33
  kerykeion/house_comparison/house_comparison_models.py,sha256=R9EW5F3fiIKIm8qrwTxtXhNOGDpf1-Lh9hbM1uK83oE,1549
34
34
  kerykeion/house_comparison/house_comparison_utils.py,sha256=BXDXmxeLSwEDbum-APNzdwK3FjweCEaoY_Z3V1kGMIk,3851
35
35
  kerykeion/kr_types/__init__.py,sha256=jshJOccCQcYZuoOvrILRZH6imy4RBvKpFPujlNLFyGE,295
36
- kerykeion/kr_types/chart_types.py,sha256=ou9mIMNrQ7vlgWW4e209z_wMa2XZa4OGvHBr-CGk_rs,2309
36
+ kerykeion/kr_types/chart_types.py,sha256=ofMYk7NRalSsdQcLVkpCbOb-dhdjYHEqIb_WPLtD0rM,2429
37
37
  kerykeion/kr_types/kerykeion_exception.py,sha256=kE1y0K0rmuz32b4K_ZppSsZ59I2Get0ZkvOkTE5HejI,314
38
38
  kerykeion/kr_types/kr_literals.py,sha256=4kJhzm_0LERiJEJks0KgDyThueMZj_F1OK2Far5SMZc,4870
39
39
  kerykeion/kr_types/kr_models.py,sha256=nzq8no2dBd4b529ybznF46_VUEvDj5ZdDdlLRBE0RmM,8835
@@ -48,8 +48,8 @@ kerykeion/settings/legacy/legacy_chart_aspects_settings.py,sha256=tO4tgPgPP07_wu
48
48
  kerykeion/settings/legacy/legacy_color_settings.py,sha256=gBUmGSNvvLzRYbdVtzwTDnMwWoh4tOCyT_9Q6aQRv_s,2620
49
49
  kerykeion/sweph/README.md,sha256=L7FtNAJTWtrZNGKa8MX87SjduFYPYxwWhaI5fmtzNZo,73
50
50
  kerykeion/sweph/seas_18.se1,sha256=X9nCqhZU43wJpq61WAdueVQJt9xL2UjrwPqn1Kdoa1s,223002
51
- kerykeion-5.0.0a8.dist-info/METADATA,sha256=XRm8bm5JWbAt-t0A4LUUOedawGjeACYyYBQQ_oGqLlc,25100
52
- kerykeion-5.0.0a8.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
53
- kerykeion-5.0.0a8.dist-info/entry_points.txt,sha256=j9J6dg4czXFgM3LDOxoWFl8UDU4LLe2bD_U0RgpyLGA,50
54
- kerykeion-5.0.0a8.dist-info/licenses/LICENSE,sha256=UTLH8EdbAsgQei4PA2PnBCPGLSZkq5J-dhkyJuXgWQU,34273
55
- kerykeion-5.0.0a8.dist-info/RECORD,,
51
+ kerykeion-5.0.0a9.dist-info/METADATA,sha256=qRC5Lxj1uBxV_AAf3lb0VWXmqT3jmZzo1nD9FaJrOdM,25100
52
+ kerykeion-5.0.0a9.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
53
+ kerykeion-5.0.0a9.dist-info/entry_points.txt,sha256=j9J6dg4czXFgM3LDOxoWFl8UDU4LLe2bD_U0RgpyLGA,50
54
+ kerykeion-5.0.0a9.dist-info/licenses/LICENSE,sha256=UTLH8EdbAsgQei4PA2PnBCPGLSZkq5J-dhkyJuXgWQU,34273
55
+ kerykeion-5.0.0a9.dist-info/RECORD,,