README.md

July 12, 2026 · View on GitHub

LineSolv Logo

LineSolv Plugins

Community plugins for LineSolv — a natural-language calculator desktop app.

Dark Welcome    Light Mode

Plugin Marketplace    Plugin Details


What Are Plugins?

LineSolv plugins extend the calculator with custom functions, themes, and constants — all without writing any code. Plugins are pure data manifests (plugin.json) that define math expressions, color themes, or named constants.

Plugin Types

TypeWhat It AddsExample
FunctionsCustom math functionscircle_area(5), compound_interest(1000, 0.05, 10)
ThemesColor themes for the UIDracula, Nord, Solarized
VariablesNamed constantsc (speed of light), g (gravity)

Available Plugins

Functions

PluginDescriptionFunctions
math-extrasExtra math functionsclamp, lerp, smoothstep, wrap, average
statisticsStatistical analysismean, median, std_dev, variance, percentile
financialFinancial calculationscompound_interest, loan_payment, present_value, future_value, roi, cagr
geometryGeometry formulascircle_area, sphere_volume, pythagorean, distance, and more
conversionsUnit conversionscelsius_to_fahrenheit, km_to_miles, kg_to_lbs, feet_to_meters, and more

Themes

PluginDescriptionThemes
ocean-themeOcean-inspired colorsOcean, Sunset
solarizedSolarized by Ethan SchoonoverSolarized Dark, Solarized Light
draculaDracula dark themeDracula
nordArctic blue paletteNord

Variables

PluginDescriptionConstants
physics-constantsPhysics constantsc, g, h, k, NA, R, eV, au, ly, pc
chemistry-constantsChemistry & physics constantsF, Na, R, sigma, big_G, little_g, m_e, m_p, m_n, and more
math-constantsMathematical constantspi, euler, phi, sqrt2, gamma, tau, and more

Installation

  1. Open LineSolv
  2. Click the Plugins icon in the title bar (or press Ctrl/Cmd + U)
  3. Browse or search for a plugin
  4. Click Install to add it to your LineSolv

Installed plugins are saved to ~/.config/neostore/linesolv/plugins/ and activate immediately.

Managing Plugins

ActionHow
Enable/DisableToggle the switch on an installed plugin
UpdateClick "Update" when a new version is available
RemoveClick "Remove" and confirm
View DetailsClick a plugin card to see functions, themes, variables, and README

Usage Examples

Math Functions

InputOutput
clamp(15, 0, 10)10
lerp(0, 100, 0.25)25
smoothstep(0, 1, 0.5)0.5
circle_area(5)78.5398
compound_interest(1000, 0.05, 10)1628.89

Themes

After installing a theme plugin, open Settings > Theme to select it. Theme plugins are labeled with a "Plugin" badge.

Constants

After installing a constants plugin, use the constants directly:

InputOutput
c299792458
c * 2599584916
g9.80665

Creating Plugins

See the Plugin Development Guide for full details, including step-by-step walkthroughs, debugging tips, and advanced patterns.

Quick Start

  1. Create a directory under ~/.config/neostore/linesolv/plugins/ with your plugin name
  2. Add a plugin.json manifest and a README.md
  3. Update plugins.json (the index) with your plugin entry
  4. Submit a Pull Request

plugin.json Format

{
  "name": "my-plugin",
  "version": "1.0.0",
  "description": "What this plugin does",
  "author": "Your Name",
  "homepage": "https://github.com/yourname/my-plugin",
  "functions": [
    {
      "name": "my_func",
      "description": "Does something useful",
      "args": 2,
      "min_args": 2,
      "max_args": 2,
      "expression": "a + b",
      "examples": ["my_func(1, 2)", "my_func(5, 10)"]
    }
  ],
  "themes": [...],
  "variables": [...]
}

Function Types

  • Expression functions: Use "expression": "a + b * c" with variables a, b, c mapped to arguments
  • Builtin functions: Use "builtin": "clamp" for pre-defined operations (clamp, lerp, smoothstep, average, etc.)

Available Builtin Functions

BuiltinArgsDescription
clamp3Clamp value between min and max
lerp3Linear interpolation
smoothstep3Smooth Hermite interpolation
wrap3Wrap value within range
average1+Arithmetic mean
median1+Median value
std_dev2+Standard deviation
variance2+Variance
percentile2+P-th percentile
sum1+Sum of all arguments
product1+Product of all arguments
gcd2Greatest common divisor
lcm2Least common multiple
fact1Factorial
npr2Permutations
ncr2Combinations
hypot2Hypotenuse
rad1Degrees to radians
deg1Radians to degrees

Plugin Development Guide

Expression Engine

Plugin expressions support:

  • Operators: +, -, *, /, % (modulo), ^ (power)
  • Parentheses: (expr)
  • Functions: abs, sin, cos, tan, asin, acos, atan, atan2, sqrt, cbrt, log, ln, log2, exp, pow, floor, ceil, round, sign, min, max, mod
  • Constants: pi, e, tau (2*pi), phi (golden ratio)
  • Variables: a-z mapped to the function arguments

Theme Colors

Themes define 14 CSS custom properties:

VariableDescription
--surfaceMain background
--surface-secondaryPanel background
--surface-hoverHover state
--borderBorder color
--accentPrimary accent
--accent-hoverAccent on hover
--textPrimary text
--text-mutedSecondary text
--text-subtleTertiary text
--errorError color
--successSuccess color
--infoInfo color
--shadowShadow color

Validation Rules

The plugin loader enforces:

  • name, version, description, author must be non-empty
  • At least one function, theme, or variable required
  • No duplicate function names within a plugin
  • No duplicate theme IDs within a plugin
  • Expressions must use valid syntax
  • Builtin references must use known names

Limitations

  • No code execution: Only math expressions or builtin references
  • Single-letter variables: a through z only
  • No loops or conditionals: Pure math expressions
  • Max 26 arguments: Limited by variable letters
  • No network or file access: Pure data manifests
  • No cross-plugin dependencies

For complete details, see the Plugin Development Guide.


Contributing

  1. Fork this repository
  2. Add your plugin to the plugins/ directory (include plugin.json and README.md)
  3. Update the plugins.json index file
  4. Submit a Pull Request

Pull Request Checklist

  • plugin.json is valid JSON
  • All required fields are present
  • No duplicate names with existing plugins
  • Working expressions with valid syntax
  • Complete README.md with documentation
  • Plugin tested in LineSolv

Contributors

rkriad585

License

MIT