You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

72 lines
2.8 KiB

  1. /*
  2. * This program source code file is part of KiCad, a free EDA CAD application.
  3. *
  4. * Copyright (C) 2007 KiCad Developers, see change_log.txt for contributors.
  5. *
  6. * This program is free software; you can redistribute it and/or
  7. * modify it under the terms of the GNU General Public License
  8. * as published by the Free Software Foundation; either version 2
  9. * of the License, or (at your option) any later version.
  10. *
  11. * This program is distributed in the hope that it will be useful,
  12. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. * GNU General Public License for more details.
  15. *
  16. * You should have received a copy of the GNU General Public License
  17. * along with this program; if not, you may find one here:
  18. * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
  19. * or you may search the http://www.gnu.org website for the version 2 license,
  20. * or you may write to the Free Software Foundation, Inc.,
  21. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
  22. */
  23. /******************************************************************/
  24. /* class_drc_erc_item.cpp - DRC_ITEM class functions for eeschema */
  25. /******************************************************************/
  26. #include <fctsys.h>
  27. #include <common.h>
  28. #include <class_drc_item.h>
  29. #include <erc.h>
  30. #include <base_units.h>
  31. wxString DRC_ITEM::GetErrorText() const
  32. {
  33. switch( m_ErrorCode )
  34. {
  35. case ERCE_UNSPECIFIED:
  36. return wxString( _("ERC err unspecified") );
  37. case ERCE_DUPLICATE_SHEET_NAME:
  38. return wxString( _("Duplicate sheet names within a given sheet") );
  39. case ERCE_PIN_NOT_CONNECTED:
  40. return wxString( _("Pin not connected (and no connect symbol found on this pin)") );
  41. case ERCE_PIN_NOT_DRIVEN:
  42. return wxString( _("Pin connected to some others pins but no pin to drive it") );
  43. case ERCE_PIN_TO_PIN_WARNING:
  44. return wxString( _("Conflict problem between pins. Severity: warning") );
  45. case ERCE_PIN_TO_PIN_ERROR:
  46. return wxString( _("Conflict problem between pins. Severity: error") );
  47. case ERCE_HIERACHICAL_LABEL:
  48. return wxString( _("Mismatch between hierarchical labels and pins sheets"));
  49. case ERCE_NOCONNECT_CONNECTED:
  50. return wxString( _("A no connect symbol is connected to more than 1 pin"));
  51. case ERCE_GLOBLABEL:
  52. return wxString( _("Global label not connected to any other global label") );
  53. case ERCE_SIMILAR_LABELS:
  54. return wxString( _("Labels are similar (lower/upper case difference only)") );
  55. case ERCE_SIMILAR_GLBL_LABELS:
  56. return wxString( _("Global labels are similar (lower/upper case difference only)") );
  57. default:
  58. return wxString( wxT("Unkown.") );
  59. }
  60. }
  61. wxString DRC_ITEM::ShowCoord( const wxPoint& aPos )
  62. {
  63. wxString ret;
  64. ret << aPos;
  65. return ret;
  66. }