<commit_before>from __future__ import division

from PySide import QtGui, QtCore
import numpy as np
import FreeCAD as App

from ._tools import BaseTool, input_field, text_field, coin
from .pivy_primitives_new_new import Line, Marker, Container, vector3D


def refresh():
    pass


# idea: draw lines between ribs and fill the panels with color
# only straight lines, no curves
# later create some helpers to generate parametric cuts

# TODO

# switch upper lower      x
# add new line            
# save to dict            x
# set cut type
# q set position
# delete                  x


class DesignTool(BaseTool):
    widget_name = "Design Tool"
    def __init__(self, obj):
        super(DesignTool, self).__init__(obj)
        self.side = "upper"

        # get 2d shape properties
        _shape = self.ParametricGlider.shape.get_shape()
        self.front = list(map(vector3D, _shape.front))
        self.back = list(map(vector3D, _shape.back))
        self.ribs = zip(self.front, self.back)
        CutLine.cuts_to_lines(self.ParametricGlider)

        self._add_mode = False
        # setup the GUI
        self.setup_widget()
        self.setup_pivy()

    def setup_widget(self):
        """set up the qt stuff"""
        self.Qtoggle_side = QtGui.QPushButton("show lower side")
        self.layout.setWidget(0, input_field, self.Qtoggle_side)
<commit_msg>update todo<commit_after>from __future__ import division

from PySide import QtGui, QtCore
import numpy as np
import FreeCAD as App

from ._tools import BaseTool, input_field, text_field, coin
from .pivy_primitives_new_new import Line, Marker, Container, vector3D


def refresh():
    pass


# idea: draw lines between ribs and fill the panels with color
# only straight lines, no curves
# later create some helpers to generate parametric cuts

# TODO

# switch upper lower        x
# add new line              x
# add new point             
# create line of two nodes
# save to dict              x
# set cut type              x
# q set position            x
# delete                    x


class DesignTool(BaseTool):
    widget_name = "Design Tool"
    def __init__(self, obj):
        super(DesignTool, self).__init__(obj)
        self.side = "upper"

        # get 2d shape properties
        _shape = self.ParametricGlider.shape.get_shape()
        self.front = list(map(vector3D, _shape.front))
        self.back = list(map(vector3D, _shape.back))
        self.ribs = zip(self.front, self.back)
        CutLine.cuts_to_lines(self.ParametricGlider)

        self._add_mode = False
        # setup the GUI
        self.setup_widget()
        self.setup_pivy()

    def setup_widget(self):
        """set up the qt stuff"""
        self.Qtoggle_side = QtGui.QPushButton("show lower side")
        self.layout.setWidget(0, input_field, self.Qtoggle_side)

{'fraction_non_alphanumeric': 0.08076514346439957, 'fraction_numerical': 0.003542330853701736, 'mean_word_length': 2.579214195183777, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7131604', 'n_tokens_mistral': 862, 'n_tokens_neox': 833, 'n_words': 266}