NeoMutt  2025-12-11-949-g4870ee
Teaching an old dog new tricks
DOXYGEN
Loading...
Searching...
No Matches
functions.h File Reference

Mailing-list functions. More...

#include <stdbool.h>
#include <stddef.h>
#include "mutt/lib.h"
#include "email/lib.h"
+ Include dependency graph for functions.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  ListAction
 A mailing-list action in the dialog. More...
 
struct  ListEntry
 A mailing-list action in the dialog. More...
 
struct  ListData
 Private data for the Mailing-list action dialog. More...
 
struct  MlistFunction
 A list dialog function. More...
 

Typedefs

typedef int(* mlist_function_t) (struct ListData *ld, const struct KeyEvent *event)
 

Functions

 ARRAY_HEAD (ListEntryArray, struct ListEntry)
 
struct ListHead * mlist_action_value (struct Rfc2369ListHeaders *headers, const struct ListAction *action)
 Get the stored value for a mailing-list action.
 
int mlist_function_dispatcher (struct MuttWindow *win, const struct KeyEvent *event)
 Perform a List dialog function - Implements function_dispatcher_t -.
 
bool mlist_open_url (const char *url)
 

Variables

const struct ListAction ListActions []
 Mailing-list actions shown in the dialog.
 
const int ListActionsCount
 Number of entries in ListActions.
 

Detailed Description

Mailing-list functions.

Authors
  • Richard Russon

This program 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 General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

Definition in file functions.h.

Typedef Documentation

◆ mlist_function_t

typedef int(* mlist_function_t) (struct ListData *ld, const struct KeyEvent *event)

Definition at line 86 of file functions.h.

Function Documentation

◆ ARRAY_HEAD()

ARRAY_HEAD ( ListEntryArray ,
struct ListEntry  )

◆ mlist_action_value()

struct ListHead * mlist_action_value ( struct Rfc2369ListHeaders * headers,
const struct ListAction * action )

Get the stored value for a mailing-list action.

Parameters
headersParsed List-* headers
actionAction definition
Return values
ptrPointer to the stored header values

Definition at line 113 of file functions.c.

115{
116 return (struct ListHead *) (((char *) headers) + action->offset);
117}
size_t offset
Offset into struct Rfc2369ListHeaders.
Definition functions.h:41
+ Here is the caller graph for this function:

◆ mlist_open_url()

bool mlist_open_url ( const char * url)

Variable Documentation

◆ ListActions

const struct ListAction ListActions[]
extern

Mailing-list actions shown in the dialog.

Definition at line 45 of file functions.c.

45 {
46 // clang-format off
47 { N_("Help"), OP_LIST_HELP, offsetof(struct Rfc2369ListHeaders, help) },
48 { N_("Post"), OP_LIST_POST, offsetof(struct Rfc2369ListHeaders, post) },
49 { N_("Subscribe"), OP_LIST_SUBSCRIBE, offsetof(struct Rfc2369ListHeaders, subscribe) },
50 { N_("Unsubscribe"), OP_LIST_UNSUBSCRIBE, offsetof(struct Rfc2369ListHeaders, unsubscribe) },
51 { N_("Archives"), OP_LIST_ARCHIVE, offsetof(struct Rfc2369ListHeaders, archive) },
52 { N_("Owner"), OP_LIST_OWNER, offsetof(struct Rfc2369ListHeaders, owner) },
53 // clang-format on
54};
#define N_(a)
Definition message.h:32
Mailing-list actions from RFC 2369 headers.
Definition parse.h:41

◆ ListActionsCount

const int ListActionsCount
extern

Number of entries in ListActions.

Definition at line 57 of file functions.c.