Skip to content

๐Ÿงฎ๐Ÿ”ข Simple Calculator application made in Java โ˜• using JavaFX ๐Ÿ–ผ๏ธ allowing fundamental math functions โœ–๏ธโž—โž•โž–๐ŸŸฐ

License

Notifications You must be signed in to change notification settings

Kerciu/javafx-calculator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

49 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿงฎ JavaFX Calculator App

๐Ÿ“œ Description

A simple calculator application built using JavaFX for the user interface. This desktop application supports basic arithmetic operations such as addition, subtraction, multiplication, and division. The app features a responsive user interface with optional dark mode and includes utility classes for parsing operations and managing calculator states.

๐Ÿ“ Notes

  • Ensure you have Java 8 or later installed. ๐ŸŒŸ
  • You need a properly configured Java Development Kit (JDK) to run the application. ๐Ÿ› ๏ธ
  • In case of missing dependencies, verify that all required libraries are included in the lib folder or declared in the pom.xml file. ๐Ÿ”

๐Ÿ› ๏ธ Usage

  1. Launch the Application:

    • Run the application by executing the MainClass.java in the com.calculator.main package. ๐Ÿš€
  2. Calculator Interface:

    • Numeric Buttons: Click or input numbers directly to the calculator. ๐Ÿ”ข
    • Operation Buttons: Choose operations such as addition (+), subtraction (-), multiplication (ร—), division (รท) and more. โž•โž–โœ–๏ธโž—
    • Display: The main display shows the current input and the result of calculations. ๐Ÿ“Ÿ
    • Equals Button: Compute the result of the current (binary) operation. โœ…
    • Clear and Clear Entry Buttons: Reset the current input or operation. ๐Ÿงน
    • Dark Mode Toggle: Switch between light and dark modes for a customized user experience. ๐ŸŒ™
  3. Core Functionality:

    • Binary Operations: Handle operations that involve two numbers (e.g., 5 + 3).
    • Unary Operations: Execute operations with a single operand (e.g., reciprocal or percentage).

๐Ÿ“ Project Structure

  • src/ - Source code directory
    • com/
      • calculator/ - Java source files
        • constants/ - Operator constants used throughout the application
        • controller/ - Contains CalculatorController.java for managing the interface logic
        • darkMode/ - Includes classes for handling dark mode (DarkModeSwitcher.java, ToggleSwitch.java)
        • icon/ - Utility for loading application icons (StageIconLoader.java)
        • main/ - Main entry point of the application (MainClass.java)
        • parsers/ - Logic for parsing binary and unary operations
        • state/ - Manages calculator state and operations (CalculatorState.java)
      • test/ - Unit tests for the parser and constants classes
    • resources/ - Resource directory
      • assets/images/ - Icons and images for the application (calculator.png)
      • styles/ - CSS for styling the application (styles.css)
      • calculator-main.fxml - FXML layout file for the calculator interface

๐Ÿ–ผ๏ธ Screenshots

Calculator Light UI Calculator Dark UI

๐Ÿ“œ License

This project is licensed under the MIT License. See the LICENCE file for details. ๐Ÿ“

๐Ÿ“ฌ Contact

For questions, feedback, or support:

For any issues, please open a GitHub issue. ๐Ÿš€

About

๐Ÿงฎ๐Ÿ”ข Simple Calculator application made in Java โ˜• using JavaFX ๐Ÿ–ผ๏ธ allowing fundamental math functions โœ–๏ธโž—โž•โž–๐ŸŸฐ

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published