Skip to content

Instantly share code, notes, and snippets.

@maxandersen
Created October 31, 2014 22:09
Show Gist options
  • Star 12 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save maxandersen/10bc76e644848eb6944d to your computer and use it in GitHub Desktop.
Save maxandersen/10bc76e644848eb6944d to your computer and use it in GitHub Desktop.
Threaded layout for MailMate - Adds view that shows threads + messages that match subject. See screenshot at https://www.dropbox.com/s/t5gxgpjcg2aoqyb/Screenshot%202014-10-31%2011.01.06.png?dl=0 copy this file to ~/Library/Application Support/MailMate/Resources/Layouts/Mailboxes/threaded.plist and restart MailMate and then a "Threaded" option sh…
{
name = "Threaded";
rootViewer =
{
viewerType = "MmSplitView";
orientation = "horizontal";
children =
(
{
viewerType = "MmBoxView";
orientation = "vertical";
defaultSize = 200;
minWidth = 100;
autoresize = 0;
toggleMenuTitle = "Mailboxes";
toggleKeyEquivalent = "^~@d";
dragRect = { width = 16.0; height = 16.0; location = "bottomRight"; };
children =
(
{
identifier = "mailboxesOutline";
viewerType = "MmMailboxesOutlineView";
stickyMessages = 1;
},
{
viewerType = "MmMailboxesStatusBar";
},
);
},
{
viewerType = "MmSplitView";
orientation = "vertical";
collapsibleSubview = 2; // Incomplete support -- no way to get it back (1 = first, 2 = last)
children =
(
{
identifier = "pathOutlineBox";
viewerType = "MmBoxView";
orientation = "vertical";
defaultSize = 250;
autoresize = 0;
children =
(
{
identifier = "pathControl";
viewerType = "MmPathControlView";
sources = ( { sourceIdentifier = "mailboxesOutline"; } );
},
{ viewerType = "MmSeparatorView"; showWithViews = ( "pathControl" ); },
{
viewerType = "MmSplitView";
minHeight = 50;
orientation = "horizontal";
children =
(
{
identifier = "mainOutline";
viewerType = "MmMessagesOutlineView";
// columnSettings = "outlineColumns";
sources = ( { sourceIdentifier = "pathControl"; } );
defaultSize = 350;
},
// {
// identifier = "locator";
// viewerType = "MmLocatorView";
// sources = ( { sourceIdentifier = "mainOutline"; } );
// canBecomeKeyView = 0; // Not implemented
// },
);
},
);
},
{
viewerType = "MmSplitView";
orientation = "horizontal";
children =
(
{
viewerType = "MmBoxView";
orientation = "vertical";
defaultSize = 200;
autoresize = 0;
children =
(
{
viewerType = "MmLabelView";
label = "Thread";
},
{ viewerType = "MmSeparatorView"; },
{
identifier = "threadedOutline";
viewerType = "MmMessagesOutlineView";
minWidth = 100;
sources = ( { sourceIdentifier = "mainOutline"; } );
selectionSources = ( { sourceIdentifier = "mainOutline"; } );
// mailmate does not always honor thread-id found in references so we try
// and make it pickup other threads by using the subject body to find
// the related threads. Has the advantage to also find forwarded mails
// or separate mails that have 'broken' off the thread.
transformation = "$ALL_MESSAGES.filter(#thread-id = $mainOutline.#thread-id or subject.body = $mainOutline.subject.body)";
defaultColumns = ( "relativeDate", "from" );
outlineColumn = "relativeDate";
},
);
toggleMenuTitle = "Threaded View";
toggleKeyEquivalent = "^~@c";
},
{
viewerType = "MmBoxView";
orientation = "vertical";
children =
(
{
identifier = "headersView";
viewerType = "MmHeadersView";
sources = ( { sourceIdentifier = "threadedOutline"; } );
inject = ( "headersFormatting.plist" );
},
{ viewerType = "MmSeparatorView"; showWithViews = ( "headersView" ); },
{
identifier = "tagsEditor";
viewerType = "MmTagsEditor";
sources = ( { sourceIdentifier = "threadedOutline"; } );
},
{ viewerType = "MmSeparatorView"; showWithViews = ( "tagsEditor" ); },
{
identifier = "blockingView";
viewerType = "MmImageBlockingView";
sources = ( { sourceIdentifier = "threadedOutline"; } );
transformation = "$threadedOutline.filter(##blocked-count exists)";
},
{ viewerType = "MmSeparatorView"; showWithViews = ( "blockingView" ); },
{
identifier = "securityView";
viewerType = "MmSecurityView";
sources = ( { sourceIdentifier = "threadedOutline"; } );
transformation = "$threadedOutline.filter(##security-problem exists)";
},
{ viewerType = "MmSeparatorView"; showWithViews = ( "securityView" ); },
{
identifier = "messageView";
viewerType = "MmWebView";
sources = ( { sourceIdentifier = "threadedOutline"; } );
minWidth = 175;
minHeight = 50;
},
);
}
);
toggleMenuTitle = "Message View";
toggleKeyEquivalent = "^~@h";
},
// {
// identifier = "messageEditor";
// viewerType = "MmMessageTextView";
// sources = ( { sourceIdentifier = "threadedOutline"; } );
// minimumNumberOfMessages = 1;
// maximumNumberOfMessages = 1;
// match = "$threadedOutline.filter(#flags.flag = '\\Draft')"; // Only match drafts
// },
);
},
);
};
}
@catesandrew
Copy link

+1

@ToJa92
Copy link

ToJa92 commented Dec 9, 2014

Is it possible to make all threads in the "Thread" pane expand by default?

@mremond
Copy link

mremond commented May 15, 2015

This is magical :) Thanks !

@devynosborne
Copy link

devynosborne commented Jan 28, 2024

I found this via the MM mailing list - and looks great in the screenshot! Unfortunately, it doesn't seem to work with the latest MM version (Version 1.14 (5937)). Any chance you've updated it?

I get this message when trying to use it: "Unable to create window layout: Unable to create window using the “MmSeparatorView” view type. If you are using a custom layout then it needs to be updated to work with this release of MailMate."

UPDATE: I found some mailing list messages as recent as 2019, that this was now included in MM. But I don't see it in the included Layouts. Unless I'm just missing it, which is possible! ;-)

@maxandersen
Copy link
Author

I have update on my laptop. Ping me tomorrow. Watching Denmark vs France in then finals…

@devynosborne
Copy link

I have update on my laptop. Ping me tomorrow. Watching Denmark vs France in then finals…

Ping! :-)

@maxandersen
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment