PyNexusAPI 1.0.1b0__tar.gz → 1.0.2b0__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: PyNexusAPI
3
- Version: 1.0.1b0
3
+ Version: 1.0.2b0
4
4
  Summary: A massive bundle bridge for lazy developers to control OS, GUI, Keyboard and Mouse
5
5
  Author: Noob3ButUkr
6
6
  Classifier: Programming Language :: Python :: 3
@@ -24,5 +24,31 @@ Dynamic: summary
24
24
 
25
25
  \# PyNexusAPI (no not GD nexus, it would be Pyfnm04API then.)
26
26
 
27
- The ultimate bridge between lazy developers and low-level libraries, designed for good..
27
+ The ultimate bridge between lazy developers and low-level libraries, designed for good.
28
+
29
+
30
+
31
+ Usage:
32
+
33
+
34
+
35
+ Recomended to use "import PyNexusAPI as nexus" or "as pn"
36
+
37
+ Also - modules macOS, Linux, Windows are not cross-platform.
38
+
39
+
40
+
41
+ from PyNexusAPI import Mouse, Keyboard, Clipboard
42
+
43
+
44
+
45
+ Mouse.LeftClick()
46
+
47
+ Keyboard.FWrite("Hello world!")
48
+
49
+ Clipboard.CopyText("Hello world! x2")
50
+
51
+
52
+
53
+ Note: Clipboard.CopyAny works ONLY for Windows.
28
54
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: PyNexusAPI
3
- Version: 1.0.1b0
3
+ Version: 1.0.2b0
4
4
  Summary: A massive bundle bridge for lazy developers to control OS, GUI, Keyboard and Mouse
5
5
  Author: Noob3ButUkr
6
6
  Classifier: Programming Language :: Python :: 3
@@ -24,5 +24,31 @@ Dynamic: summary
24
24
 
25
25
  \# PyNexusAPI (no not GD nexus, it would be Pyfnm04API then.)
26
26
 
27
- The ultimate bridge between lazy developers and low-level libraries, designed for good..
27
+ The ultimate bridge between lazy developers and low-level libraries, designed for good.
28
+
29
+
30
+
31
+ Usage:
32
+
33
+
34
+
35
+ Recomended to use "import PyNexusAPI as nexus" or "as pn"
36
+
37
+ Also - modules macOS, Linux, Windows are not cross-platform.
38
+
39
+
40
+
41
+ from PyNexusAPI import Mouse, Keyboard, Clipboard
42
+
43
+
44
+
45
+ Mouse.LeftClick()
46
+
47
+ Keyboard.FWrite("Hello world!")
48
+
49
+ Clipboard.CopyText("Hello world! x2")
50
+
51
+
52
+
53
+ Note: Clipboard.CopyAny works ONLY for Windows.
28
54
 
@@ -0,0 +1,30 @@
1
+ \# PyNexusAPI (no not GD nexus, it would be Pyfnm04API then.)
2
+
3
+ The ultimate bridge between lazy developers and low-level libraries, designed for good.
4
+
5
+
6
+
7
+ Usage:
8
+
9
+
10
+
11
+ Recomended to use "import PyNexusAPI as nexus" or "as pn"
12
+
13
+ Also - modules macOS, Linux, Windows are not cross-platform.
14
+
15
+
16
+
17
+ from PyNexusAPI import Mouse, Keyboard, Clipboard
18
+
19
+
20
+
21
+ Mouse.LeftClick()
22
+
23
+ Keyboard.FWrite("Hello world!")
24
+
25
+ Clipboard.CopyText("Hello world! x2")
26
+
27
+
28
+
29
+ Note: Clipboard.CopyAny works ONLY for Windows.
30
+
@@ -7,14 +7,19 @@ import time
7
7
  import datetime
8
8
  import keyboard
9
9
  import pyperclip
10
- import win32clipboard
11
- import win32con
12
- import ctypes
13
- from ctypes import wintypes
10
+ if os.name == "nt":
11
+ import win32clipboard
12
+ import win32con
13
+ import ctypes
14
+ from ctypes import wintypes
15
+ else:
14
16
  import warnings
15
17
  import customtkinter as ctk
18
+ import builtins
19
+ # I import actions not when then needed because it will slow down it when functions is on, what did i just spell?
16
20
 
17
- print("Thanks for using PyNexusAPI by PyNoob CaSP Software (C) 2026! This message can be deleted by going into project's file and just uhm like deleting it..")
21
+ # print("Thanks for using PyNexusAPI by PyNoob CaSP Software (C) 2026! This message can be deleted by going into project's file and just uhm like deleting it..")
22
+ # deleted for good no being pygame
18
23
 
19
24
  class DROPFILES(ctypes.Structure):
20
25
  _fields_ = [
@@ -143,9 +148,11 @@ class Clipboard:
143
148
 
144
149
  @staticmethod
145
150
  def CopyAny(file_path):
151
+ if sys.platform != "win32":
152
+ raise OSError("Clipboard.CopyAny can be only executed on Microsoft Windows.")
146
153
  abs_path = os.path.abspath(file_path)
147
154
  if not os.path.exists(abs_path):
148
- raise FileNotFoundError(f"Файл по пути '{abs_path}' не существует!")
155
+ raise FileNotFoundError(f"File with path {abs_path} is not found because it doesn't exist.")
149
156
  file_str = abs_path + "\x00\x00"
150
157
  file_bytes = file_str.encode("utf-16-le")
151
158
  dropfiles = DROPFILES()
@@ -388,12 +395,10 @@ class Log:
388
395
  Log._orig_print(f"[PyNexusAPI.Log] Error: Unable to log: {e}")
389
396
  except:
390
397
  pass
391
- import builtins
392
398
  builtins.print = log_print
393
399
 
394
400
  @staticmethod
395
401
  def Unhook():
396
- import builtins
397
402
  builtins.print = Log._orig_print
398
403
 
399
404
  class App:
@@ -404,30 +409,25 @@ class App:
404
409
  self.window.title(title)
405
410
  self.window.geometry(size)
406
411
 
407
- @staticmethod
408
412
  def AddText(self, text, font_size=16, pady=10):
409
413
  label = ctk.CTkLabel(self.window, text=text, font=("Arial", font_size))
410
414
  label.pack(pady=pady)
411
415
  return label
412
416
 
413
- @staticmethod
414
417
  def AddButton(self, text, command, pady=10):
415
418
  btn = ctk.CTkButton(self.window, text=text, command=command)
416
419
  btn.pack(pady=pady)
417
420
  return btn
418
421
 
419
- @staticmethod
420
422
  def AddInput(self, placeholder="Input something...", width=250, pady=10):
421
423
  entry = ctk.CTkEntry(self.window, placeholder_text=placeholder, width=width)
422
424
  entry.pack(pady=pady)
423
425
  return entry
424
426
 
425
- @staticmethod
426
427
  def AddCheckbox(self, text, command=None, pady=10):
427
428
  checkbox = ctk.CTkCheckBox(self.window, text=text, command=command)
428
429
  checkbox.pack(pady=pady)
429
430
  return checkbox
430
431
 
431
- @staticmethod
432
432
  def Run(self):
433
433
  self.window.mainloop()
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
2
2
 
3
3
  setup(
4
4
  name="PyNexusAPI",
5
- version="1.0.1b0",
5
+ version="1.0.2b0",
6
6
  author="Noob3ButUkr", # or PyNoob3 CaSP Software (C) 2026, or even Python Noob3ButUkr Custom and Small Projects Copyright 2026
7
7
  description="A massive bundle bridge for lazy developers to control OS, GUI, Keyboard and Mouse",
8
8
  long_description=open("README.md", encoding="utf-8").read(),
@@ -1,4 +0,0 @@
1
- \# PyNexusAPI (no not GD nexus, it would be Pyfnm04API then.)
2
-
3
- The ultimate bridge between lazy developers and low-level libraries, designed for good..
4
-
File without changes