Skip to main content

X9 is a user-friendly multi-use module made by PyModuleDev.

Project description

X9 by Pymoduledev

NOTE: X9 only works in Python 3.1+

Updates

1.0.1 - bug fixes in description

1.0.0 - initial release

What is X9?

X9 is a comprehensive Python module developed by pymoduledev, offering three essential classes that cater to various programming needs. The module includes the following classes:

  1. gui: Provides functionalities for creating and managing graphical user interfaces (GUIs) using tkinter.
  2. web: Enables the development of web applications using wsgiref.simple_server's make_server and logging.
  3. maths: An improved version of the standard math module, offering additional mathematical capabilities made using math.

How to Install X9

You can easily install X9 using pip:

pip install x9

How do I use X9?

X9 is very easy to understand, and you can take an tutorial here right now.

GUI Class

The gui class facilitates the creation of user-friendly graphical interfaces. Here's a simple example:

from x9 import gui

window = gui.new()
window.bg(color='#000000')
window.title('My Window')
window.favicon('path/to/favicon.ico')
window.resize("1880x600")

textbox = window.textbox(placeholder='type here...')
textbox.resize(100)

text = gui.label('Hey!')
gui.font(text, 'Arial', 16, is_bold=True)

button = window.button(value='submit',command=lambda: print(textbox.get()))

window.run()

Web Class

With the web class, you can effortlessly build web applications and APIs. Here's a basic example:

from x9 import web

app = web() #Create the web instance

def index():
    return '<p>Hello, World!</p>'

def render_html():
    return app.html('index.html') #This will get the contents of the index.html file assuming it is in the same directory as the Python file

app.new(index, '/')

app.new(render_html, '/render-html')

app.run()

Maths Class

The maths class extends the capabilities of the standard math module. Take advantage of its additional functions:

from x9 import maths as ImprovedMath

# Using Algebra functions
a, b, c = 1, -3, 2
roots = ImprovedMath.Algebra.quadratic_formula(a, b, c)
print(f"The roots of the quadratic equation {a}x^2 + {b}x + {c} = 0 are: {roots}")

# Using Calculus functions
coefficients = [1, 2, 3]
x = 2
derivative_at_x = ImprovedMath.Calculus.differentiate_polynomial(coefficients, x)
print(f"The derivative of the polynomial {coefficients} at x={x} is: {derivative_at_x}")

# Using Statistics functions
data = [2, 4, 6, 8, 10]
mean_value = ImprovedMath.Statistics.mean(data)
print(f"The mean of the data {data} is: {mean_value}")

variance_value = ImprovedMath.Statistics.variance(data)
print(f"The variance of the data {data} is: {variance_value}")

Contributions

We welcome contributions from the community to enhance X9 further. Feel free to share your ideas, report bugs, or request new features at the official PyModuleDev website(pymoduledev.neocities.org)

License

X9 is distributed under the Apache License 2.0. A copy of the License can be found at https://www.apache.org/licenses/LICENSE-2.0.txt.

Contact

For any questions or support, you can reach out to pymoduledev at pxcom@mail.com.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

x9-1.0.1.tar.gz (9.7 kB view details)

Uploaded Source

File details

Details for the file x9-1.0.1.tar.gz.

File metadata

  • Download URL: x9-1.0.1.tar.gz
  • Upload date:
  • Size: 9.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.11

File hashes

Hashes for x9-1.0.1.tar.gz
Algorithm Hash digest
SHA256 fdc5921d32e293ffe1b995eaee6a6237471c1979602196c1d6232e1bf496e341
MD5 e42511dc8e6d4dff1a21281297e90626
BLAKE2b-256 afc6fda97b9c53f8c81d5e3f72c6b8a33e631713080ac8dc280f175728f88d63

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page