]> git.ipfire.org Git - thirdparty/cups-filters.git/commitdiff
libcupsfilters: Removed kmdevices.* (Kolor Manager/Oyranos interface)
authorTill Kamppeter <till.kamppeter@gmail.com>
Tue, 5 Apr 2022 21:09:06 +0000 (23:09 +0200)
committerTill Kamppeter <till.kamppeter@gmail.com>
Tue, 5 Apr 2022 21:09:06 +0000 (23:09 +0200)
The files cupsfilters/kmdevices.h and cupsfilters/kmdevices.cpp form
an interface for Kolor Manager, a KDE system settings component for
color management with Oyranos.

Kolor Manager is unmaintained for several years, same for Oyranos. The
kmdevices.* are not included in the build of libcupsfilters, only
shipped for optional use (requires uncommenting a line in
colormanager.c) and no one complained about their non-inclusion in the
build. They even contain a typo which would prevent them from
building. So one can assume that no one cares about them.

Therefore they get removed now, before the cups-filters 2.x release.

Makefile.am
cupsfilters/colormanager.c
cupsfilters/kmdevices.cpp [deleted file]
cupsfilters/kmdevices.h [deleted file]

index 46407257e28fa81b7d5f8c161104e27095dbbc65..133f0ef8372b21b770736d3fe61c194ce10781d0 100644 (file)
@@ -29,8 +29,6 @@ EXTRA_DIST = \
        filter/braille/filters/TODO.txt
 
 EXTRA_DIST += \
-       cupsfilters/kmdevices.cpp \
-       cupsfilters/kmdevices.h \
        cupsfilters/testdriver.c \
        data/makePDFfromPS.sh \
        data/classified.ps \
index c06c1a39e5786c32efa73aff63c104539ec6c602..a1ff5aa520ed79a8af72bbf3181e975077e09a6e 100644 (file)
@@ -29,7 +29,6 @@ MIT Open Source License  -  http://www.opensource.org/
 #include "colormanager.h"
 #include <cupsfilters/colord.h>
 #include <cupsfilters/filter.h>
-//#include <cupsfilters/kmdevices.h>
 
 
 #define CM_MAX_FILE_LENGTH 1024
diff --git a/cupsfilters/kmdevices.cpp b/cupsfilters/kmdevices.cpp
deleted file mode 100644 (file)
index 15ccde8..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-#include <oyranos.h>
-#include <oyranos_icc.h>
-#include <oyranos_devices.h>
-#include <oyProfiles_s.h>
-#include <oyObject_s.h>
-
-oyConfig_s * get_device(const char * printer_name)
-{
-  oyConfig_s * device = 0;
-  oyOptions_s * options = 0;
-
-  oyOptions_SetFromText( &options, "//" OY_TYPE_STD "/config/command",
-                         "properties", OY_CREATE_NEW );
-  oyOptions_SetFromText( &options,
-                   "//"OY_TYPE_STD"/config/icc_profile.x_color_region_target",
-                         "yes", OY_CREATE_NEW );
-
-  oyDeviceGet( OY_TYPE_STD, "PRINTER", printer_name,
-               options, &device );
-  
-  oyOptions_Release(&options);
-
-  return device;
-}
-
-int kmIsPrinterCmOff(const char * printer_name)
-{
-  int state = 0;
-  oyConfig_s * device = 0;
-  const char* str = 0;
-
-  // Disable CM if invalid
-  if(printer_name == NULL)
-    return 1;
-
-  device = get_device(printer_name);
-
-  if (error) 
-    state = 1;
-  else {
-    str = oyConfig_FindString(device, "CM_State", 0);   
-    if (!strcmp(str, "Disabled"))
-      state = 1;
-  }
-
-  return state;
-}
-
-const char * kmGetPrinterProfile(const char* printer_name)
-{
-  int state = 0;
-  oyConfig_s * device = 0;
-  oyProfile_s * profile = 0;
-  const char* profile_filepath = 0;
-
-  if(printer_name == NULL)
-    return 0;
-
-  device = get_device(printer_name);
-
-  if (device != NULL)
-    profile_filepath = oyGetDeviceProfile( device, options, profile );
-
-  return profile_filepath;
-}
diff --git a/cupsfilters/kmdevices.h b/cupsfilters/kmdevices.h
deleted file mode 100644 (file)
index 9260e68..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
-Copyright (C) 2014 Joseph Simon <jsimon383@gmail.com>
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions
-are met:
-
-1. Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-2. Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
-
-THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
-IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
-OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
-IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
-NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
-THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-*/
-
-/* Interface for Kolor Manager */
-
-/* Get color management state of a printer */
-int kmIsPrinterCMOff(const char * /*printer_name*/);
-
-/* Get profile from color manager */
-const char * kmGetPrinterProfile(const char* /*printer_name*/);