help@rskworld.in +91 93305 39277
RSK World
  • Home
  • Development
    • Web Development
    • Mobile Apps
    • Software
    • Games
    • Project
  • Technologies
    • Data Science
    • AI Development
    • Cloud Development
    • Blockchain
    • Cyber Security
    • Dev Tools
    • Testing Tools
  • About
  • Contact

Theme Settings

Color Scheme
Display Options
Font Size
100%
Back to Project
RSK World
java-math-tools
/
src
/
main
/
java
/
com
/
rskworld
/
mathtools
/
panels
RSK World
java-math-tools
Java Math Tools - 15 Mathematical Tools + Scientific Calculator + Geometry + Statistics + Financial Calculators + Swing GUI + Educational Design
panels
  • AgeCalculatorPanel.java2.4 KB
  • BMIPanel.java2.3 KB
  • CalculatorPanel.java4.5 KB
  • ConstantsPanel.java1.6 KB
  • EquationSolverPanel.java3.3 KB
  • FinancialPanel.java3.2 KB
  • GSTPanel.java2.1 KB
  • GeometryPanel.java4 KB
  • HistoryPanel.java1.8 KB
  • MatrixPanel.java4.2 KB
  • NumberSystemPanel.java3 KB
  • PasswordPanel.java3.2 KB
  • PlotterPanel.java3 KB
  • PrimePanel.java3.5 KB
  • StatisticsPanel.java3.5 KB
  • UnitConverterPanel.java5.8 KB
ConstantsPanel.java
src/main/java/com/rskworld/mathtools/panels/ConstantsPanel.java
Raw Download
Find: Go to:
/**
 * Project: Java Basic Math Tools
 * Developer: Molla Samser
 * Designer & Tester: Rima Khatun
 * Website: https://rskworld.in
 * Year: 2026
 */

package com.rskworld.mathtools.panels;

import com.rskworld.mathtools.utils.ThemeManager;
import javax.swing.*;
import java.awt.*;

public class ConstantsPanel extends JPanel {
    public ConstantsPanel() {
        setLayout(new BorderLayout());
        setBackground(ThemeManager.BACKGROUND);
        initComponents();
    }

    private void initComponents() {
        String[] columns = {"Constant", "Symbol", "Value", "Description"};
        Object[][] data = {
            {"Pi", "π", "3.1415926535...", "Ratio of circumference to diameter"},
            {"Euler's Number", "e", "2.718281828...", "Base of natural logarithms"},
            {"Golden Ratio", "φ", "1.618033988...", "Divine proportion"},
            {"Light Speed", "c", "299,792,458 m/s", "Speed of light in vacuum"},
            {"Gravity", "g", "9.80665 m/s²", "Earth's surface gravity"},
            {"Planck's Constant", "h", "6.626e-34 J·s", "Quantum of action"},
            {"Avogadro Number", "Na", "6.022e23 mol⁻¹", "Particles in one mole"}
        };

        JTable table = new JTable(data, columns);
        table.setBackground(ThemeManager.PANEL_BACKGROUND);
        table.setForeground(ThemeManager.TEXT_PRIMARY);
        table.setFillsViewportHeight(true);
        table.setRowHeight(30);
        
        JScrollPane scroll = new JScrollPane(table);
        add(scroll, BorderLayout.CENTER);
        
        ThemeManager.applyTheme(this);
    }
}
46 lines•1.6 KB
java

About RSK World

Founded by Molla Samser, with Designer & Tester Rima Khatun, RSK World is your one-stop destination for free programming resources, source code, and development tools.

Founder: Molla Samser
Designer & Tester: Rima Khatun

Development

  • Game Development
  • Web Development
  • Mobile Development
  • AI Development
  • Development Tools

Legal

  • Terms & Conditions
  • Privacy Policy
  • Disclaimer

Contact Info

Nutanhat, Mongolkote
Purba Burdwan, West Bengal
India, 713147

+91 93305 39277

hello@rskworld.in
support@rskworld.in

© 2026 RSK World. All rights reserved.

Content used for educational purposes only. View Disclaimer