It's always a pleasure when someone wants to know a bit about the language we speak.
Thanks for the clarification, Metamorfose! I knew it had the durative sense but I was never taught about HAVER except to say there is/are/was/were... so maybe that's something Brazilian Portuguese has kept that Portugues de Portugal has dropped. Do you know anything about that?
You talk about the Past Perfect being similar in use; in Lisbon I was taught to use the mais que perfeito, or the -ra, -ras, -ra... forms, so I had spoken would be (eu) falara rather than tinha falado. Is it different in Brazil?

I forgot to mention one thing: HAVER is not used with our equivalent to the present perfect, the so-called pretérito perfeito composto so in sentences like Você tem almoçado fora estes dias? only TER is possible. However, any other combinations can use HAVER or TER, for example:
Nós haviamos estudado bastante.
Nós tínhamos estudado bastante.
=> We had studied a lot.
In Brazil those compounded forms of the mais-que-perfeito are by far more largely used and accepted than the simple form as in Nós estudáramos, the simple form is only used in very formal pieces of written or speeches but I would totally avoid it here.
Se nós houvessemos estudado bastante, teriamos agora uma nota melhor.
Se nós tivessemos estudado bastante, teriamos agora uma nota melhor.
=> If we had studied more, we would've got better grades.
To give you a few examples.
José