# Path: mathfuncs.py
# def sum(*numbers):
# def mod(dividend, divisor):
# def ceil(x):
# def exp(x):
# def fact(n):
# def sqrt(x):
# def floor(x):
# def pow(x, y):
# def deg(radians):
# def rad(degrees):
# def hyp(x, y):
# def log10(x):
# def log2(x):
# def log(x, y):
# def lg(x):
# def ln(x):
# def acosh(x):
# def asinh(x):
# def atanh(x):
# def cosh(x):
# def sinh(x):
# def tanh(x):
# def acos(x):
# def asin(x):
# def atan(x):
# def atan2(y, x):
# def cos(x):
# def sin(x):
# def tan(x):
# def erf(x):
# def erfc(x):
# def gamma(x):
# def lgamma(x):
# def cdf(x):
# def bin(x):
# def oct(x):
# def hex(x):
# def round(x, *dig):     # in parsefuncs.function_handler.used_optlist
# def abs(x):
# def min(*numbers):
# def max(*numbers):
# def rt(x, N):
# def cbrt(x):
# def pc(x, percent):
# def perc(x, percent):
# def dperc(old, new):
# def gcd(x, y):
# def dms(degrees, minutes, *seconds):  # Args may be negative, and may be subtracted
# def dd(degrees):
# def amn(*numbers):
# def gmn(*numbers):
# def hmn(*numbers):
# def in_mm(inch):
# def in_cm(inch):
# def in_m(inch):
# def ft_in(foot):
# def ft_mm(foot):
# def ft_cm(foot):
# def ft_m(foot):
# def ftin_cm(foot, inch):    # Args may be negative, and may be subtracted
# def ftin_m(foot, inch):     # Args may be negative, and may be subtracted
# def yd_in(yard):
# def yd_ft(yard):
# def yd_mm(yard):
# def yd_cm(yard):
# def yd_m(yard):
# def yd_km(yard):
# def mi_yd(mile):
# def mi_m(mile):
# def mi_km(mile):
# def mm_in(mm):
# def cm_in(cm):
# def cm_ft(cm):
# def cm_ftin(cm):
# def m_ftin(m):
# def m_in(m):
# def m_ft(m):
# def m_yd(m):
# def m_mi(m):
# def km_mi(km):
# def sqcm_sqin(sqcm):
# def sqm_sqft(sqm):
# def sqm_sqyd(sqm):
# def sqm_ac(sqm):
# def sqm_ha(sqm):
# def sqkm_sqmi(sqkm):
# def sqin_sqcm(sqin):
# def sqft_sqm(sqft):
# def sqyd_sqm(sqyd):
# def sqmi_sqkm(sqmi):
# def sqmi_ac(sqmi):
# def sqmi_ha(sqmi):
# def ac_ha(ac):
# def ha_ac(ha):
# def l_usgal(l):
# def l_ukgal(l):
# def gal_pt(gal):
# def ukgal_l(ukgal):
# def usgal_l(usgal):
# def oz_g(ounce):
# def lb_oz(pound):
# def lb_g(pound):
# def lb_kg(pound):
# def g_oz(gram):
# def g_lb(gram):
# def kg_oz(kg):
# def kg_lb(kg):
# def ct_g(ct):
# def ct_oz(ct):
# def g_ct(g):
# def oz_ct(oz):
# def wh_cl(watt):
# def wh_j(watt_h):
# def cl_j(calorie):
# def cl_wh(calorie):
# def j_cl(joule):
# def j_wh(joule):
# def c_f(c):
# def c_k(c):
# def f_c(f):
# def f_k(f):
# def k_c(k):
# def k_f(k):
# def kw_hp(kw):
# def hp_kw(hp):
#     def __init__(self, *args):
# class MathError(ValueError):


from math import isfinite
from PyQt5 import QtCore, QtGui, QtWidgets
from mathfuncs import safeeval_dict
import common
            QtWidgets.QDialogButtonBox.Close,
            QtCore.Qt.Horizontal)

        self.listView.getFocus.connect(self.firstSel)
        self.listView.customContextMenuRequested.connect(self.listContextMenu)
        self.inputLine.returnPressed.connect(self.getInput)
        self.inputLine.textChanged.connect(self.statTurnBack)
        self.buttons.clicked.connect(self.close)

        constLayout = QtWidgets.QVBoxLayout()
        listLayout = QtWidgets.QVBoxLayout()
        noteLayout = QtWidgets.QVBoxLayout()
        listLayout.addWidget(self.listView)
        listLayout.addWidget(self.statBar)
        listLayout.setContentsMargins(0, 0, 0, 18)
        listLayout.setSpacing(3)
        noteLayout.addWidget(self.warnNote)
        noteLayout.addWidget(self.infoNote)
        noteLayout.setSpacing(6)
        noteLayout.setContentsMargins(0, 0, 0, 12)

        constLayout.addWidget(self.inputLine)
        constLayout.addItem(listLayout)
        constLayout.addItem(noteLayout)
        constLayout.addWidget(self.buttons)

        self.setLayout(constLayout)

        # Load Constants on init
        for c in sorted(constants):

# Path: mathfuncs.py
# def sum(*numbers):
# def mod(dividend, divisor):
# def ceil(x):
# def exp(x):
# def fact(n):
# def sqrt(x):
# def floor(x):
# def pow(x, y):
# def deg(radians):
# def rad(degrees):
# def hyp(x, y):
# def log10(x):
# def log2(x):
# def log(x, y):
# def lg(x):
# def ln(x):
# def acosh(x):
# def asinh(x):
# def atanh(x):
# def cosh(x):
# def sinh(x):
# def tanh(x):
# def acos(x):
# def asin(x):
# def atan(x):
# def atan2(y, x):
# def cos(x):
# def sin(x):
# def tan(x):
# def erf(x):
# def erfc(x):
# def gamma(x):
# def lgamma(x):
# def cdf(x):
# def bin(x):
# def oct(x):
# def hex(x):
# def round(x, *dig):     # in parsefuncs.function_handler.used_optlist
# def abs(x):
# def min(*numbers):
# def max(*numbers):
# def rt(x, N):
# def cbrt(x):
# def pc(x, percent):
# def perc(x, percent):
# def dperc(old, new):
# def gcd(x, y):
# def dms(degrees, minutes, *seconds):  # Args may be negative, and may be subtracted
# def dd(degrees):
# def amn(*numbers):
# def gmn(*numbers):
# def hmn(*numbers):
# def in_mm(inch):
# def in_cm(inch):
# def in_m(inch):
# def ft_in(foot):
# def ft_mm(foot):
# def ft_cm(foot):
# def ft_m(foot):
# def ftin_cm(foot, inch):    # Args may be negative, and may be subtracted
# def ftin_m(foot, inch):     # Args may be negative, and may be subtracted
# def yd_in(yard):
# def yd_ft(yard):
# def yd_mm(yard):
# def yd_cm(yard):
# def yd_m(yard):
# def yd_km(yard):
# def mi_yd(mile):
# def mi_m(mile):
# def mi_km(mile):
# def mm_in(mm):
# def cm_in(cm):
# def cm_ft(cm):
# def cm_ftin(cm):
# def m_ftin(m):
# def m_in(m):
# def m_ft(m):
# def m_yd(m):
# def m_mi(m):
# def km_mi(km):
# def sqcm_sqin(sqcm):
# def sqm_sqft(sqm):
# def sqm_sqyd(sqm):
# def sqm_ac(sqm):
# def sqm_ha(sqm):
# def sqkm_sqmi(sqkm):
# def sqin_sqcm(sqin):
# def sqft_sqm(sqft):
# def sqyd_sqm(sqyd):
# def sqmi_sqkm(sqmi):
# def sqmi_ac(sqmi):
# def sqmi_ha(sqmi):
# def ac_ha(ac):
# def ha_ac(ha):
# def l_usgal(l):
# def l_ukgal(l):
# def gal_pt(gal):
# def ukgal_l(ukgal):
# def usgal_l(usgal):
# def oz_g(ounce):
# def lb_oz(pound):
# def lb_g(pound):
# def lb_kg(pound):
# def g_oz(gram):
# def g_lb(gram):
# def kg_oz(kg):
# def kg_lb(kg):
# def ct_g(ct):
# def ct_oz(ct):
# def g_ct(g):
# def oz_ct(oz):
# def wh_cl(watt):
# def wh_j(watt_h):
# def cl_j(calorie):
# def cl_wh(calorie):
# def j_cl(joule):
# def j_wh(joule):
# def c_f(c):
# def c_k(c):
# def f_c(f):
# def f_k(f):
# def k_c(k):
# def k_f(k):
# def kw_hp(kw):
# def hp_kw(hp):
#     def __init__(self, *args):
# class MathError(ValueError):


# Path: prefs.py
from math import isfinite
from PyQt5 import QtCore, QtGui, QtWidgets
from mathfuncs import safeeval_dict
import common

            QtWidgets.QDialogButtonBox.Close,
            QtCore.Qt.Horizontal)

        self.listView.getFocus.connect(self.firstSel)
        self.listView.customContextMenuRequested.connect(self.listContextMenu)
        self.inputLine.returnPressed.connect(self.getInput)
        self.inputLine.textChanged.connect(self.statTurnBack)
        self.buttons.clicked.connect(self.close)

        constLayout = QtWidgets.QVBoxLayout()
        listLayout = QtWidgets.QVBoxLayout()
        noteLayout = QtWidgets.QVBoxLayout()
        listLayout.addWidget(self.listView)
        listLayout.addWidget(self.statBar)
        listLayout.setContentsMargins(0, 0, 0, 18)
        listLayout.setSpacing(3)
        noteLayout.addWidget(self.warnNote)
        noteLayout.addWidget(self.infoNote)
        noteLayout.setSpacing(6)
        noteLayout.setContentsMargins(0, 0, 0, 12)

        constLayout.addWidget(self.inputLine)
        constLayout.addItem(listLayout)
        constLayout.addItem(noteLayout)
        constLayout.addWidget(self.buttons)

        self.setLayout(constLayout)

        # Load Constants on init
        for c in sorted(constants):

            safeeval_dict[c] = constants[c]