
/* PIKA - Photo and Image Kooker Application
 * a rebranding of The GNU Image Manipulation Program (created with heckimp)
 * A derived work which may be trivial. However, any changes may be (C)2023 by Aldercone Studio
 *
 * Original copyright, applying to most contents (license remains unchanged): 
 * Copyright (C) 1995-1997 Peter Mattis and Spencer Kimball
 *
 * pikacoreapp.h
 * Copyright (C) 2022 Lukas Oberhuber <lukaso@gmail.com>
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Library General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library.  If not, see
 * <https://www.gnu.org/licenses/>.
 */

#ifndef __PIKA_CORE_APP_H__
#define __PIKA_CORE_APP_H__

G_BEGIN_DECLS

#define PIKA_APPLICATION_ID "technology.heckin.PIKA"

enum
{
  PIKA_CORE_APP_PROP_0,
  PIKA_CORE_APP_PROP_PIKA,
  PIKA_CORE_APP_PROP_FILENAMES,
  PIKA_CORE_APP_PROP_AS_NEW,

  PIKA_CORE_APP_PROP_QUIT,
  PIKA_CORE_APP_PROP_BATCH_INTERPRETER,
  PIKA_CORE_APP_PROP_BATCH_COMMANDS,

  PIKA_CORE_APP_PROP_LAST = PIKA_CORE_APP_PROP_BATCH_COMMANDS,
};

#define PIKA_TYPE_CORE_APP pika_core_app_get_type()
G_DECLARE_INTERFACE (PikaCoreApp, pika_core_app, PIKA, CORE_APP, GObject)

struct _PikaCoreAppInterface
{
  GTypeInterface parent_iface;

  /* Padding to allow adding up to 12 new virtual functions without
   * breaking ABI. */
  gpointer padding[12];
};

Pika *             pika_core_app_get_pika              (PikaCoreApp *self);

gboolean           pika_core_app_get_quit              (PikaCoreApp *self);

gboolean           pika_core_app_get_as_new            (PikaCoreApp *self);

const gchar **     pika_core_app_get_filenames         (PikaCoreApp *self);

const gchar *      pika_core_app_get_batch_interpreter (PikaCoreApp *self);

const gchar **     pika_core_app_get_batch_commands    (PikaCoreApp *self);

void               pika_core_app_set_exit_status       (PikaCoreApp *self,
                                                        gint         exit_status);

gboolean           pika_core_app_get_exit_status       (PikaCoreApp *self);


/* Protected functions. */

void               pika_core_app_install_properties    (GObjectClass *klass);
void               pika_core_app_get_property          (GObject      *object,
                                                        guint         property_id,
                                                        GValue       *value,
                                                        GParamSpec   *pspec);
void               pika_core_app_set_property          (GObject      *object,
                                                        guint         property_id,
                                                        const GValue *value,
                                                        GParamSpec   *pspec);


G_END_DECLS

#endif /* __PIKA_CORE_APP_H__ */
