KiCad PCB EDA Suite
dialog_plot.cpp File Reference
#include <kiface_i.h>
#include <plotter.h>
#include <confirm.h>
#include <pcb_edit_frame.h>
#include <pcbplot.h>
#include <gerber_jobfile_writer.h>
#include <base_units.h>
#include <macros.h>
#include <reporter.h>
#include <wildcards_and_files_ext.h>
#include <bitmaps.h>
#include <class_board.h>
#include <wx/ffile.h>
#include <dialog_plot.h>
#include <wx_html_report_panel.h>
#include <drc.h>
#include <layers_id_colors_and_visibility.h>

Go to the source code of this file.

Functions

static bool setDouble (double *aResult, double aValue, double aMin, double aMax)
 
static bool setInt (int *aResult, int aValue, int aMin, int aMax)
 

Function Documentation

static bool setDouble ( double *  aResult,
double  aValue,
double  aMin,
double  aMax 
)
static

Definition at line 549 of file dialog_plot.cpp.

Referenced by DIALOG_PLOT::applyPlotSettings().

550 {
551  if( aValue < aMin )
552  {
553  *aResult = aMin;
554  return false;
555  }
556  else if( aValue > aMax )
557  {
558  *aResult = aMax;
559  return false;
560  }
561 
562  *aResult = aValue;
563  return true;
564 }
static bool setInt ( int *  aResult,
int  aValue,
int  aMin,
int  aMax 
)
static

Definition at line 567 of file dialog_plot.cpp.

Referenced by DIALOG_PLOT::applyPlotSettings().

568 {
569  if( aValue < aMin )
570  {
571  *aResult = aMin;
572  return false;
573  }
574  else if( aValue > aMax )
575  {
576  *aResult = aMax;
577  return false;
578  }
579 
580  *aResult = aValue;
581  return true;
582 }