But the part that is declarative is sure difficult to test.
i did not speak about testing, however what a declarative language can do is defined by the framework under it. so you test that I guess?
You don't draw line by line. You describe what you want and have the engine work it out. Just because that description can be complex such as a <path> definition doesn't detract from this point.
Kinda like SQL. Describe the set of data you want from other sets of data and have the engine work it out. It's set theory. In math, sets can have conditions, can be combined, can be filtered, and all without a single function or loop in sight. Ergo declarative, not functional or imperative.
SQL is a DSL for set theory with some extensions tacked on. You can use functions with SQL, but its core is perfectly adequate without them.
I totally agree. It is declarative the same way how HTML is.
I don't see how SQL and SVG is similar from the viewpoint of approaching the problem. In SVG you concretely define what you want, and that is happening. In SQL you don't define the data you get, like ok, this cell will be 5, another will 8. I understand what you want to say, I just see those completely different ways.
>can be combined, can be filtered, and all without a single function or loop in sight
This is the key here, because this is exactly true to functional programming.
Compare SQL->LINQ->lambda expression
If they work the how you say, then
SQL - declarative
LINQ - declarative and functional the same time
Lambda exp - functional
This idea is completely nonsensical for me
Point to any programming language that is supposed to be a pure example of anything and folks will either find at least ten clear counterexamples in that language within five minutes or demonstrate how it is grossly limited to the point of uselessness for production use on a non-trivial scale.