mirror of
https://github.com/deltachat/deltachat-core.git
synced 2025-10-04 10:19:16 +02:00
876 lines
53 KiB
HTML
876 lines
53 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
<meta name="generator" content="Doxygen 1.8.11"/>
|
|
<title>Delta Chat Core C-API: mrmsg_t Struct Reference</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<script type="text/javascript" src="dynsections.js"></script>
|
|
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
<script type="text/javascript" src="search/search.js"></script>
|
|
<script type="text/javascript">
|
|
$(document).ready(function() { init_search(); });
|
|
</script>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
<link href="user.css" rel="stylesheet" type="text/css"/>
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr style="height: 56px;">
|
|
<td id="projectalign" style="padding-left: 0.5em;">
|
|
<div id="projectname">Delta Chat Core C-API
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.8.11 -->
|
|
<script type="text/javascript">
|
|
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
</script>
|
|
<div id="navrow1" class="tabs">
|
|
<ul class="tablist">
|
|
<li><a href="index.html"><span>Main Page</span></a></li>
|
|
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
|
|
<li><a href="files.html"><span>Files</span></a></li>
|
|
<li>
|
|
<div id="MSearchBox" class="MSearchBoxInactive">
|
|
<span class="left">
|
|
<img id="MSearchSelect" src="search/mag_sel.png"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
alt=""/>
|
|
<input type="text" id="MSearchField" value="Search" accesskey="S"
|
|
onfocus="searchBox.OnSearchFieldFocus(true)"
|
|
onblur="searchBox.OnSearchFieldFocus(false)"
|
|
onkeyup="searchBox.OnSearchFieldChange(event)"/>
|
|
</span><span class="right">
|
|
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
|
|
</span>
|
|
</div>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div id="navrow2" class="tabs2">
|
|
<ul class="tablist">
|
|
<li><a href="annotated.html"><span>Class List</span></a></li>
|
|
<li><a href="functions.html"><span>Class Members</span></a></li>
|
|
</ul>
|
|
</div>
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
</div>
|
|
|
|
<!-- iframe showing the search results (closed by default) -->
|
|
<div id="MSearchResultsWindow">
|
|
<iframe src="javascript:void(0)" frameborder="0"
|
|
name="MSearchResults" id="MSearchResults">
|
|
</iframe>
|
|
</div>
|
|
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="summary">
|
|
<a href="#pub-methods">Public Member Functions</a> |
|
|
<a href="#pub-attribs">Public Attributes</a> |
|
|
<a href="structmrmsg__t-members.html">List of all members</a> </div>
|
|
<div class="headertitle">
|
|
<div class="title">mrmsg_t Struct Reference</div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
|
|
<p>An object representing a single message in memory.
|
|
<a href="structmrmsg__t.html#details">More...</a></p>
|
|
|
|
<p><code>#include <<a class="el" href="mrmsg_8h_source.html">mrmsg.h</a>></code></p>
|
|
<table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
|
|
Public Member Functions</h2></td></tr>
|
|
<tr class="memitem:aa33212e41efff643aa7290753f3d9b02"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#aa33212e41efff643aa7290753f3d9b02">mrmsg_unref</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:aa33212e41efff643aa7290753f3d9b02"><td class="mdescLeft"> </td><td class="mdescRight">Free a message object. <a href="#aa33212e41efff643aa7290753f3d9b02">More...</a><br /></td></tr>
|
|
<tr class="separator:aa33212e41efff643aa7290753f3d9b02"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a705454903b36ded8c3cd43a2044de60a"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a705454903b36ded8c3cd43a2044de60a">mrmsg_get_type</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:a705454903b36ded8c3cd43a2044de60a"><td class="mdescLeft"> </td><td class="mdescRight">Get the type of the message. <a href="#a705454903b36ded8c3cd43a2044de60a">More...</a><br /></td></tr>
|
|
<tr class="separator:a705454903b36ded8c3cd43a2044de60a"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a1f411e4be17fb5fe408a1aa74cba90a5"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a1f411e4be17fb5fe408a1aa74cba90a5">mrmsg_get_state</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:a1f411e4be17fb5fe408a1aa74cba90a5"><td class="mdescLeft"> </td><td class="mdescRight">Get the state of a message. <a href="#a1f411e4be17fb5fe408a1aa74cba90a5">More...</a><br /></td></tr>
|
|
<tr class="separator:a1f411e4be17fb5fe408a1aa74cba90a5"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:af5bf52ee1adbc55c9c9d4699afee87fb"><td class="memItemLeft" align="right" valign="top">time_t </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#af5bf52ee1adbc55c9c9d4699afee87fb">mrmsg_get_timestamp</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:af5bf52ee1adbc55c9c9d4699afee87fb"><td class="mdescLeft"> </td><td class="mdescRight">Get message time. <a href="#af5bf52ee1adbc55c9c9d4699afee87fb">More...</a><br /></td></tr>
|
|
<tr class="separator:af5bf52ee1adbc55c9c9d4699afee87fb"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ae549e58d9ae2f73ad76bd27636b43982"><td class="memItemLeft" align="right" valign="top">char * </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#ae549e58d9ae2f73ad76bd27636b43982">mrmsg_get_text</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:ae549e58d9ae2f73ad76bd27636b43982"><td class="mdescLeft"> </td><td class="mdescRight">Get the text of the message. <a href="#ae549e58d9ae2f73ad76bd27636b43982">More...</a><br /></td></tr>
|
|
<tr class="separator:ae549e58d9ae2f73ad76bd27636b43982"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a2544769c77af5447546fcf5fc95c64f7"><td class="memItemLeft" align="right" valign="top">char * </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a2544769c77af5447546fcf5fc95c64f7">mrmsg_get_file</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:a2544769c77af5447546fcf5fc95c64f7"><td class="mdescLeft"> </td><td class="mdescRight">Find out full path, file name and extension of the file associated with a message. <a href="#a2544769c77af5447546fcf5fc95c64f7">More...</a><br /></td></tr>
|
|
<tr class="separator:a2544769c77af5447546fcf5fc95c64f7"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ad0dcfc0a1e33d9a88b7381e368d7895a"><td class="memItemLeft" align="right" valign="top">char * </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#ad0dcfc0a1e33d9a88b7381e368d7895a">mrmsg_get_filename</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:ad0dcfc0a1e33d9a88b7381e368d7895a"><td class="mdescLeft"> </td><td class="mdescRight">Get base file name without path. <a href="#ad0dcfc0a1e33d9a88b7381e368d7895a">More...</a><br /></td></tr>
|
|
<tr class="separator:ad0dcfc0a1e33d9a88b7381e368d7895a"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a4afcbb38dd1f37fb5f7b2c6d1f4e9042"><td class="memItemLeft" align="right" valign="top">char * </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a4afcbb38dd1f37fb5f7b2c6d1f4e9042">mrmsg_get_filemime</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:a4afcbb38dd1f37fb5f7b2c6d1f4e9042"><td class="mdescLeft"> </td><td class="mdescRight">Get mime type of the file. <a href="#a4afcbb38dd1f37fb5f7b2c6d1f4e9042">More...</a><br /></td></tr>
|
|
<tr class="separator:a4afcbb38dd1f37fb5f7b2c6d1f4e9042"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:afd11616dcf572662561829c0f48ca713"><td class="memItemLeft" align="right" valign="top">uint64_t </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#afd11616dcf572662561829c0f48ca713">mrmsg_get_filebytes</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:afd11616dcf572662561829c0f48ca713"><td class="mdescLeft"> </td><td class="mdescRight">Get the size of the file. <a href="#afd11616dcf572662561829c0f48ca713">More...</a><br /></td></tr>
|
|
<tr class="separator:afd11616dcf572662561829c0f48ca713"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ad87b7df007489b3a47c3fde79978a58a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structmrpoortext__t.html">mrpoortext_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#ad87b7df007489b3a47c3fde79978a58a">mrmsg_get_mediainfo</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:ad87b7df007489b3a47c3fde79978a58a"><td class="mdescLeft"> </td><td class="mdescRight">Get real author and title. <a href="#ad87b7df007489b3a47c3fde79978a58a">More...</a><br /></td></tr>
|
|
<tr class="separator:ad87b7df007489b3a47c3fde79978a58a"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:adfe10086430b562b8df4e45668b51927"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#adfe10086430b562b8df4e45668b51927">mrmsg_get_width</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:adfe10086430b562b8df4e45668b51927"><td class="mdescLeft"> </td><td class="mdescRight">Get width of image or video. <a href="#adfe10086430b562b8df4e45668b51927">More...</a><br /></td></tr>
|
|
<tr class="separator:adfe10086430b562b8df4e45668b51927"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a8600ed157b44b1089783e66ce7b33353"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a8600ed157b44b1089783e66ce7b33353">mrmsg_get_height</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:a8600ed157b44b1089783e66ce7b33353"><td class="mdescLeft"> </td><td class="mdescRight">Get height of image or video. <a href="#a8600ed157b44b1089783e66ce7b33353">More...</a><br /></td></tr>
|
|
<tr class="separator:a8600ed157b44b1089783e66ce7b33353"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:aa180c0fd4c9cdd58cc47006022ebc1e0"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#aa180c0fd4c9cdd58cc47006022ebc1e0">mrmsg_get_duration</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:aa180c0fd4c9cdd58cc47006022ebc1e0"><td class="mdescLeft"> </td><td class="mdescRight">Get duration of audio or video. <a href="#aa180c0fd4c9cdd58cc47006022ebc1e0">More...</a><br /></td></tr>
|
|
<tr class="separator:aa180c0fd4c9cdd58cc47006022ebc1e0"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a7f1bd3d845bbc5face7636aed8f8afd4"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a7f1bd3d845bbc5face7636aed8f8afd4">mrmsg_get_showpadlock</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:a7f1bd3d845bbc5face7636aed8f8afd4"><td class="mdescLeft"> </td><td class="mdescRight">Check if a padlock should be shown beside the message. <a href="#a7f1bd3d845bbc5face7636aed8f8afd4">More...</a><br /></td></tr>
|
|
<tr class="separator:a7f1bd3d845bbc5face7636aed8f8afd4"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:afc3d94448ada0ad7142cf168cab1462e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structmrpoortext__t.html">mrpoortext_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#afc3d94448ada0ad7142cf168cab1462e">mrmsg_get_summary</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg, <a class="el" href="structmrchat__t.html">mrchat_t</a> *chat)</td></tr>
|
|
<tr class="memdesc:afc3d94448ada0ad7142cf168cab1462e"><td class="mdescLeft"> </td><td class="mdescRight">Get a summary for a message. <a href="#afc3d94448ada0ad7142cf168cab1462e">More...</a><br /></td></tr>
|
|
<tr class="separator:afc3d94448ada0ad7142cf168cab1462e"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a8c8c1f342f01439ae40c5cf37532387e"><td class="memItemLeft" align="right" valign="top">char * </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a8c8c1f342f01439ae40c5cf37532387e">mrmsg_get_summarytext</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg, int approx_characters)</td></tr>
|
|
<tr class="memdesc:a8c8c1f342f01439ae40c5cf37532387e"><td class="mdescLeft"> </td><td class="mdescRight">Get a message summary as a single line of text. <a href="#a8c8c1f342f01439ae40c5cf37532387e">More...</a><br /></td></tr>
|
|
<tr class="separator:a8c8c1f342f01439ae40c5cf37532387e"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:af202a7e7527df4681cd3ea24f779848f"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#af202a7e7527df4681cd3ea24f779848f">mrmsg_is_starred</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:af202a7e7527df4681cd3ea24f779848f"><td class="mdescLeft"> </td><td class="mdescRight">Check if a message is starred. <a href="#af202a7e7527df4681cd3ea24f779848f">More...</a><br /></td></tr>
|
|
<tr class="separator:af202a7e7527df4681cd3ea24f779848f"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a3256ed8c6a55a6c1a30e0fce33b85421"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a3256ed8c6a55a6c1a30e0fce33b85421">mrmsg_is_forwarded</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:a3256ed8c6a55a6c1a30e0fce33b85421"><td class="mdescLeft"> </td><td class="mdescRight">Check if the message is a forwarded message. <a href="#a3256ed8c6a55a6c1a30e0fce33b85421">More...</a><br /></td></tr>
|
|
<tr class="separator:a3256ed8c6a55a6c1a30e0fce33b85421"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a752209192e3a022d087fe6c647fb3ad9"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a752209192e3a022d087fe6c647fb3ad9">mrmsg_is_systemcmd</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:a752209192e3a022d087fe6c647fb3ad9"><td class="mdescLeft"> </td><td class="mdescRight">Check if the message is a system command. <a href="#a752209192e3a022d087fe6c647fb3ad9">More...</a><br /></td></tr>
|
|
<tr class="separator:a752209192e3a022d087fe6c647fb3ad9"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a32d23bac4bf35ed5f8c2cfbb93d636f5"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a32d23bac4bf35ed5f8c2cfbb93d636f5">mrmsg_is_increation</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg)</td></tr>
|
|
<tr class="memdesc:a32d23bac4bf35ed5f8c2cfbb93d636f5"><td class="mdescLeft"> </td><td class="mdescRight">Check if a message is still in creation. <a href="#a32d23bac4bf35ed5f8c2cfbb93d636f5">More...</a><br /></td></tr>
|
|
<tr class="separator:a32d23bac4bf35ed5f8c2cfbb93d636f5"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a9e5dc81d4e814284b465ad23abbfb6cb"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a9e5dc81d4e814284b465ad23abbfb6cb">mrmsg_latefiling_mediasize</a> (<a class="el" href="structmrmsg__t.html">mrmsg_t</a> *msg, int width, int height, int duration)</td></tr>
|
|
<tr class="memdesc:a9e5dc81d4e814284b465ad23abbfb6cb"><td class="mdescLeft"> </td><td class="mdescRight">Late filing information to a message. <a href="#a9e5dc81d4e814284b465ad23abbfb6cb">More...</a><br /></td></tr>
|
|
<tr class="separator:a9e5dc81d4e814284b465ad23abbfb6cb"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-attribs"></a>
|
|
Public Attributes</h2></td></tr>
|
|
<tr class="memitem:a793898c8da24c717dc2bb1d91faac801"><td class="memItemLeft" align="right" valign="top">uint32_t </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a793898c8da24c717dc2bb1d91faac801">m_id</a></td></tr>
|
|
<tr class="memdesc:a793898c8da24c717dc2bb1d91faac801"><td class="mdescLeft"> </td><td class="mdescRight">Message ID. <a href="#a793898c8da24c717dc2bb1d91faac801">More...</a><br /></td></tr>
|
|
<tr class="separator:a793898c8da24c717dc2bb1d91faac801"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a299981cb89b25ebaaedf7a8486a86ee6"><td class="memItemLeft" align="right" valign="top">uint32_t </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#a299981cb89b25ebaaedf7a8486a86ee6">m_from_id</a></td></tr>
|
|
<tr class="memdesc:a299981cb89b25ebaaedf7a8486a86ee6"><td class="mdescLeft"> </td><td class="mdescRight">Contact ID of the sender. <a href="#a299981cb89b25ebaaedf7a8486a86ee6">More...</a><br /></td></tr>
|
|
<tr class="separator:a299981cb89b25ebaaedf7a8486a86ee6"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ad549fc02587ba284fda2bbecd162b16a"><td class="memItemLeft" align="right" valign="top">uint32_t </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#ad549fc02587ba284fda2bbecd162b16a">m_to_id</a></td></tr>
|
|
<tr class="memdesc:ad549fc02587ba284fda2bbecd162b16a"><td class="mdescLeft"> </td><td class="mdescRight">Contact ID of the recipient. <a href="#ad549fc02587ba284fda2bbecd162b16a">More...</a><br /></td></tr>
|
|
<tr class="separator:ad549fc02587ba284fda2bbecd162b16a"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ac19bdc40e452c8997dd58474a7be6880"><td class="memItemLeft" align="right" valign="top">uint32_t </td><td class="memItemRight" valign="bottom"><a class="el" href="structmrmsg__t.html#ac19bdc40e452c8997dd58474a7be6880">m_chat_id</a></td></tr>
|
|
<tr class="memdesc:ac19bdc40e452c8997dd58474a7be6880"><td class="mdescLeft"> </td><td class="mdescRight">Chat ID the message belongs to. <a href="#ac19bdc40e452c8997dd58474a7be6880">More...</a><br /></td></tr>
|
|
<tr class="separator:ac19bdc40e452c8997dd58474a7be6880"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table>
|
|
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
|
<div class="textblock"><p>An object representing a single message in memory. </p>
|
|
<p>The message object is not updated. If you want an update, you have to recreate the object. </p>
|
|
</div><h2 class="groupheader">Member Function Documentation</h2>
|
|
<a class="anchor" id="aa33212e41efff643aa7290753f3d9b02"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void mrmsg_unref </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Free a message object. </p>
|
|
<p>Message objects are created eg. by <a class="el" href="structmrmailbox__t.html#a9ef144244e7d86ba82ce3257abf14f13" title="Get a single message object of the type mrmsg_t. ">mrmailbox_get_msg()</a>.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object to free.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>None. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a705454903b36ded8c3cd43a2044de60a"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int mrmsg_get_type </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get the type of the message. </p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>One of MR_MSG_TEXT (10), MR_MSG_IMAGE (20), MR_MSG_GIF (21), MR_MSG_AUDIO (40), MR_MSG_VOICE (41), MR_MSG_VIDEO (50), MR_MSG_FILE (60) or MR_MSG_UNDEFINED (0) if the type is undefined. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a1f411e4be17fb5fe408a1aa74cba90a5"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int mrmsg_get_state </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get the state of a message. </p>
|
|
<p>Incoming message states:</p><ul>
|
|
<li>MR_STATE_IN_FRESH (10) - Incoming <em>fresh</em> message. Fresh messages are not noticed nor seen and are typically shown in notifications. Use <a class="el" href="structmrmailbox__t.html#a65215149290bec16b173106269b08e5e" title="Returns the message IDs of all fresh messages of any chat. ">mrmailbox_get_fresh_msgs()</a> to get all fresh messages.</li>
|
|
<li>MR_STATE_IN_NOTICED (13) - Incoming <em>noticed</em> message. Eg. chat opened but message not yet read - noticed messages are not counted as unread but did not marked as read nor resulted in MDNs. Use <a class="el" href="structmrmailbox__t.html#a07cc8fe0cfd900a9449bffc4ca5a7a95" title="Mark all message in a chat as noticed. ">mrmailbox_marknoticed_chat()</a> or <a class="el" href="structmrmailbox__t.html#a7150c575193d43e048689aa264c74c79" title="Mark all messages send by the given contact as noticed. ">mrmailbox_marknoticed_contact()</a> to mark messages as being noticed.</li>
|
|
<li>MR_STATE_IN_SEEN (16) - Incoming message, really <em>seen</em> by the user. Marked as read on IMAP and MDN may be send. Use <a class="el" href="structmrmailbox__t.html#a67281e50b568dc18df710275e0e13f5b" title="Mark a message as seen, updates the IMAP state and sends MDNs. ">mrmailbox_markseen_msgs()</a> to mark messages as being seen.</li>
|
|
</ul>
|
|
<p>Outgoing message states:</p><ul>
|
|
<li>MR_STATE_OUT_PENDING (20) - The user has send the "send" button but the message is not yet sent and is pending in some way. Maybe we're offline (no checkmark).</li>
|
|
<li>MR_STATE_OUT_ERROR (24) - <em>Unrecoverable</em> error (<em>recoverable</em> errors result in pending messages)</li>
|
|
<li>MR_STATE_OUT_DELIVERED (26) - Outgoing message successfully delivered to server (one checkmark). Note, that already delivered messages may get into the state MR_STATE_OUT_ERROR if we get such a hint from the server. If a sent message changes to this state, you'll receive the event <a class="el" href="mrevent_8h.html#a10c4a8b6fa9014e5725e3a1daadf301b" title="A single message is send successfully (state changed from MR_STATE_OUT_PENDING to MR_STATE_OUT_DELIVE...">MR_EVENT_MSG_DELIVERED</a>.</li>
|
|
<li>MR_STATE_OUT_MDN_RCVD (28) - Outgoing message read by the recipient (two checkmarks; this requires goodwill on the receiver's side) If a sent message changes to this state, you'll receive the event <a class="el" href="mrevent_8h.html#a080965cf1f3dd138999c56ec30580b58" title="A single message is read by the receiver (state changed from MR_STATE_OUT_DELIVERED to MR_STATE_OUT_M...">MR_EVENT_MSG_READ</a>.</li>
|
|
</ul>
|
|
<p>The state of just created message objects is MR_STATE_UNDEFINED (0). The state is always set by the core-library, users of the library cannot set the state directly, but it is changed implicitly eg. when calling <a class="el" href="structmrmailbox__t.html#a07cc8fe0cfd900a9449bffc4ca5a7a95" title="Mark all message in a chat as noticed. ">mrmailbox_marknoticed_chat()</a> or <a class="el" href="structmrmailbox__t.html#a67281e50b568dc18df710275e0e13f5b" title="Mark a message as seen, updates the IMAP state and sends MDNs. ">mrmailbox_markseen_msgs()</a>.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>The state of the message. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="af5bf52ee1adbc55c9c9d4699afee87fb"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">time_t mrmsg_get_timestamp </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get message time. </p>
|
|
<p>Unix time the message was sended or received.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>The time of the message. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="ae549e58d9ae2f73ad76bd27636b43982"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">char * mrmsg_get_text </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get the text of the message. </p>
|
|
<p>If there is no text associalted with the message, an empty string is returned. NULL is never returned.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>Message text. The result must be free()'d. Never returns NULL. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a2544769c77af5447546fcf5fc95c64f7"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">char * mrmsg_get_file </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Find out full path, file name and extension of the file associated with a message. </p>
|
|
<p>Typically files are associated with images, videos, audios, documents. Plain text messages do not have a file.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>Full path, file name and extension of the file associated with the message. If there is no file associated with the message, an emtpy string is returned. NULL is never returned and the returned value must be free()'d. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="ad0dcfc0a1e33d9a88b7381e368d7895a"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">char * mrmsg_get_filename </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get base file name without path. </p>
|
|
<p>The base file name includes the extension; the path is not returned. To get the full path, use <a class="el" href="structmrmsg__t.html#a2544769c77af5447546fcf5fc95c64f7" title="Find out full path, file name and extension of the file associated with a message. ">mrmsg_get_file()</a>.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>Base file name plus extension without part. If there is no file associated with the message, an empty string is returned. The returned value must be free()'d. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a4afcbb38dd1f37fb5f7b2c6d1f4e9042"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">char * mrmsg_get_filemime </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get mime type of the file. </p>
|
|
<p>If there is not file, an empty string is returned. If there is no associated mime type with the file, the function guesses on; if in doubt, <code>application/octet-stream</code> is returned. NULL is never returned.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>String containing the mime type. Must be free()'d after usage. NULL is never returned. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="afd11616dcf572662561829c0f48ca713"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">uint64_t mrmsg_get_filebytes </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get the size of the file. </p>
|
|
<p>Returns the size of the file associated with a message, if applicable.</p>
|
|
<p>Typically, this is used to show the size of document messages, eg. a PDF.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>File size in bytes, 0 if not applicable or on errors. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="ad87b7df007489b3a47c3fde79978a58a"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="structmrpoortext__t.html">mrpoortext_t</a> * mrmsg_get_mediainfo </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get real author and title. </p>
|
|
<ul>
|
|
<li>For voice messages, the author is the sender and the trackname is the sending time.</li>
|
|
<li>For music messages and videos, we read the information from the filename (we do not read ID3 and such at this stage, the needed libraries are too complicated and oversized. However, this is no big problem, as the sender usually sets the filename in a way we expect it)</li>
|
|
</ul>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="structmrpoortext__t.html" title="An object representing text with some attributes. ">mrpoortext_t</a> object that contains the author as <a class="el" href="structmrpoortext__t.html#af3b56661ccf1c783f397c15c310cf36f" title="The meaning is defined by m_text1_meaning and by the creator of the object. ">mrpoortext_t::m_text1</a> and the title as <a class="el" href="structmrpoortext__t.html#a54e10365f38dddd070a2ab68f4177331" title="The meaning is defined by the creator of the object. ">mrpoortext_t::m_text2</a>. Both may be NULL if unknown. The returned object must be freed using <a class="el" href="structmrpoortext__t.html#a89c28735bfd718051ffc6b742f9c10ed" title="Frees a poortext object. ">mrpoortext_unref()</a> when no longer used. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="adfe10086430b562b8df4e45668b51927"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int mrmsg_get_width </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get width of image or video. </p>
|
|
<p>The width is returned in pixels. If the width is unknown or if the associated file is no image or video file, 0 is returned.</p>
|
|
<p>Often the ascpect ratio is the more interesting thing. You can calculate this using <a class="el" href="structmrmsg__t.html#adfe10086430b562b8df4e45668b51927" title="Get width of image or video. ">mrmsg_get_width()</a> / <a class="el" href="structmrmsg__t.html#a8600ed157b44b1089783e66ce7b33353" title="Get height of image or video. ">mrmsg_get_height()</a>.</p>
|
|
<p>See also <a class="el" href="structmrmsg__t.html#aa180c0fd4c9cdd58cc47006022ebc1e0" title="Get duration of audio or video. ">mrmsg_get_duration()</a>.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>Width in pixels, if applicable. 0 otherwise or if unknown. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a8600ed157b44b1089783e66ce7b33353"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int mrmsg_get_height </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get height of image or video. </p>
|
|
<p>The height is returned in pixels. If the height is unknown or if the associated file is no image or video file, 0 is returned.</p>
|
|
<p>Often the ascpect ratio is the more interesting thing. You can calculate this using <a class="el" href="structmrmsg__t.html#adfe10086430b562b8df4e45668b51927" title="Get width of image or video. ">mrmsg_get_width()</a> / <a class="el" href="structmrmsg__t.html#a8600ed157b44b1089783e66ce7b33353" title="Get height of image or video. ">mrmsg_get_height()</a>.</p>
|
|
<p>See also <a class="el" href="structmrmsg__t.html#aa180c0fd4c9cdd58cc47006022ebc1e0" title="Get duration of audio or video. ">mrmsg_get_duration()</a>.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>Height in pixels, if applicable. 0 otherwise or if unknown. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="aa180c0fd4c9cdd58cc47006022ebc1e0"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int mrmsg_get_duration </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get duration of audio or video. </p>
|
|
<p>The duration is returned in milliseconds (ms). If the duration is unknown or if the associated file is no audio or video file, 0 is returned.</p>
|
|
<p>See also <a class="el" href="structmrmsg__t.html#adfe10086430b562b8df4e45668b51927" title="Get width of image or video. ">mrmsg_get_width()</a> and <a class="el" href="structmrmsg__t.html#a8600ed157b44b1089783e66ce7b33353" title="Get height of image or video. ">mrmsg_get_height()</a>.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>Duration in milliseconds, if applicable. 0 otherwise or if unknown. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a7f1bd3d845bbc5face7636aed8f8afd4"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int mrmsg_get_showpadlock </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Check if a padlock should be shown beside the message. </p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>1=padlock should be shown beside message, 0=do not show a padlock beside the message. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="afc3d94448ada0ad7142cf168cab1462e"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="structmrpoortext__t.html">mrpoortext_t</a> * mrmsg_get_summary </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype"><a class="el" href="structmrchat__t.html">mrchat_t</a> * </td>
|
|
<td class="paramname"><em>chat</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get a summary for a message. </p>
|
|
<p>Typically used to display a search result.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
<tr><td class="paramname">chat</td><td>To speed up things, pass an already available chat object here. If the chat object is not yet available, it is faster to pass NULL.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>The returned summary is similar to <a class="el" href="structmrchatlist__t.html#ae7670d62ab7fc83aff18f299f26853d8" title="Get a summary for a chatlist index. ">mrchatlist_get_summary()</a>, however, without "draft", "no messages" and so on. The result must be freed using <a class="el" href="structmrpoortext__t.html#a89c28735bfd718051ffc6b742f9c10ed" title="Frees a poortext object. ">mrpoortext_unref()</a>. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a8c8c1f342f01439ae40c5cf37532387e"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">char * mrmsg_get_summarytext </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">int </td>
|
|
<td class="paramname"><em>approx_characters</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Get a message summary as a single line of text. </p>
|
|
<p>Typically used for notifications.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
<tr><td class="paramname">approx_characters</td><td>Rough length of the expected string.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>A summary for the given messages. The returned string must be free()'d. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="af202a7e7527df4681cd3ea24f779848f"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int mrmsg_is_starred </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Check if a message is starred. </p>
|
|
<p>Starred messages are "favorites" marked by the user with a "star" or something like that. Starred messages can typically be shown easily and are not deleted automatically.</p>
|
|
<p>To star one or more messages, use <a class="el" href="structmrmailbox__t.html#a8ed1c3bd08cd6515abf6046ebad9cafc" title="Star/unstar messages by setting the last parameter to 0 (unstar) or 1(star). ">mrmailbox_star_msgs()</a>, to get a list of starred messages, use <a class="el" href="structmrmailbox__t.html#af5ac7f527aef58f8e834f3bd740acd46" title="Get all message IDs belonging to a chat. ">mrmailbox_get_chat_msgs()</a> using MR_CHAT_ID_STARRED as the chat_id.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>1=message is starred, 0=message not starred. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a3256ed8c6a55a6c1a30e0fce33b85421"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int mrmsg_is_forwarded </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Check if the message is a forwarded message. </p>
|
|
<p>Forwarded messages may not be created by the contact given as "from".</p>
|
|
<p>Typically, the UI shows a little text for a symbol above forwarded messages.</p>
|
|
<p>For privacy reasons, we do not provide the name or the email address of the original author (in a typical GUI, you select the messages text and click on "forwared"; you won't expect other data to be send to the new recipient, esp. as the new recipient may not be in any relationship to the original author)</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>1=message is a forwarded message, 0=message not forwarded. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a752209192e3a022d087fe6c647fb3ad9"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int mrmsg_is_systemcmd </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Check if the message is a system command. </p>
|
|
<p>System command messages are messages not "typed" by the user but created due to other actions, eg. <a class="el" href="structmrmailbox__t.html#a8772e9bb55b02299f65ebd8bcc682bb1" title="Set group name. ">mrmailbox_set_chat_name()</a>, <a class="el" href="structmrmailbox__t.html#a08c527170681c949ddd6931a004fdd5f" title="Set group profile image. ">mrmailbox_set_chat_profile_image()</a> or <a class="el" href="structmrmailbox__t.html#a96368620971935c7ac4a0bb324ece2c9" title="Add a member to a group. ">mrmailbox_add_contact_to_chat()</a>.</p>
|
|
<p><a class="el" href="structmrmsg__t.html#ae549e58d9ae2f73ad76bd27636b43982" title="Get the text of the message. ">mrmsg_get_text()</a> returns a descriptive text about what is going on.</p>
|
|
<p>There is no need to perfrom any action when seeing such a message - this is already done by the core. Typically, this text is displayed in another color or in another font than normal user messages.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>1=message is a system command, 0=normal message </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a32d23bac4bf35ed5f8c2cfbb93d636f5"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int mrmsg_is_increation </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Check if a message is still in creation. </p>
|
|
<p>The user can mark files as being in creation by simply creating a file <code><filename>.increation</code>. If <code><filename></code> is created then, the user should just delete <code><filename>.increation</code>.</p>
|
|
<p>Typically, this is used for videos that should be recoded by the user before they can be sent.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>the message object</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>1=message is still in creation (<code><filename>.increation</code> exists), 0=message no longer in creation </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a9e5dc81d4e814284b465ad23abbfb6cb"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void mrmsg_latefiling_mediasize </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="structmrmsg__t.html">mrmsg_t</a> * </td>
|
|
<td class="paramname"><em>msg</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">int </td>
|
|
<td class="paramname"><em>width</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">int </td>
|
|
<td class="paramname"><em>height</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">int </td>
|
|
<td class="paramname"><em>duration</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Late filing information to a message. </p>
|
|
<p>Sometimes, the core cannot find out the width, the height or the duration of an image, an audio or a video.</p>
|
|
<p>If, in these cases, the frontend can provide the information, it can save them together with the message object for later usage.</p>
|
|
<p>This function should only be used if <a class="el" href="structmrmsg__t.html#adfe10086430b562b8df4e45668b51927" title="Get width of image or video. ">mrmsg_get_width()</a>, <a class="el" href="structmrmsg__t.html#a8600ed157b44b1089783e66ce7b33353" title="Get height of image or video. ">mrmsg_get_height()</a> or <a class="el" href="structmrmsg__t.html#aa180c0fd4c9cdd58cc47006022ebc1e0" title="Get duration of audio or video. ">mrmsg_get_duration()</a> do not provide the expected values.</p>
|
|
<p>To get the stored values later, use <a class="el" href="structmrmsg__t.html#adfe10086430b562b8df4e45668b51927" title="Get width of image or video. ">mrmsg_get_width()</a>, <a class="el" href="structmrmsg__t.html#a8600ed157b44b1089783e66ce7b33353" title="Get height of image or video. ">mrmsg_get_height()</a> or <a class="el" href="structmrmsg__t.html#aa180c0fd4c9cdd58cc47006022ebc1e0" title="Get duration of audio or video. ">mrmsg_get_duration()</a>.</p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">msg</td><td>The message object.</td></tr>
|
|
<tr><td class="paramname">width</td><td>The new width to store in the message object. 0 if you do not want to change it.</td></tr>
|
|
<tr><td class="paramname">height</td><td>The new height to store in the message object. 0 if you do not want to change it.</td></tr>
|
|
<tr><td class="paramname">duration</td><td>The new duration to store in the message object. 0 if you do not want to change it.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd>None. </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<h2 class="groupheader">Member Data Documentation</h2>
|
|
<a class="anchor" id="a793898c8da24c717dc2bb1d91faac801"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">uint32_t mrmsg_t::m_id</td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Message ID. </p>
|
|
<p>Never 0. </p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a299981cb89b25ebaaedf7a8486a86ee6"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">uint32_t mrmsg_t::m_from_id</td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Contact ID of the sender. </p>
|
|
<p>Never 0. See <a class="el" href="structmrcontact__t.html#ab2ee31297c327e04ed14673adbd49716" title="The contact ID. ">mrcontact_t::m_id</a> for special IDs. Use <a class="el" href="structmrmailbox__t.html#a057660d94350ff98eca72785c6e88962" title="Get a single contact object. ">mrmailbox_get_contact()</a> to load details about this contact. </p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="ad549fc02587ba284fda2bbecd162b16a"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">uint32_t mrmsg_t::m_to_id</td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Contact ID of the recipient. </p>
|
|
<p>Never 0. See <a class="el" href="structmrcontact__t.html#ab2ee31297c327e04ed14673adbd49716" title="The contact ID. ">mrcontact_t::m_id</a> for special IDs. Use <a class="el" href="structmrmailbox__t.html#a057660d94350ff98eca72785c6e88962" title="Get a single contact object. ">mrmailbox_get_contact()</a> to load details about this contact. </p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="ac19bdc40e452c8997dd58474a7be6880"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">uint32_t mrmsg_t::m_chat_id</td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Chat ID the message belongs to. </p>
|
|
<p>Never 0. See <a class="el" href="structmrchat__t.html#a1591431716413350eaffce0b588e4911" title="Chat ID under which the chat is filed in the database. ">mrchat_t::m_id</a> for special IDs. Use <a class="el" href="structmrmailbox__t.html#ad106b9c23b3a559b524a37bb5504e096" title="Get chat object by a chat ID. ">mrmailbox_get_chat()</a> to load details about the chat. </p>
|
|
|
|
</div>
|
|
</div>
|
|
<hr/>The documentation for this struct was generated from the following files:<ul>
|
|
<li>/home/bpetersen/projects/deltachat-core/src/<a class="el" href="mrmsg_8h_source.html">mrmsg.h</a></li>
|
|
<li>/home/bpetersen/projects/deltachat-core/src/mrmsg.c</li>
|
|
</ul>
|
|
</div><!-- contents -->
|
|
<!-- start footer part -->
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated by  <a href="http://www.doxygen.org/index.html">
|
|
<img class="footer" src="doxygen.png" alt="doxygen"/>
|
|
</a> 1.8.11
|
|
</small></address>
|
|
</body>
|
|
</html>
|