Skip to main content

A multi-language to Python code renderer with CLI visualization.

Project description

LanguageRenderer7

LanguageRenderer7 is a Python-based language converter that supports converting code from 7 popular programming languages into Python. It includes syntax transformers, code visualization, statistical insights, and rich colored terminal output.

🌍 Supported Input Languages

  • JavaScript
  • Java
  • C
  • C++
  • Go
  • PHP
  • Ruby

🚀 Features

  • Convert code from 7 languages to Python.
  • Render with syntax highlighting using pygments.
  • Beautiful CLI output with rich and colorama.
  • Analyze conversion frequency and visualize using matplotlib and networkx.
  • Batch rendering with tqdm progress bar.
  • Web scraping code snippets using requests and beautifulsoup4.
  • Logs all conversions and builds a language graph.

🛠 Installation

python -m venv venv
venv\Scripts\activate
pip install -U pip
pip install language-renderer7

Or Clone With Git

git clone https://github.com/EdenGithhub/LanguageRenderer7

⚠️ Requires Python 3.7+


📦 Dependencies

  • matplotlib
  • numpy
  • colorama
  • rich
  • pygments
  • beautifulsoup4
  • requests
  • tqdm
  • lxml
  • networkx

Install all via:

pip install -r requirements.txt

📄 Example: Basic Usage

from language_renderer7.core import LanguageRenderer

renderer = LanguageRenderer()
code = 'console.log("Hello from JS!");'
output = renderer.render(code, "javascript")
print(output)

📁 Example: Render from File

output = renderer.render_from_file("examples/example.c", "c", highlight=False)
print(output)

🔁 Batch Rendering Example

items = [
    ("javascript", 'console.log("Hello")'),
    ("php", 'echo "Hi!";'),
    ("ruby", 'puts "Hey!"')
]
results = renderer.render_batch(items, highlight=False)

🌐 Web Scrape Docs

snippets = renderer.scrape_doc("https://www.w3schools.com/js/js_examples.asp")
print(snippets)

📊 Show Stats and Graph

renderer.show_stats()
renderer.show_graph()

✅ Testing

Run full tests:

python -m unittest tests/test_core.py -v

📤 Publishing to PyPI

Use your PowerShell with env token:

$env:PYPI_USERNAME="your-username"
$env:PYPI_TOKEN="pypi-***"
python -m build
python -m twine upload dist/* --username $env:PYPI_USERNAME --password $env:PYPI_TOKEN --verbose

📚 License

MIT License


✨ Author

Created with ❤️ by Adam Alcander et Eden.

Contact : Email = aeden6877@gmail.com GitHub = EdenGithhub


🔮 Future Plans

  • Add Kotlin and Swift support
  • LLM-powered smart converter (experimental)
  • GUI version with drag & drop support
  • VS Code extension
  • Live conversion mode via socket
  • Language auto-detection
  • Integration with GitHub Copilot
  • Export to .py files directly
  • Dark/light themes for terminal
  • API endpoints for external tools

© Eden Simamora\2025

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

language_renderer7-0.1.0.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

language_renderer7-0.1.0-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

Details for the file language_renderer7-0.1.0.tar.gz.

File metadata

  • Download URL: language_renderer7-0.1.0.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.3

File hashes

Hashes for language_renderer7-0.1.0.tar.gz
Algorithm Hash digest
SHA256 e1fcff330da52cdc014f1bb0704df3c2d002244023178006b3bc34e008573fbe
MD5 7f2fdadb8b6b2f133a804f460d1e52c9
BLAKE2b-256 0c3c4e4ceb2b2d05a52db5cbd1452ec206ec151e11c4fcbc0b2df875600b23cc

See more details on using hashes here.

File details

Details for the file language_renderer7-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for language_renderer7-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5f1367b487fb6903b6c4d261b7cb083db917c708fd3dee4f693d6f40a70f9a95
MD5 8dc5d7f517659d212f8df76768b183d5
BLAKE2b-256 c8290f57128304a916551ca991d138969101e11cf7f82d7ecab7c7b47022667f

See more details on using hashes here.

Supported by

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