示例#1
0
    def _add_plateau_overlay(self, lp, bounds, plateau_age, ages, age_errors,
                             info_txt):
        ov = PlateauOverlay(
            component=lp,
            plateau_bounds=bounds,
            cumulative39s=hstack(([0], self.xs)),
            info_txt=info_txt,
            id='plateau',
            ages=ages,
            age_errors=age_errors,
            line_width=self.options.plateau_line_width,
            line_color=self.options.plateau_line_color,
            extend_end_caps=self.options.extend_plateau_end_caps,
            label_visible=self.options.display_plateau_info,
            label_font_size=self.options.plateau_font_size,

            # label_offset=plateau_age.std_dev*self.options.step_nsigma,
            y=plateau_age.nominal_value * 1.25)

        lp.overlays.append(ov)

        tool = PlateauTool(component=ov)
        lp.tools.insert(0, tool)
        #plateau_label:[x, y
        ov.on_trait_change(self._handle_plateau_overlay_move, 'position[]')

        return ov
示例#2
0
    def _add_plateau_overlay(self, lp, bounds, plateau_age, ages, age_errors,
                             info_txt):
        opt = self.options

        # color = opt.get_group_color(self.group_id)
        # line_width = option.get_group(self.group_id)
        group = self.options.get_group(self.group_id)

        ov = PlateauOverlay(
            component=lp,
            plateau_bounds=bounds,
            cumulative39s=hstack(([0], self.xs)),
            info_txt=info_txt,
            id='plateau',
            ages=ages,
            age_errors=age_errors,
            line_width=group.line_width,
            line_color=group.line_color,
            # line_width=opt.plateau_line_width,
            # line_color=opt.plateau_line_color if opt.user_plateau_line_color else lp.color,
            # line_color=color,
            extend_end_caps=opt.extend_plateau_end_caps,
            label_visible=opt.display_plateau_info,
            label_font_size=opt.plateau_font_size,

            # label_offset=plateau_age.std_dev*self.options.step_nsigma,
            # y=plateau_age.nominal_value * 1.25)
            y=plateau_age.nominal_value)

        # lp.underlays.append(ov)
        lp.overlays.append(ov)
        tool = PlateauTool(component=ov)
        lp.tools.append(tool)
        # plateau_label:[x, y
        ov.on_trait_change(self._handle_plateau_overlay_move, 'position[]')
        self.plateau_overlay = ov
        return ov
示例#3
0
    def _add_plateau_overlay(self, lp, bounds, plateau_age, ages, age_errors, info_txt):
        opt = self.options

        # color = opt.get_group_color(self.group_id)
        # line_width = option.get_group(self.group_id)
        group = self.options.get_group(self.group_id)

        ov = PlateauOverlay(component=lp, plateau_bounds=bounds,
                            cumulative39s=hstack(([0], self.xs)),
                            info_txt=info_txt,
                            id='plateau',
                            ages=ages,
                            age_errors=age_errors,

                            line_width = group.line_width,
                            line_color = group.line_color,
                            # line_width=opt.plateau_line_width,
                            # line_color=opt.plateau_line_color if opt.user_plateau_line_color else lp.color,
                            # line_color=color,

                            extend_end_caps=opt.extend_plateau_end_caps,
                            label_visible=opt.display_plateau_info,
                            label_font_size=opt.plateau_font_size,

                            # label_offset=plateau_age.std_dev*self.options.step_nsigma,
                            # y=plateau_age.nominal_value * 1.25)
                            y=plateau_age.nominal_value)

        # lp.underlays.append(ov)
        lp.overlays.append(ov)
        tool = PlateauTool(component=ov)
        lp.tools.append(tool)
        # plateau_label:[x, y
        ov.on_trait_change(self._handle_plateau_overlay_move, 'position[]')
        self.plateau_overlay = ov
        return ov
示例#4
0
    def _add_plateau_overlay(self, lp, bounds, plateau_age, ages,age_errors, info_txt):
        ov = PlateauOverlay(component=lp, plateau_bounds=bounds,
                            cumulative39s=hstack(([0], self.xs)),
                            info_txt=info_txt,
                            id='plateau',
                            ages=ages,
                            age_errors=age_errors,
                            line_width=self.options.plateau_line_width,
                            line_color=self.options.plateau_line_color,
                            extend_end_caps=self.options.extend_plateau_end_caps,
                            label_visible=self.options.display_plateau_info,
                            label_font_size=self.options.plateau_font_size,

                            # label_offset=plateau_age.std_dev*self.options.step_nsigma,
                            y=plateau_age.nominal_value*1.25)

        lp.overlays.append(ov)

        tool = PlateauTool(component=ov)
        lp.tools.insert(0, tool)
        #plateau_label:[x, y
        ov.on_trait_change(self._handle_plateau_overlay_move, 'position[]')

        return ov