ComposeMessage issues

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

ComposeMessage issues

rene-39
Hi,

while working on https://bugzilla.mozilla.org/show_bug.cgi?id=1518025
I'm trying to understand how MessageCompose is done in Thunderbird. Some
questions came up, as usual, the more you learn about some area the more
questions you've got.

Message-Compose is done after a preparation in
mailCommands.js:ComposeMessage in
nsMsgComposeService::OpenComposeWindow. At this point Drafts, Templates
and EditAsNew messages are parsed through a mime reader
(LoadDraftOrTemplate) and Reply-Messages are opened via
OpenComposeWindowWithParams without parsing the complete message.

Having the message not parsed completely on Replys has different effects.

Assume for instance you only show headers for your IMAP-mails and
prevent previews of the message by hiding the preview area. If you try
to forward such a message, everything will be ok. If you are going to
reply, you will end with an empty message without some recipient in your
compose-window (tested with daily 71.0a1)

Question: Is there a special reason why there are different ways for
Templates-etc. and Reply's?

I've also run into issues with the pre-selected identity via
mailCommands.js:ComposeMessage->findDeliveredToIdentityEmail . Probably
nobody uses a "delivered-to" header, but if you do, the detection of
this header and therefore the selected identity for your Reply is
dependent on your display settings as well. No preview, no header,
different identity.

Is there anybody who can help me understanding the Why and WhyNots of
MessageCompose?

Best regards, Rene
_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird
Reply | Threaded
Open this post in threaded view
|

Re: ComposeMessage issues

Jörg Knobloch
On 13/10/2019 17:41, rene wrote:
> Is there anybody who can help me understanding the Why and WhyNots of
> MessageCompose?

A compose peer?

As you discovered, the ways of compose are twisted and replying works
completely differently to forward/edit as new/edit draft.

I once tried to work out how it works and attached my findings to a bug,
but it's faster to add the document here.

Jörg.


_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird

Compose pipeline.txt (7K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: ComposeMessage issues

rene-39
Hi Jörg,

thanks for the overview... seems to match my impression.

you wrote in your attachment:
"We can userstand so far that the compose types that go through the MIME
processing here have an advantage since they parsed the exising message
with MIME. The remaining types, especially all the reply types, don't
seem to know about the original message so far."

So, why there are two way of handling Compose-Types, 'historical'
reasons? Why not sending all types trough mime processing?

Until now I thought the only difference between forwarding some or
replying to an email should be the auto-insertion of the recipient
address in the reply case... Am I missing something here?

Regards, Rene


On 10/13/19 10:34 PM, Jörg Knobloch wrote:

> On 13/10/2019 17:41, rene wrote:
>> Is there anybody who can help me understanding the Why and WhyNots of
>> MessageCompose?
>
> A compose peer?
>
> As you discovered, the ways of compose are twisted and replying works
> completely differently to forward/edit as new/edit draft.
>
> I once tried to work out how it works and attached my findings to a bug,
> but it's faster to add the document here.
>
> Jörg.
>
>
> _______________________________________________
> dev-apps-thunderbird mailing list
> [hidden email]
> https://lists.mozilla.org/listinfo/dev-apps-thunderbird
>
_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird
Reply | Threaded
Open this post in threaded view
|

Re: ComposeMessage issues

Jörg Knobloch
On 14/10/2019 17:11, rene wrote:
> So, why there are two way of handling Compose-Types, 'historical'
> reasons? Why not sending all types trough mime processing?
>
> Until now I thought the only difference between forwarding some or
> replying to an email should be the auto-insertion of the recipient
> address in the reply case... Am I missing something here?

That stuff existed before I joined the project, so I don't know.

For replies, which are inserted as a quote, the work happens in
QuotingOutputStreamListener::OnStopRequest().

Jörg.

_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird
Reply | Threaded
Open this post in threaded view
|

Re: ComposeMessage issues

ISHIKAWA,chiaki
In reply to this post by Jörg Knobloch
On 2019/10/14 5:34, Jörg Knobloch wrote:

> On 13/10/2019 17:41, rene wrote:
>> Is there anybody who can help me understanding the Why and WhyNots of
>> MessageCompose?
>
> A compose peer?
>
> As you discovered, the ways of compose are twisted and replying works
> completely differently to forward/edit as new/edit draft.
>
> I once tried to work out how it works and attached my findings to a bug, but
> it's faster to add the document here.
>
> Jörg.
>

Dear Jörg,

I found the call flow analysis very useful.

Have you created the relationship paragraphs using, say VS 201x addon tool
or something?
(I understand you develop TB under Windows.)

I have been trying to find a good call flow graph/diagram generator which is
detailed enough to
help occasional patch submitters like me to understand the C-C TB code.
(Even a crude call-relationship description a la cflow for C program would
be fine.)
Doxygen is not good enough (not complete) for a patch developer: not many
functions are annotated to begin with :-(

I have searched for such a tool a few weeks ago, but none seems to fit the bill.

If there is a good addon tool for VS201x suite, I may simply install the
tool just for obtaining the call-callee listing.

I am currently only interested in C++ source files.

TIA


_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird
Reply | Threaded
Open this post in threaded view
|

Re: ComposeMessage issues

Buddy Butterfly

Hi,

call graphs and navigation is built-in in Netbeans.
Install latest netbeans 11.1, enable the update source
for version 8.2 (last tab in update window) and install
c++ support. You can get from any point a call graph
with switching directions. Also nice is the macro expansion.

Cheers,
Matt


Am 21.10.19 um 10:45 schrieb ishikawa:
On 2019/10/14 5:34, Jörg Knobloch wrote:
On 13/10/2019 17:41, rene wrote:
Is there anybody who can help me understanding the Why and WhyNots of
MessageCompose?
A compose peer?

As you discovered, the ways of compose are twisted and replying works
completely differently to forward/edit as new/edit draft.

I once tried to work out how it works and attached my findings to a bug, but
it's faster to add the document here.

Jörg.

Dear Jörg,

I found the call flow analysis very useful.

Have you created the relationship paragraphs using, say VS 201x addon tool
or something?
(I understand you develop TB under Windows.)

I have been trying to find a good call flow graph/diagram generator which is
detailed enough to
help occasional patch submitters like me to understand the C-C TB code.
(Even a crude call-relationship description a la cflow for C program would
be fine.)
Doxygen is not good enough (not complete) for a patch developer: not many
functions are annotated to begin with :-(

I have searched for such a tool a few weeks ago, but none seems to fit the bill.

If there is a good addon tool for VS201x suite, I may simply install the
tool just for obtaining the call-callee listing.

I am currently only interested in C++ source files.

TIA


_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird


_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird
Reply | Threaded
Open this post in threaded view
|

Re: ComposeMessage issues

ISHIKAWA,chiaki
Thank you for the tips.

I have not installed serious IDE for a while now. I tinkered with Eclipse
several years ago, but gave up due to the slowness on my then not so
powerful PC.

Maybe I should give a serious IDE a try again now that my PC has multi core
CPU (8 real core to boot!) and 16GB memory: Actually, I  do most of the work
under linux in Virtualbox  hosted under Windows 10 due to driver issues.
Now I split CPU cores and memory between the host Windows 10 and guest
linux. Today, guest linux has 7 virtual cores and 16GB while the host
Windows have 9 virtual cores and can use the rest of 32 GB real memory. Back
when I tinkered with Eclipse, I think the total core was four and the memory
as a whole is 16GB.
(My CPU is Ryzen 1700: it has 8 real core with hyperthreading. It is very
low-power and thus I could build very quiet computer using the stock fan
that came with the CPU package. With 16MB cache, it is a very fast CPU when
I run C-C TB under valgrind even. )

I will report back my finding after I install Netbeans and experiment with it.

Chiaki


On 2019/10/21 17:53, Buddy Butterfly wrote:

>
> Hi,
>
> call graphs and navigation is built-in in Netbeans.
> Install latest netbeans 11.1, enable the update source
> for version 8.2 (last tab in update window) and install
> c++ support. You can get from any point a call graph
> with switching directions. Also nice is the macro expansion.
>
> Cheers,
> Matt
>
>
> Am 21.10.19 um 10:45 schrieb ishikawa:
>> On 2019/10/14 5:34, Jörg Knobloch wrote:
>>> On 13/10/2019 17:41, rene wrote:
>>>> Is there anybody who can help me understanding the Why and WhyNots of
>>>> MessageCompose?
>>> A compose peer?
>>>
>>> As you discovered, the ways of compose are twisted and replying works
>>> completely differently to forward/edit as new/edit draft.
>>>
>>> I once tried to work out how it works and attached my findings to a bug, but
>>> it's faster to add the document here.
>>>
>>> Jörg.
>>>
>> Dear Jörg,
>>
>> I found the call flow analysis very useful.
>>
>> Have you created the relationship paragraphs using, say VS 201x addon tool
>> or something?
>> (I understand you develop TB under Windows.)
>>
>> I have been trying to find a good call flow graph/diagram generator which is
>> detailed enough to
>> help occasional patch submitters like me to understand the C-C TB code.
>> (Even a crude call-relationship description a la cflow for C program would
>> be fine.)
>> Doxygen is not good enough (not complete) for a patch developer: not many
>> functions are annotated to begin with :-(
>>
>> I have searched for such a tool a few weeks ago, but none seems to fit the bill.
>>
>> If there is a good addon tool for VS201x suite, I may simply install the
>> tool just for obtaining the call-callee listing.
>>
>> I am currently only interested in C++ source files.
>>
>> TIA
>>
>>
>> _______________________________________________
>> dev-apps-thunderbird mailing list
>> [hidden email]
>> https://lists.mozilla.org/listinfo/dev-apps-thunderbird
>

_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird
Reply | Threaded
Open this post in threaded view
|

Call diagram (was Re: ComposeMessage issues)

ISHIKAWA,chiaki
After installing netbeans, I realize one thing.
It only supports GNU Make as build scheme. (Maybe there are later additions,
but I don't know.)

On the other hand, Eclispse *seems* to be supported by |mach|.
|mach ide eclipse| seems to create the project template for use with Eclipse.

Given the necessary massaging to let Netbeans know the used file set and
dependencies, I decided
try Eclipse instead.

Netbeans dynamic call status viewer, also called Call Diagram or some such
(using dynamic profiling support of Linux kernel) seems very promising.
I wonder if Eclipse has something similar. I will try investigating this as
well.
My initial and foremost interest is the static call graph to help me/us in
understanding the code structure.

TIA

Chiaki

PS: I am pleasantly surprised that
Netbeans  boots rather quickly thanks to today's CPU power.
I wonder how Eclipse will fare on my PC. Many years ago when I  tried Eclipse,
it was so slow that I had to ditch it in a day.

I will report the progress.
On 2019/10/23 20:06, ishikawa wrote:

> Thank you for the tips.
>
> I have not installed serious IDE for a while now. I tinkered with Eclipse
> several years ago, but gave up due to the slowness on my then not so
> powerful PC.
>
> Maybe I should give a serious IDE a try again now that my PC has multi core
> CPU (8 real core to boot!) and 16GB memory: Actually, I  do most of the work
> under linux in Virtualbox  hosted under Windows 10 due to driver issues.
> Now I split CPU cores and memory between the host Windows 10 and guest
> linux. Today, guest linux has 7 virtual cores and 16GB while the host
> Windows have 9 virtual cores and can use the rest of 32 GB real memory. Back
> when I tinkered with Eclipse, I think the total core was four and the memory
> as a whole is 16GB.
> (My CPU is Ryzen 1700: it has 8 real core with hyperthreading. It is very
> low-power and thus I could build very quiet computer using the stock fan
> that came with the CPU package. With 16MB cache, it is a very fast CPU when
> I run C-C TB under valgrind even. )
>
> I will report back my finding after I install Netbeans and experiment with it.
>
> Chiaki
>
>
> On 2019/10/21 17:53, Buddy Butterfly wrote:
>>
>> Hi,
>>
>> call graphs and navigation is built-in in Netbeans.
>> Install latest netbeans 11.1, enable the update source
>> for version 8.2 (last tab in update window) and install
>> c++ support. You can get from any point a call graph
>> with switching directions. Also nice is the macro expansion.
>>
>> Cheers,
>> Matt
>>
>>
>> Am 21.10.19 um 10:45 schrieb ishikawa:
>>> On 2019/10/14 5:34, Jörg Knobloch wrote:
>>>> On 13/10/2019 17:41, rene wrote:
>>>>> Is there anybody who can help me understanding the Why and WhyNots of
>>>>> MessageCompose?
>>>> A compose peer?
>>>>
>>>> As you discovered, the ways of compose are twisted and replying works
>>>> completely differently to forward/edit as new/edit draft.
>>>>
>>>> I once tried to work out how it works and attached my findings to a bug, but
>>>> it's faster to add the document here.
>>>>
>>>> Jörg.
>>>>
>>> Dear Jörg,
>>>
>>> I found the call flow analysis very useful.
>>>
>>> Have you created the relationship paragraphs using, say VS 201x addon tool
>>> or something?
>>> (I understand you develop TB under Windows.)
>>>
>>> I have been trying to find a good call flow graph/diagram generator which is
>>> detailed enough to
>>> help occasional patch submitters like me to understand the C-C TB code.
>>> (Even a crude call-relationship description a la cflow for C program would
>>> be fine.)
>>> Doxygen is not good enough (not complete) for a patch developer: not many
>>> functions are annotated to begin with :-(
>>>
>>> I have searched for such a tool a few weeks ago, but none seems to fit the bill.
>>>
>>> If there is a good addon tool for VS201x suite, I may simply install the
>>> tool just for obtaining the call-callee listing.
>>>
>>> I am currently only interested in C++ source files.
>>>
>>> TIA
>>>
>>>
>>> _______________________________________________
>>> dev-apps-thunderbird mailing list
>>> [hidden email]
>>> https://lists.mozilla.org/listinfo/dev-apps-thunderbird
>>
>

_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird
Reply | Threaded
Open this post in threaded view
|

Re: Call diagram (was Re: ComposeMessage issues)

ISHIKAWA,chiaki
Intermediate result.

I am trying Eclipse.

Installing Eclipse under Debian GNU/Linux needs one blackmagic.
Without the tips in the following post, installation won't proceed at
all (!)

https://superuser.com/questions/1455397/debian-9-org-eclipse-swt-swterror-no-more-handles-immediately-after-opening-ec

It seems to have something to do with multi-octet unicode input system
such as for Japanese.
(I have no idea how that can affect Eclipse installer.)

But ten, unfortunately, |mach ide eclipse| fails with a missing module
or something.

See https://bugzilla.mozilla.org/show_bug.cgi?id=1591229

Stay tuned...

Chiaki


On 2019/10/24 10:16, ishikawa wrote:

> After installing netbeans, I realize one thing.
> It only supports GNU Make as build scheme. (Maybe there are later additions,
> but I don't know.)
>
> On the other hand, Eclispse *seems* to be supported by |mach|.
> |mach ide eclipse| seems to create the project template for use with Eclipse.
>
> Given the necessary massaging to let Netbeans know the used file set and
> dependencies, I decided
> try Eclipse instead.
>
> Netbeans dynamic call status viewer, also called Call Diagram or some such
> (using dynamic profiling support of Linux kernel) seems very promising.
> I wonder if Eclipse has something similar. I will try investigating this as
> well.
> My initial and foremost interest is the static call graph to help me/us in
> understanding the code structure.
>
> TIA
>
> Chiaki
>
> PS: I am pleasantly surprised that
> Netbeans  boots rather quickly thanks to today's CPU power.
> I wonder how Eclipse will fare on my PC. Many years ago when I  tried Eclipse,
> it was so slow that I had to ditch it in a day.
>
> I will report the progress.
> On 2019/10/23 20:06, ishikawa wrote:
>> Thank you for the tips.
>>
>> I have not installed serious IDE for a while now. I tinkered with Eclipse
>> several years ago, but gave up due to the slowness on my then not so
>> powerful PC.
>>
>> Maybe I should give a serious IDE a try again now that my PC has multi core
>> CPU (8 real core to boot!) and 16GB memory: Actually, I  do most of the work
>> under linux in Virtualbox  hosted under Windows 10 due to driver issues.
>> Now I split CPU cores and memory between the host Windows 10 and guest
>> linux. Today, guest linux has 7 virtual cores and 16GB while the host
>> Windows have 9 virtual cores and can use the rest of 32 GB real memory. Back
>> when I tinkered with Eclipse, I think the total core was four and the memory
>> as a whole is 16GB.
>> (My CPU is Ryzen 1700: it has 8 real core with hyperthreading. It is very
>> low-power and thus I could build very quiet computer using the stock fan
>> that came with the CPU package. With 16MB cache, it is a very fast CPU when
>> I run C-C TB under valgrind even. )
>>
>> I will report back my finding after I install Netbeans and experiment with it.
>>
>> Chiaki
>>
>>
>> On 2019/10/21 17:53, Buddy Butterfly wrote:
>>> Hi,
>>>
>>> call graphs and navigation is built-in in Netbeans.
>>> Install latest netbeans 11.1, enable the update source
>>> for version 8.2 (last tab in update window) and install
>>> c++ support. You can get from any point a call graph
>>> with switching directions. Also nice is the macro expansion.
>>>
>>> Cheers,
>>> Matt
>>>
>>>
>>> Am 21.10.19 um 10:45 schrieb ishikawa:
>>>> On 2019/10/14 5:34, Jörg Knobloch wrote:
>>>>> On 13/10/2019 17:41, rene wrote:
>>>>>> Is there anybody who can help me understanding the Why and WhyNots of
>>>>>> MessageCompose?
>>>>> A compose peer?
>>>>>
>>>>> As you discovered, the ways of compose are twisted and replying works
>>>>> completely differently to forward/edit as new/edit draft.
>>>>>
>>>>> I once tried to work out how it works and attached my findings to a bug, but
>>>>> it's faster to add the document here.
>>>>>
>>>>> Jörg.
>>>>>
>>>> Dear Jörg,
>>>>
>>>> I found the call flow analysis very useful.
>>>>
>>>> Have you created the relationship paragraphs using, say VS 201x addon tool
>>>> or something?
>>>> (I understand you develop TB under Windows.)
>>>>
>>>> I have been trying to find a good call flow graph/diagram generator which is
>>>> detailed enough to
>>>> help occasional patch submitters like me to understand the C-C TB code.
>>>> (Even a crude call-relationship description a la cflow for C program would
>>>> be fine.)
>>>> Doxygen is not good enough (not complete) for a patch developer: not many
>>>> functions are annotated to begin with :-(
>>>>
>>>> I have searched for such a tool a few weeks ago, but none seems to fit the bill.
>>>>
>>>> If there is a good addon tool for VS201x suite, I may simply install the
>>>> tool just for obtaining the call-callee listing.
>>>>
>>>> I am currently only interested in C++ source files.
>>>>
>>>> TIA
>>>>
>>>>
>>>> _______________________________________________
>>>> dev-apps-thunderbird mailing list
>>>> [hidden email]
>>>> https://lists.mozilla.org/listinfo/dev-apps-thunderbird
> _______________________________________________
> dev-apps-thunderbird mailing list
> [hidden email]
> https://lists.mozilla.org/listinfo/dev-apps-thunderbird


_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird