|
rpm-build |
9a349e |
/* This file is part of Libspectre.
|
|
rpm-build |
9a349e |
*
|
|
rpm-build |
9a349e |
* Copyright (C) 2007 Albert Astals Cid <aacid@kde.org>
|
|
rpm-build |
9a349e |
* Copyright (C) 2007 Carlos Garcia Campos <carlosgc@gnome.org>
|
|
rpm-build |
9a349e |
*
|
|
rpm-build |
9a349e |
* Libspectre is free software; you can redistribute it and/or modify
|
|
rpm-build |
9a349e |
* it under the terms of the GNU General Public License as published by
|
|
rpm-build |
9a349e |
* the Free Software Foundation; either version 2, or (at your option)
|
|
rpm-build |
9a349e |
* any later version.
|
|
rpm-build |
9a349e |
*
|
|
rpm-build |
9a349e |
* Libspectre is distributed in the hope that it will be useful,
|
|
rpm-build |
9a349e |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
rpm-build |
9a349e |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
rpm-build |
9a349e |
* GNU General Public License for more details.
|
|
rpm-build |
9a349e |
*
|
|
rpm-build |
9a349e |
* You should have received a copy of the GNU General Public License
|
|
rpm-build |
9a349e |
* along with this program; if not, write to the Free Software
|
|
rpm-build |
9a349e |
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|
rpm-build |
9a349e |
*/
|
|
rpm-build |
9a349e |
|
|
rpm-build |
9a349e |
#include "spectre-status.h"
|
|
rpm-build |
9a349e |
|
|
rpm-build |
9a349e |
const char *
|
|
rpm-build |
9a349e |
spectre_status_to_string (SpectreStatus status)
|
|
rpm-build |
9a349e |
{
|
|
rpm-build |
9a349e |
switch (status) {
|
|
rpm-build |
9a349e |
case SPECTRE_STATUS_SUCCESS:
|
|
rpm-build |
9a349e |
return "success";
|
|
rpm-build |
9a349e |
case SPECTRE_STATUS_NO_MEMORY:
|
|
rpm-build |
9a349e |
return "out of memory";
|
|
rpm-build |
9a349e |
case SPECTRE_STATUS_LOAD_ERROR:
|
|
rpm-build |
9a349e |
return "error loading document";
|
|
rpm-build |
9a349e |
case SPECTRE_STATUS_DOCUMENT_NOT_LOADED:
|
|
rpm-build |
9a349e |
return "document is not loaded";
|
|
rpm-build |
9a349e |
case SPECTRE_STATUS_INVALID_PAGE:
|
|
rpm-build |
9a349e |
return "page is invalid";
|
|
rpm-build |
9a349e |
case SPECTRE_STATUS_RENDER_ERROR:
|
|
rpm-build |
9a349e |
return "render error";
|
|
rpm-build |
9a349e |
case SPECTRE_STATUS_EXPORTER_ERROR:
|
|
rpm-build |
9a349e |
return "exporter error";
|
|
rpm-build |
9a349e |
case SPECTRE_STATUS_SAVE_ERROR:
|
|
rpm-build |
9a349e |
return "save error";
|
|
rpm-build |
9a349e |
}
|
|
rpm-build |
9a349e |
|
|
rpm-build |
9a349e |
return "unknown error status";
|
|
rpm-build |
9a349e |
}
|