File indexing completed on 2025-01-19 12:59:16
0001 /************************************************** -*- mode:c++; -*- *** 0002 * * 0003 * This file is part of libkscan, a KDE scanning library. * 0004 * * 0005 * Copyright (C) 2013 Jonathan Marten <jjm@keelhaul.me.uk> * 0006 * * 0007 * This library is free software; you can redistribute it and/or * 0008 * modify it under the terms of the GNU Library General Public * 0009 * License as published by the Free Software Foundation and appearing * 0010 * in the file COPYING included in the packaging of this file; * 0011 * either version 2 of the License, or (at your option) any later * 0012 * version. * 0013 * * 0014 * This program is distributed in the hope that it will be useful, * 0015 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 0016 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 0017 * GNU General Public License for more details. * 0018 * * 0019 * You should have received a copy of the GNU General Public License * 0020 * along with this program; see the file COPYING. If not, write to * 0021 * the Free Software Foundation, Inc., 51 Franklin Street, * 0022 * Fifth Floor, Boston, MA 02110-1301, USA. * 0023 * * 0024 ************************************************************************/ 0025 0026 #ifndef AUTOSELECTDATA_H 0027 #define AUTOSELECTDATA_H 0028 0029 /** 0030 * This namespace collects together constants and limits for auto-selection. 0031 * 0032 * @author Jonathan Marten 0033 */ 0034 0035 namespace AutoSelectData 0036 { 0037 // Item indexes for the scanner background 0038 const int ItemIndexBlack = 0; 0039 const int ItemIndexWhite = 1; 0040 0041 // Default values for the auto-selection settings 0042 const int DefaultMargin = 0; 0043 const int DefaultThreshold = 25; 0044 const int DefaultBackground = ItemIndexWhite; 0045 const int DefaultDustsize = 5; 0046 0047 // Limits for the auto-selection settings 0048 const int MaximumMargin = 20; 0049 const int MaximumThreshold = 100; 0050 const int MaximumDustsize = 50; 0051 0052 // Configuration strings for the scanner background 0053 const char ConfigValueBlack[] = "black"; 0054 const char ConfigValueWhite[] = "white"; 0055 0056 // Configuration strings for the auto-selection state 0057 const char ConfigValueOn[] = "on"; 0058 const char ConfigValueOff[] = "off"; 0059 }; 0060 0061 #endif // AUTOSELECTDATA_H