xython 4.0.1__tar.gz → 4.0.5__tar.gz
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.
- {xython-4.0.1 → xython-4.0.5}/MANIFEST.in +9 -10
- {xython-4.0.1/src/xython.egg-info → xython-4.0.5}/PKG-INFO +3 -3
- {xython-4.0.1 → xython-4.0.5}/setup.py +3 -3
- {xython-4.0.1 → xython-4.0.5}/src/xython/__init__.py +1 -1
- xython-4.0.1/src/xython/pyclick.py → xython-4.0.5/src/xython/xy_auto.py +6 -6
- xython-4.0.1/src/xython/scolor.py → xython-4.0.5/src/xython/xy_color.py +83 -83
- xython-4.0.1/src/xython/basic_data.py → xython-4.0.5/src/xython/xy_common.py +229 -229
- xython-4.0.1/src/xython/basic_data_for_han.py → xython-4.0.5/src/xython/xy_common_hwp.py +9 -9
- xython-4.0.1/src/xython/basic_data_for_xymap.py → xython-4.0.5/src/xython/xy_common_map.py +2 -2
- xython-4.0.1/src/xython/anydb.py → xython-4.0.5/src/xython/xy_db.py +10 -10
- xython-4.0.1/src/xython/pcell.py → xython-4.0.5/src/xython/xy_excel.py +218 -218
- xython-4.0.1/src/xython/han.py → xython-4.0.5/src/xython/xy_hwp.py +45 -45
- xython-4.0.1/src/xython/xylist.py → xython-4.0.5/src/xython/xy_list.py +47 -50
- xython-4.0.1/src/xython/xymap.py → xython-4.0.5/src/xython/xy_map.py +48 -49
- xython-4.0.1/src/xython/mailmail.py → xython-4.0.5/src/xython/xy_outlook.py +70 -31
- xython-4.0.1/src/xython/jfinder.py → xython-4.0.5/src/xython/xy_re.py +2 -2
- xython-4.0.1/src/xython/pynal.py → xython-4.0.5/src/xython/xy_time.py +19 -19
- xython-4.0.1/src/xython/youtil.py → xython-4.0.5/src/xython/xy_util.py +38 -37
- xython-4.0.1/src/xython/xyweb.py → xython-4.0.5/src/xython/xy_web.py +12 -12
- xython-4.0.1/src/xython/ganada.py → xython-4.0.5/src/xython/xy_word.py +226 -226
- {xython-4.0.1 → xython-4.0.5/src/xython.egg-info}/PKG-INFO +3 -3
- xython-4.0.5/src/xython.egg-info/SOURCES.txt +30 -0
- xython-4.0.1/src/xython.egg-info/SOURCES.txt +0 -30
- {xython-4.0.1 → xython-4.0.5}/README.md +0 -0
- {xython-4.0.1 → xython-4.0.5}/requirements.txt +0 -0
- {xython-4.0.1 → xython-4.0.5}/setup.cfg +0 -0
- /xython-4.0.1/src/xython/pcell_event.py → /xython-4.0.5/src/xython/xy_excel_event.py +0 -0
- /xython-4.0.1/src/xython/mygrid.py → /xython-4.0.5/src/xython/xy_grid.py +0 -0
- {xython-4.0.1 → xython-4.0.5}/src/xython.egg-info/dependency_links.txt +0 -0
- {xython-4.0.1 → xython-4.0.5}/src/xython.egg-info/not-zip-safe +0 -0
- {xython-4.0.1 → xython-4.0.5}/src/xython.egg-info/requires.txt +0 -0
- {xython-4.0.1 → xython-4.0.5}/src/xython.egg-info/top_level.txt +0 -0
|
@@ -2,22 +2,21 @@ include LICENSE
|
|
|
2
2
|
include README.md
|
|
3
3
|
include requirements.txt
|
|
4
4
|
|
|
5
|
-
include src/xython/
|
|
5
|
+
include src/xython/xy_auto.py
|
|
6
|
+
include src/xython/xy_color.py
|
|
6
7
|
include src/xython/xy_common.py
|
|
7
8
|
include src/xython/xy_common_hwp.py
|
|
8
9
|
include src/xython/xy_common_map.py
|
|
9
|
-
include src/xython/
|
|
10
|
-
include src/xython/xy_hwp.py
|
|
11
|
-
include src/xython/xy_re.py
|
|
12
|
-
include src/xython/xy_outlook.py
|
|
13
|
-
include src/xython/xy_grid.py
|
|
10
|
+
include src/xython/xy_db.py
|
|
14
11
|
include src/xython/xy_excel.py
|
|
15
12
|
include src/xython/xy_excel_event.py
|
|
16
|
-
include src/xython/
|
|
17
|
-
include src/xython/
|
|
18
|
-
include src/xython/xy_color.py
|
|
13
|
+
include src/xython/xy_grid.py
|
|
14
|
+
include src/xython/xy_hwp.py
|
|
19
15
|
include src/xython/xy_list.py
|
|
20
16
|
include src/xython/xy_map.py
|
|
21
|
-
include src/xython/
|
|
17
|
+
include src/xython/xy_outlook.py
|
|
18
|
+
include src/xython/xy_re.py
|
|
19
|
+
include src/xython/xy_time.py
|
|
22
20
|
include src/xython/xy_util.py
|
|
21
|
+
include src/xython/xy_word.py
|
|
23
22
|
include images/*
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: xython
|
|
3
|
-
Version: 4.0.
|
|
3
|
+
Version: 4.0.5
|
|
4
4
|
Summary: win32com + python + Office Automation = xython, (for easy automation for excel, word, outlook, regex, color, hwp, etc BY python & win32com)
|
|
5
5
|
Home-page: https://www.xython.co.kr
|
|
6
|
-
Author:
|
|
6
|
+
Author: s.j.park
|
|
7
7
|
Author-email: sjpkorea@naver.com
|
|
8
8
|
License: UNKNOWN
|
|
9
|
-
Download-URL: https://github.com/sjpark/xython/archive/v4.0.
|
|
9
|
+
Download-URL: https://github.com/sjpark/xython/archive/v4.0.5.tar.gz
|
|
10
10
|
Project-URL: Documentation, https://sjpkorea.github.io/xython.github.io/
|
|
11
11
|
Project-URL: Link 1, https://www.xython.co.kr
|
|
12
12
|
Platform: UNKNOWN
|
|
@@ -5,7 +5,7 @@ from setuptools import setup, find_packages
|
|
|
5
5
|
# long_description = fh.read()
|
|
6
6
|
setup(
|
|
7
7
|
name='xython',
|
|
8
|
-
version='4.0.
|
|
8
|
+
version='4.0.5',
|
|
9
9
|
url='https://www.xython.co.kr',
|
|
10
10
|
install_requires=['pandas',
|
|
11
11
|
'Pillow',
|
|
@@ -24,8 +24,8 @@ setup(
|
|
|
24
24
|
'selenium',
|
|
25
25
|
'pytest-shutil',
|
|
26
26
|
],
|
|
27
|
-
download_url='https://github.com/sjpark/xython/archive/v4.0.
|
|
28
|
-
author='
|
|
27
|
+
download_url='https://github.com/sjpark/xython/archive/v4.0.5.tar.gz',
|
|
28
|
+
author='s.j.park',
|
|
29
29
|
author_email='sjpkorea@naver.com',
|
|
30
30
|
description="win32com + python + Office Automation = xython, (for easy automation for excel, word, outlook, regex, color, hwp, etc BY python & win32com)",
|
|
31
31
|
packages=find_packages("src"),
|
|
@@ -11,7 +11,7 @@ import pygetwindow as gw
|
|
|
11
11
|
import paho.mqtt.client as mqtt
|
|
12
12
|
import psutil
|
|
13
13
|
import ctypes
|
|
14
|
-
import
|
|
14
|
+
import xy_common
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
# WinAPI 함수 정의
|
|
@@ -21,7 +21,7 @@ from unittest.mock import patch
|
|
|
21
21
|
with patch("ctypes.windll.user32.SetProcessDPIAware", autospec=True):
|
|
22
22
|
import pyautogui
|
|
23
23
|
|
|
24
|
-
class
|
|
24
|
+
class xy_auto:
|
|
25
25
|
"""
|
|
26
26
|
여러가지 사무용에 사용할 만한 메소드들을 만들어 놓은것이며,
|
|
27
27
|
좀더 특이한 것은 youtil2로 만들어서 사용할 예정입니다
|
|
@@ -30,7 +30,7 @@ class pyclick:
|
|
|
30
30
|
"""
|
|
31
31
|
|
|
32
32
|
def __init__(self):
|
|
33
|
-
self.
|
|
33
|
+
self.xvar = xy_common.xy_common().xvar
|
|
34
34
|
|
|
35
35
|
def all_infomation_for_handle_no(self, handle_no):
|
|
36
36
|
"""
|
|
@@ -93,7 +93,7 @@ class pyclick:
|
|
|
93
93
|
:return:
|
|
94
94
|
"""
|
|
95
95
|
input_value = str(input_value).lower()
|
|
96
|
-
if input_value in self.
|
|
96
|
+
if input_value in self.xvar["keyboard_action_list_all"]:
|
|
97
97
|
result = input_value
|
|
98
98
|
else:
|
|
99
99
|
result = ""
|
|
@@ -162,7 +162,7 @@ class pyclick:
|
|
|
162
162
|
키보드 액션의 종류들
|
|
163
163
|
:return:
|
|
164
164
|
"""
|
|
165
|
-
result = self.
|
|
165
|
+
result = self.xvar["keyboard_action_list_short"]
|
|
166
166
|
return result
|
|
167
167
|
|
|
168
168
|
def data_for_keyboard_action_list(self):
|
|
@@ -170,7 +170,7 @@ class pyclick:
|
|
|
170
170
|
키보드 액션의 종류들
|
|
171
171
|
:return:
|
|
172
172
|
"""
|
|
173
|
-
result = self.
|
|
173
|
+
result = self.xvar["keyboard_action_list_all"]
|
|
174
174
|
return result
|
|
175
175
|
|
|
176
176
|
def dclick_mouse(self):
|
|
@@ -5,9 +5,9 @@ from unittest.mock import patch
|
|
|
5
5
|
with patch("ctypes.windll.user32.SetProcessDPIAware", autospec=True):
|
|
6
6
|
import pyautogui
|
|
7
7
|
|
|
8
|
-
import
|
|
8
|
+
import xy_re, xy_common # xython 모듈
|
|
9
9
|
|
|
10
|
-
class
|
|
10
|
+
class xy_color:
|
|
11
11
|
"""
|
|
12
12
|
색을 편하게 사용하기위해 만든 모듈
|
|
13
13
|
기본값의 형태 : rgb
|
|
@@ -16,11 +16,11 @@ class scolor:
|
|
|
16
16
|
|
|
17
17
|
def __init__(self):
|
|
18
18
|
"""
|
|
19
|
-
self.
|
|
19
|
+
self.xvar : package안에서 공통적으로 사용되는 변수들
|
|
20
20
|
"""
|
|
21
21
|
|
|
22
|
-
self.xre =
|
|
23
|
-
self.
|
|
22
|
+
self.xre = xy_re.xy_re()
|
|
23
|
+
self.xvar = xy_common.xy_common().xvar
|
|
24
24
|
self.s_step = 5 # +, -의 각 1개에 hs1에서 s의 값의 변화
|
|
25
25
|
|
|
26
26
|
def _change_scolor_to_hsl(self, input_scolor):
|
|
@@ -35,9 +35,9 @@ class scolor:
|
|
|
35
35
|
hsl_list = None
|
|
36
36
|
|
|
37
37
|
if input_l1d[0]: # 정수, 12가지 기본색
|
|
38
|
-
hsl_list = self.
|
|
38
|
+
hsl_list = self.xvar["list_basic_12hsl"][input_l1d[0]]
|
|
39
39
|
elif input_l1d[1]: # 색이름
|
|
40
|
-
hsl_list = self.
|
|
40
|
+
hsl_list = self.xvar["color_name_eng_vs_hsl_no"][input_l1d[1]]
|
|
41
41
|
if input_l1d[2]: # 명도
|
|
42
42
|
hsl_list[2] = input_l1d[2]
|
|
43
43
|
if input_l1d[3]: # 채도 +
|
|
@@ -92,7 +92,7 @@ class scolor:
|
|
|
92
92
|
# 영어나 한글로 된 색깔이름을 추출
|
|
93
93
|
re_com1 = re.compile("[a-zA-Z_가-힣]+")
|
|
94
94
|
color_name = re_com1.findall(input_scolor)
|
|
95
|
-
checked_color_name = self.
|
|
95
|
+
checked_color_name = self.xvar["check_color_name"][color_name[0]]
|
|
96
96
|
result[1] = checked_color_name
|
|
97
97
|
|
|
98
98
|
# scolor에서 + 추출
|
|
@@ -130,7 +130,7 @@ class scolor:
|
|
|
130
130
|
:param input_56color_no:
|
|
131
131
|
:return:
|
|
132
132
|
"""
|
|
133
|
-
result = self.
|
|
133
|
+
result = self.xvar["56color_vs_color_kor"][int(input_56color_no)]
|
|
134
134
|
return result
|
|
135
135
|
|
|
136
136
|
def change_56color_to_color_kor(self, input_56color):
|
|
@@ -140,7 +140,7 @@ class scolor:
|
|
|
140
140
|
:param input_56color:
|
|
141
141
|
:return:
|
|
142
142
|
"""
|
|
143
|
-
result = self.
|
|
143
|
+
result = self.xvar["56color_vs_color_kor"][int(input_56color)]
|
|
144
144
|
return result
|
|
145
145
|
|
|
146
146
|
def change_56color_to_color_name(self, input_56color):
|
|
@@ -159,7 +159,7 @@ class scolor:
|
|
|
159
159
|
:param input_56color:
|
|
160
160
|
:return:
|
|
161
161
|
"""
|
|
162
|
-
result = self.
|
|
162
|
+
result = self.xvar["rgb56_for_excel"][int(i_no)]
|
|
163
163
|
return result
|
|
164
164
|
|
|
165
165
|
def change_any_color_to_hsl(self, input_color):
|
|
@@ -444,10 +444,10 @@ class scolor:
|
|
|
444
444
|
:return:
|
|
445
445
|
"""
|
|
446
446
|
|
|
447
|
-
checked_color_style = self.
|
|
447
|
+
checked_color_style = self.xvar["check_color_tone"][color_style]
|
|
448
448
|
|
|
449
|
-
step_2 = self.
|
|
450
|
-
step_1 = self.
|
|
449
|
+
step_2 = self.xvar["basic_15tone_eng_vs_sl"][checked_color_style]
|
|
450
|
+
step_1 = self.xvar["sl_10_by_작은step"][style_step]
|
|
451
451
|
h = int(input_hsl[0])
|
|
452
452
|
s = int(step_1[0]) + int(step_2[0])
|
|
453
453
|
l = int(step_1[1]) + int(step_2[1])
|
|
@@ -495,7 +495,7 @@ class scolor:
|
|
|
495
495
|
:param step_no:
|
|
496
496
|
:return:
|
|
497
497
|
"""
|
|
498
|
-
s, l = self.
|
|
498
|
+
s, l = self.xvar["색강도_vs_sl"][step_no]
|
|
499
499
|
result = [input_hsl[0], input_hsl[1] + s, input_hsl[2] + l]
|
|
500
500
|
|
|
501
501
|
def change_hsl_for_sl_by_plusminus100(self, input_hsl, s_step="++", l_step="++"):
|
|
@@ -1125,9 +1125,9 @@ class scolor:
|
|
|
1125
1125
|
:return:
|
|
1126
1126
|
"""
|
|
1127
1127
|
|
|
1128
|
-
color_style_checked = self.
|
|
1129
|
-
step_2 = self.
|
|
1130
|
-
step_1 = self.
|
|
1128
|
+
color_style_checked = self.xvar["check_color_tone"][color_style]
|
|
1129
|
+
step_2 = self.xvar["basic_15tone_eng_vs_sl"][color_style_checked] # 스타일을 적용하는것
|
|
1130
|
+
step_1 = self.xvar["sl_10_by_작은step"][style_step] # 스타일을 얼마나 강하게 적용할것인가를 나타내는것
|
|
1131
1131
|
|
|
1132
1132
|
h = int(input_hsl[0])
|
|
1133
1133
|
s = int(step_1[0]) + int(step_2[0])
|
|
@@ -1178,9 +1178,9 @@ class scolor:
|
|
|
1178
1178
|
:return:
|
|
1179
1179
|
"""
|
|
1180
1180
|
|
|
1181
|
-
color_style_checked = self.
|
|
1182
|
-
step_2 = self.
|
|
1183
|
-
step_1 = self.
|
|
1181
|
+
color_style_checked = self.xvar["check_color_tone"][color_style]
|
|
1182
|
+
step_2 = self.xvar["basic_15tone_eng_vs_sl"][color_style_checked] # 스타일을 적용하는것
|
|
1183
|
+
step_1 = self.xvar["sl_10_by_작은step"][style_step] # 스타일을 얼마나 강하게 적용할것인가를 나타내는것
|
|
1184
1184
|
|
|
1185
1185
|
h = int(input_hsl[0])
|
|
1186
1186
|
s = int(step_1[0]) + int(step_2[0])
|
|
@@ -1343,7 +1343,7 @@ class scolor:
|
|
|
1343
1343
|
"""
|
|
1344
1344
|
result = []
|
|
1345
1345
|
h, s, l = self.change_rgb_to_hsl(input_rgb)
|
|
1346
|
-
result4 = self.
|
|
1346
|
+
result4 = self.xvar["basic_12color_hsl"]
|
|
1347
1347
|
for one in result4:
|
|
1348
1348
|
result.append([h, one[0], one[1]])
|
|
1349
1349
|
return result
|
|
@@ -1362,7 +1362,7 @@ class scolor:
|
|
|
1362
1362
|
"""
|
|
1363
1363
|
result = []
|
|
1364
1364
|
h, s, l = self.change_rgb_to_hsl(input_rgb)
|
|
1365
|
-
result4 = self.
|
|
1365
|
+
result4 = self.xvar["basic_12color_hsl"]
|
|
1366
1366
|
for one in result4:
|
|
1367
1367
|
result.append([h, one[0], one[1]])
|
|
1368
1368
|
return result
|
|
@@ -1376,7 +1376,7 @@ class scolor:
|
|
|
1376
1376
|
"""
|
|
1377
1377
|
result = 0
|
|
1378
1378
|
max_rgbint = 255 * 255 * 255
|
|
1379
|
-
var_56_rgb = self.
|
|
1379
|
+
var_56_rgb = self.xvar["56color_vs_rgb"]
|
|
1380
1380
|
|
|
1381
1381
|
for excel_color_no in var_56_rgb.keys():
|
|
1382
1382
|
excel_rgb = var_56_rgb[excel_color_no]
|
|
@@ -1395,7 +1395,7 @@ class scolor:
|
|
|
1395
1395
|
"""
|
|
1396
1396
|
result = 0
|
|
1397
1397
|
max_rgbint = 255 * 255 * 255
|
|
1398
|
-
var_56_rgb = self.
|
|
1398
|
+
var_56_rgb = self.xvar["56color_vs_rgb"]
|
|
1399
1399
|
|
|
1400
1400
|
for excel_color_no in var_56_rgb.keys():
|
|
1401
1401
|
excel_rgb = var_56_rgb[excel_color_no]
|
|
@@ -1414,7 +1414,7 @@ class scolor:
|
|
|
1414
1414
|
"""
|
|
1415
1415
|
result = 0
|
|
1416
1416
|
max_rgbint = 255 * 255 * 255
|
|
1417
|
-
var_56_rgb = self.
|
|
1417
|
+
var_56_rgb = self.xvar["highlight_vs_rgb"]
|
|
1418
1418
|
|
|
1419
1419
|
for excel_color_no in var_56_rgb.keys():
|
|
1420
1420
|
excel_rgb = var_56_rgb[excel_color_no]
|
|
@@ -1578,7 +1578,7 @@ class scolor:
|
|
|
1578
1578
|
level1to3 : 1~3 사이의 값
|
|
1579
1579
|
|
|
1580
1580
|
pastel_style : ["연한", "밝은회색", "회색", "어두운회색", "옅은", "부드러운", "탁한", "어두운", "밝은", "강한", "짙은", "선명한"]
|
|
1581
|
-
basic_data의 self.
|
|
1581
|
+
basic_data의 self.xvar["check_color_tone"] 를 이용해서 pastel_style의 공식적인 이름을 찾읍니다
|
|
1582
1582
|
pastel의 0에서 100 : 중간값(sl) [100, 85]
|
|
1583
1583
|
|
|
1584
1584
|
:return:
|
|
@@ -1707,7 +1707,7 @@ class scolor:
|
|
|
1707
1707
|
[value_only, color_name, basic_l_value] = self.check_input_scolor(input_scolor)
|
|
1708
1708
|
|
|
1709
1709
|
if value_only:
|
|
1710
|
-
h_value, s_value, l_value = self.
|
|
1710
|
+
h_value, s_value, l_value = self.xvar["basic_18color_hsl"][int(value_only)]
|
|
1711
1711
|
|
|
1712
1712
|
elif color_name in ["whi", "bla", "gra"]: # 색이 흰색, 검정, 회색일 경우는 h,s는 0으로 한다
|
|
1713
1713
|
h_value = 0
|
|
@@ -1728,7 +1728,7 @@ class scolor:
|
|
|
1728
1728
|
l_value = 100
|
|
1729
1729
|
|
|
1730
1730
|
elif color_name:
|
|
1731
|
-
h_value, s_value, l_value = self.
|
|
1731
|
+
h_value, s_value, l_value = self.xvar["basic_20color_name_eng_vs_hsl"][color_name]
|
|
1732
1732
|
l_value = basic_l_value
|
|
1733
1733
|
|
|
1734
1734
|
if int(l_value) > 100: l_value = 100
|
|
@@ -1790,10 +1790,10 @@ class scolor:
|
|
|
1790
1790
|
:param style_step: 변화정도는 5를 기준으로 1~9까지임
|
|
1791
1791
|
"""
|
|
1792
1792
|
basic_hsl = self._change_scolor_to_hsl(input_scolor)
|
|
1793
|
-
checked_color_style = self.
|
|
1793
|
+
checked_color_style = self.xvar["check_color_tone"][color_style]
|
|
1794
1794
|
|
|
1795
|
-
step_2 = self.
|
|
1796
|
-
step_1 = self.
|
|
1795
|
+
step_2 = self.xvar["basic_15tone_eng_vs_sl"][checked_color_style]
|
|
1796
|
+
step_1 = self.xvar["sl_10_by_작은step"][style_step]
|
|
1797
1797
|
|
|
1798
1798
|
h = int(basic_hsl[0])
|
|
1799
1799
|
s = int(basic_hsl[1]) + int(step_1[0]) + int(step_2[0])
|
|
@@ -1814,10 +1814,10 @@ class scolor:
|
|
|
1814
1814
|
:param style_step: 변화정도는 5를 기준으로 1~9까지임
|
|
1815
1815
|
"""
|
|
1816
1816
|
basic_hsl = self.change_scolor_to_hsl(input_scolor)
|
|
1817
|
-
checked_color_style = self.
|
|
1817
|
+
checked_color_style = self.xvar["check_color_tone"][color_style]
|
|
1818
1818
|
|
|
1819
|
-
step_2 = self.
|
|
1820
|
-
step_1 = self.
|
|
1819
|
+
step_2 = self.xvar["basic_15tone_eng_vs_sl"][checked_color_style]
|
|
1820
|
+
step_1 = self.xvar["sl_10_by_작은step"][style_step]
|
|
1821
1821
|
|
|
1822
1822
|
h = int(basic_hsl[0])
|
|
1823
1823
|
s = int(basic_hsl[1]) + int(step_1[0]) + int(step_2[0])
|
|
@@ -1836,10 +1836,10 @@ class scolor:
|
|
|
1836
1836
|
# 넘어온 자료중 color값을 hsl로 변경한다
|
|
1837
1837
|
basic_hsl = self.change_scolor_to_hsl(input_scolor)
|
|
1838
1838
|
# 스타일을 적용하는것
|
|
1839
|
-
aaa = self.
|
|
1840
|
-
step_2 = self.
|
|
1839
|
+
aaa = self.xvar["color_tone_12_names_vs_no"][color_style]
|
|
1840
|
+
step_2 = self.xvar["sl_small_step_vs_sl_no"][aaa]
|
|
1841
1841
|
# 스타일을 얼마나 강하게 적용할것인가를 나타내는것
|
|
1842
|
-
step_1 = self.
|
|
1842
|
+
step_1 = self.xvar["basic_9color_sl_big_step"][str(style_step)]
|
|
1843
1843
|
|
|
1844
1844
|
h = int(basic_hsl[0])
|
|
1845
1845
|
s = int(basic_hsl[1]) + int(step_1[0]) + int(step_2[0])
|
|
@@ -1884,12 +1884,12 @@ class scolor:
|
|
|
1884
1884
|
:return:
|
|
1885
1885
|
"""
|
|
1886
1886
|
hsl = self.change_scolor_to_hsl(input_scolor)
|
|
1887
|
-
plusminus100 = self.
|
|
1887
|
+
plusminus100 = self.xvar["check_color_step"][style_name]
|
|
1888
1888
|
result = self.change_hsl_to_rgb_by_plusminus100(hsl, plusminus100)
|
|
1889
1889
|
return result
|
|
1890
1890
|
|
|
1891
1891
|
def check_color_name(self, input_value):
|
|
1892
|
-
result = self.
|
|
1892
|
+
result = self.xvar["check_color_name"][input_value]
|
|
1893
1893
|
return result
|
|
1894
1894
|
|
|
1895
1895
|
def check_color_name_by_rgbint(self, rgbint):
|
|
@@ -1987,8 +1987,8 @@ class scolor:
|
|
|
1987
1987
|
l_value = None
|
|
1988
1988
|
else:
|
|
1989
1989
|
if scolor_color:
|
|
1990
|
-
if scolor_color[0] in self.
|
|
1991
|
-
color_name = self.
|
|
1990
|
+
if scolor_color[0] in self.xvar["check_color_name"].keys():
|
|
1991
|
+
color_name = self.xvar["check_color_name"][scolor_color[0]]
|
|
1992
1992
|
else:
|
|
1993
1993
|
color_name = "not_found_" + str(scolor_color[0])
|
|
1994
1994
|
|
|
@@ -2018,9 +2018,9 @@ class scolor:
|
|
|
2018
2018
|
# 현재의 값에서 10만큼 어두워지도록 한다
|
|
2019
2019
|
l_value = -10 * len(plusminus100)
|
|
2020
2020
|
result = [0, 0, l_value]
|
|
2021
|
-
elif plusminus100 in self.
|
|
2022
|
-
no = self.
|
|
2023
|
-
result = self.
|
|
2021
|
+
elif plusminus100 in self.xvar["tone_vs_index"].keys():
|
|
2022
|
+
no = self.xvar["tone_vs_index"][plusminus100]
|
|
2023
|
+
result = self.xvar["basic_9color_sl_big_step"][no]
|
|
2024
2024
|
return result
|
|
2025
2025
|
|
|
2026
2026
|
def control_hsl(self, input_hsl, position, strength=50):
|
|
@@ -2058,10 +2058,10 @@ class scolor:
|
|
|
2058
2058
|
:return:
|
|
2059
2059
|
"""
|
|
2060
2060
|
|
|
2061
|
-
checked_color_style = self.
|
|
2061
|
+
checked_color_style = self.xvar["check_color_tone"][color_style]
|
|
2062
2062
|
|
|
2063
|
-
step_2 = self.
|
|
2064
|
-
step_1 = self.
|
|
2063
|
+
step_2 = self.xvar["basic_15tone_eng_vs_sl"][checked_color_style]
|
|
2064
|
+
step_1 = self.xvar["sl_10_by_작은step"][style_step]
|
|
2065
2065
|
h = int(input_hsl[0])
|
|
2066
2066
|
s = int(step_1[0]) + int(step_2[0])
|
|
2067
2067
|
l = int(step_1[1]) + int(step_2[1])
|
|
@@ -2078,7 +2078,7 @@ class scolor:
|
|
|
2078
2078
|
:param step_no:
|
|
2079
2079
|
:return:
|
|
2080
2080
|
"""
|
|
2081
|
-
s, l = self.
|
|
2081
|
+
s, l = self.xvar["색강도_vs_sl"][step_no]
|
|
2082
2082
|
result = [input_hsl[0], input_hsl[1] + s, input_hsl[2] + l]
|
|
2083
2083
|
|
|
2084
2084
|
def control_hsl_for_sl_by_plusminus100(self, input_hsl, s_step="++", l_step="++"):
|
|
@@ -2235,14 +2235,14 @@ class scolor:
|
|
|
2235
2235
|
"""
|
|
2236
2236
|
12가지 영어 색깔이름을 돌려준다
|
|
2237
2237
|
"""
|
|
2238
|
-
result = self.
|
|
2238
|
+
result = self.xvar["color_12_basic"]
|
|
2239
2239
|
return result
|
|
2240
2240
|
|
|
2241
2241
|
def data_for_12_color_tone_kor(self):
|
|
2242
2242
|
"""
|
|
2243
2243
|
칼라톤에 대한 한글이름
|
|
2244
2244
|
"""
|
|
2245
|
-
result = self.
|
|
2245
|
+
result = self.xvar["color_12_kor_basic"]
|
|
2246
2246
|
return result
|
|
2247
2247
|
|
|
2248
2248
|
def data_for_12_hsl(self):
|
|
@@ -2251,7 +2251,7 @@ class scolor:
|
|
|
2251
2251
|
|
|
2252
2252
|
:return:
|
|
2253
2253
|
"""
|
|
2254
|
-
result = self.
|
|
2254
|
+
result = self.xvar["basic_12color_hsl"]
|
|
2255
2255
|
return result
|
|
2256
2256
|
|
|
2257
2257
|
def data_for_12_hsl_for_pccs(self, hsl):
|
|
@@ -2261,7 +2261,7 @@ class scolor:
|
|
|
2261
2261
|
:param hsl: [h,s,l]형식의 값
|
|
2262
2262
|
"""
|
|
2263
2263
|
result = []
|
|
2264
|
-
for one_value in self.
|
|
2264
|
+
for one_value in self.xvar["basic_12color_hsl"]:
|
|
2265
2265
|
temp = self.change_hsl_to_rgb([hsl[0], one_value[0], one_value[1]])
|
|
2266
2266
|
result.append(temp)
|
|
2267
2267
|
return result
|
|
@@ -2297,7 +2297,7 @@ class scolor:
|
|
|
2297
2297
|
"""
|
|
2298
2298
|
기본 12가지 색에 대한 rgb 리스트 값
|
|
2299
2299
|
"""
|
|
2300
|
-
result = self.
|
|
2300
|
+
result = self.xvar["basic_12color_rgb"]
|
|
2301
2301
|
return result
|
|
2302
2302
|
|
|
2303
2303
|
def data_for_36_hsl(self):
|
|
@@ -2332,21 +2332,21 @@ class scolor:
|
|
|
2332
2332
|
"""
|
|
2333
2333
|
엑셀 기본 46 rgb 값
|
|
2334
2334
|
"""
|
|
2335
|
-
result = self.
|
|
2335
|
+
result = self.xvar["rgb_46_for_excel46"]
|
|
2336
2336
|
return result
|
|
2337
2337
|
|
|
2338
2338
|
def data_for_56_excel_rgb(self):
|
|
2339
2339
|
"""
|
|
2340
2340
|
엑셀 기본 56 rgb 값
|
|
2341
2341
|
"""
|
|
2342
|
-
result = self.
|
|
2342
|
+
result = self.xvar["rgb_56_for_excel56"]
|
|
2343
2343
|
return result
|
|
2344
2344
|
|
|
2345
2345
|
def data_for_8_pastel_rgb(self):
|
|
2346
2346
|
"""
|
|
2347
2347
|
기본적인 자료가 있는 색들의 배경색으로 사용하면 좋은 색들
|
|
2348
2348
|
"""
|
|
2349
|
-
color_set = self.
|
|
2349
|
+
color_set = self.xvar["basic_12color_hsl"][:-4]
|
|
2350
2350
|
result = []
|
|
2351
2351
|
for hsl_value in color_set:
|
|
2352
2352
|
rgb = self.change_scolor_to_rgb_with_pccs_style(hsl_value, "pastel", 4)
|
|
@@ -2357,7 +2357,7 @@ class scolor:
|
|
|
2357
2357
|
"""
|
|
2358
2358
|
모든 색깔의 이름들
|
|
2359
2359
|
"""
|
|
2360
|
-
result = list(set(self.
|
|
2360
|
+
result = list(set(self.xvar["check_color_name"].values()))
|
|
2361
2361
|
return result
|
|
2362
2362
|
|
|
2363
2363
|
def data_for_basic_color_name_kor(self):
|
|
@@ -2365,7 +2365,7 @@ class scolor:
|
|
|
2365
2365
|
12가지 기본색이름(한글)
|
|
2366
2366
|
:return:
|
|
2367
2367
|
"""
|
|
2368
|
-
result = self.
|
|
2368
|
+
result = self.xvar["color_12_kor_basic"]
|
|
2369
2369
|
return result
|
|
2370
2370
|
|
|
2371
2371
|
def data_for_color_name_12(self):
|
|
@@ -2373,7 +2373,7 @@ class scolor:
|
|
|
2373
2373
|
12가지 영어 색깔이름을 돌려준다
|
|
2374
2374
|
data로 시작하는 함수는 자료를 돌려주는 목적이다
|
|
2375
2375
|
"""
|
|
2376
|
-
result = self.
|
|
2376
|
+
result = self.xvar["color_12_basic"]
|
|
2377
2377
|
return result
|
|
2378
2378
|
|
|
2379
2379
|
def data_for_color_name_all(self):
|
|
@@ -2381,7 +2381,7 @@ class scolor:
|
|
|
2381
2381
|
모든 색깔의 이름들
|
|
2382
2382
|
data로 시작하는 함수는 자료를 돌려주는 목적이다
|
|
2383
2383
|
"""
|
|
2384
|
-
result = list(set(self.
|
|
2384
|
+
result = list(set(self.xvar["check_color_name"].values()))
|
|
2385
2385
|
return result
|
|
2386
2386
|
|
|
2387
2387
|
def data_for_color_name_kor_basic(self):
|
|
@@ -2389,7 +2389,7 @@ class scolor:
|
|
|
2389
2389
|
12가지 기본색이름(한글)
|
|
2390
2390
|
data로 시작하는 함수는 자료를 돌려주는 목적이다
|
|
2391
2391
|
"""
|
|
2392
|
-
result = self.
|
|
2392
|
+
result = self.xvar["color_12_kor_basic"]
|
|
2393
2393
|
return result
|
|
2394
2394
|
|
|
2395
2395
|
def data_for_color_tone_kor_12(self):
|
|
@@ -2397,7 +2397,7 @@ class scolor:
|
|
|
2397
2397
|
칼라톤에 대한 한글이름
|
|
2398
2398
|
data로 시작하는 함수는 자료를 돌려주는 목적이다
|
|
2399
2399
|
"""
|
|
2400
|
-
result = self.
|
|
2400
|
+
result = self.xvar["color_12_kor_basic"]
|
|
2401
2401
|
return result
|
|
2402
2402
|
|
|
2403
2403
|
def data_for_contrast_2set_8(self):
|
|
@@ -2421,7 +2421,7 @@ class scolor:
|
|
|
2421
2421
|
엑셀 기본 46 rgb 값
|
|
2422
2422
|
data로 시작하는 함수는 자료를 돌려주는 목적이다
|
|
2423
2423
|
"""
|
|
2424
|
-
result = self.
|
|
2424
|
+
result = self.xvar["rgb_46_for_excel46"]
|
|
2425
2425
|
return result
|
|
2426
2426
|
|
|
2427
2427
|
def data_for_excel_rgb56(self):
|
|
@@ -2429,7 +2429,7 @@ class scolor:
|
|
|
2429
2429
|
엑셀 기본 56 rgb 값
|
|
2430
2430
|
data로 시작하는 함수는 자료를 돌려주는 목적이다
|
|
2431
2431
|
"""
|
|
2432
|
-
result = self.
|
|
2432
|
+
result = self.xvar["rgb_56_for_excel56"]
|
|
2433
2433
|
return result
|
|
2434
2434
|
|
|
2435
2435
|
def data_for_hilight_7(self):
|
|
@@ -2445,7 +2445,7 @@ class scolor:
|
|
|
2445
2445
|
12가지 hsl의 값
|
|
2446
2446
|
data로 시작하는 함수는 자료를 돌려주는 목적이다
|
|
2447
2447
|
"""
|
|
2448
|
-
result = self.
|
|
2448
|
+
result = self.xvar["basic_12color_hsl"]
|
|
2449
2449
|
return result
|
|
2450
2450
|
|
|
2451
2451
|
def data_for_hsl_36(self):
|
|
@@ -2493,7 +2493,7 @@ class scolor:
|
|
|
2493
2493
|
기본적인 자료가 있는 색들의 배경색으로 사용하면 좋은 색들
|
|
2494
2494
|
data로 시작하는 함수는 자료를 돌려주는 목적이다
|
|
2495
2495
|
"""
|
|
2496
|
-
color_set = self.
|
|
2496
|
+
color_set = self.xvar["basic_12color_hsl"][:-4]
|
|
2497
2497
|
result = []
|
|
2498
2498
|
for hsl_value in color_set:
|
|
2499
2499
|
rgb = self.change_scolor_to_rgb_as_pccs_style_by_level10(hsl_value, "pastel", 4)
|
|
@@ -2508,7 +2508,7 @@ class scolor:
|
|
|
2508
2508
|
:param input_hsl: [h,s,l]형식의 값
|
|
2509
2509
|
"""
|
|
2510
2510
|
result = []
|
|
2511
|
-
for one_value in self.
|
|
2511
|
+
for one_value in self.xvar["basic_12color_hsl"]:
|
|
2512
2512
|
temp = self.change_hsl_to_rgb([input_hsl[0], one_value[0], one_value[1]])
|
|
2513
2513
|
result.append(temp)
|
|
2514
2514
|
return result
|
|
@@ -2537,7 +2537,7 @@ class scolor:
|
|
|
2537
2537
|
기본 12가지 색에 대한 rgb 리스트 값
|
|
2538
2538
|
data로 시작하는 함수는 자료를 돌려주는 목적이다
|
|
2539
2539
|
"""
|
|
2540
|
-
result = self.
|
|
2540
|
+
result = self.xvar["basic_12color_rgb"]
|
|
2541
2541
|
return result
|
|
2542
2542
|
|
|
2543
2543
|
def data_rgb_12set(self):
|
|
@@ -2545,7 +2545,7 @@ class scolor:
|
|
|
2545
2545
|
기본 12색에대한 rgb값을 돌려주는 것
|
|
2546
2546
|
:return:
|
|
2547
2547
|
"""
|
|
2548
|
-
result = self.
|
|
2548
|
+
result = self.xvar["basic_12color_rgb"]
|
|
2549
2549
|
return result
|
|
2550
2550
|
|
|
2551
2551
|
def find_near_list(self, rgb_list, target_rgb):
|
|
@@ -2611,7 +2611,7 @@ class scolor:
|
|
|
2611
2611
|
|
|
2612
2612
|
:return:
|
|
2613
2613
|
"""
|
|
2614
|
-
result = self.
|
|
2614
|
+
result = self.xvar["color_12_kor_basic"]
|
|
2615
2615
|
return result
|
|
2616
2616
|
|
|
2617
2617
|
def get_basic_12_color_name_list_by_eng(self):
|
|
@@ -2620,7 +2620,7 @@ class scolor:
|
|
|
2620
2620
|
|
|
2621
2621
|
:return:
|
|
2622
2622
|
"""
|
|
2623
|
-
result = self.
|
|
2623
|
+
result = self.xvar["basic_12color_rgb"]
|
|
2624
2624
|
return result
|
|
2625
2625
|
|
|
2626
2626
|
def get_basic_12_color_name_set_for_kor(self):
|
|
@@ -2628,7 +2628,7 @@ class scolor:
|
|
|
2628
2628
|
기본 12색에대한 한글 이름
|
|
2629
2629
|
:return:
|
|
2630
2630
|
"""
|
|
2631
|
-
result = self.
|
|
2631
|
+
result = self.xvar["color_12_kor_basic"]
|
|
2632
2632
|
return result
|
|
2633
2633
|
|
|
2634
2634
|
def get_color_name_for_rgbint(self, rgbint):
|
|
@@ -2703,8 +2703,8 @@ class scolor:
|
|
|
2703
2703
|
:param code:
|
|
2704
2704
|
:return:
|
|
2705
2705
|
"""
|
|
2706
|
-
h_list = self.
|
|
2707
|
-
sl_faber = self.
|
|
2706
|
+
h_list = self.xvar["basic_12color_hsl"]
|
|
2707
|
+
sl_faber = self.xvar["faber_to_sl"]
|
|
2708
2708
|
|
|
2709
2709
|
h_no = h_list[start_color][0]
|
|
2710
2710
|
result = []
|
|
@@ -2733,9 +2733,9 @@ class scolor:
|
|
|
2733
2733
|
:param stongness: 색의 농도를 나타내는 것, 검정에서 하양까지의 11단계를 나타낸것, 중간이 5이다
|
|
2734
2734
|
:return:
|
|
2735
2735
|
"""
|
|
2736
|
-
h_list = self.
|
|
2737
|
-
sl_list = self.
|
|
2738
|
-
hsl_johannes = self.
|
|
2736
|
+
h_list = self.xvar["basic_12color_hsl"]
|
|
2737
|
+
sl_list = self.xvar["sl11_step"]
|
|
2738
|
+
hsl_johannes = self.xvar["johannes_to_hsl"]
|
|
2739
2739
|
color_set = [[], [], [0, 6], [0, 5, 9], [0, 4, 7, 10], [0, 3, 5, 8, 10], [0, 3, 5, 7, 9, 11]]
|
|
2740
2740
|
|
|
2741
2741
|
h_no = h_list[start_color][0]
|
|
@@ -3019,8 +3019,8 @@ class scolor:
|
|
|
3019
3019
|
:param code:
|
|
3020
3020
|
:return:
|
|
3021
3021
|
"""
|
|
3022
|
-
h_list = self.
|
|
3023
|
-
sl_faber = self.
|
|
3022
|
+
h_list = self.xvar["basic_12color_hsl"]
|
|
3023
|
+
sl_faber = self.xvar["faber_to_sl"]
|
|
3024
3024
|
|
|
3025
3025
|
h_no = h_list[start_color][0]
|
|
3026
3026
|
result = []
|
|
@@ -3049,9 +3049,9 @@ class scolor:
|
|
|
3049
3049
|
:param stongness: 색의 농도를 나타내는 것, 검정에서 하양까지의 11단계를 나타낸것, 중간이 5이다
|
|
3050
3050
|
:return:
|
|
3051
3051
|
"""
|
|
3052
|
-
h_list = self.
|
|
3053
|
-
sl_list = self.
|
|
3054
|
-
hsl_johannes = self.
|
|
3052
|
+
h_list = self.xvar["basic_12color_hsl"]
|
|
3053
|
+
sl_list = self.xvar["sl11_step"]
|
|
3054
|
+
hsl_johannes = self.xvar["johannes_to_hsl"]
|
|
3055
3055
|
color_set = [[], [], [0, 6], [0, 5, 9], [0, 4, 7, 10], [0, 3, 5, 8, 10], [0, 3, 5, 7, 9, 11]]
|
|
3056
3056
|
|
|
3057
3057
|
h_no = h_list[start_color][0]
|