qulogic/talkatu
Clone
Summary
Browse
Changes
Graph
Merged in default (pull request #28)
2019-07-19, Gary Kramlich
59e25513f093
Merged in default (pull request #28)
Remove the now deprecated talkatu_editor_{hide,show}_toolbar functions
Approved-by: Elliott Sales de Andrade
/*
* talkatu
* Copyright (C) 2017-2019 Gary Kramlich <grim@reaperworld.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* 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
* Lesser 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 <http://www.gnu.org/licenses/>.
*/
#include
<gtk/gtk.h>
#include
<talkatu/talkatuhistory.h>
#include
<talkatu/talkatumessage.h>
/**
* SECTION:talkatuhistory
* @Title: History View
* @Short_description: Chat history widget
*
* This widget is used to display the conversation history. It doesn't care if
* it is multi user or one to one.
*/
struct
_TalkatuHistory
{
TalkatuView
parent
;
};
G_DEFINE_TYPE
(
TalkatuHistory
,
talkatu_history
,
TALKATU_TYPE_VIEW
)
/******************************************************************************
* GObject Stuff
*****************************************************************************/
static
void
talkatu_history_init
(
TalkatuHistory
*
history
)
{
gtk_text_view_set_editable
(
GTK_TEXT_VIEW
(
history
),
FALSE
);
gtk_text_view_set_cursor_visible
(
GTK_TEXT_VIEW
(
history
),
FALSE
);
}
static
void
talkatu_history_class_init
(
TalkatuHistoryClass
*
klass
)
{
}
/******************************************************************************
* Public API
*****************************************************************************/
/**
* talkatu_history_new:
*
* Creates a new #TalkatuHistory for displaying chat history.
*
* Returns: (transfer full): The new #TalkatuHistory instance.
*/
GtkWidget
*
talkatu_history_new
(
void
)
{
return
GTK_WIDGET
(
g_object_new
(
TALKATU_TYPE_HISTORY
,
NULL
));
}