Skip to search.

Breaking News Visit Yahoo! News for the latest.

×Close this window

svg-developers · SVG Developers

The Yahoo! Groups Product Blog

Check it out!

Group Information

  • Members: 8775
  • Category: Data Formats
  • Founded: Aug 16, 1999
  • Language: English
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Hear how Yahoo! Groups has changed the lives of others. Take me there.

Messages

Advanced
Messages Help
Messages 64167 - 64196 of 66117   Oldest  |  < Older  |  Newer >  |  Newest
Messages: Show Message Summaries Sort by Date ^  
#64167 From: "j.ingram48" <j.ingram48@...>
Date: Tue Nov 2, 2010 3:58 pm
Subject: SVG and MIDI
j.ingram48
Send Email Send Email
 
This thread started at W3C [1], but both Helder and David have recommended that
I move it here, so that's what I'm doing. The thread so far is quoted below.

Helder wrote:
> You mean "Inkscape" [1]? ;-)
Oops, yes.

> Yeah, I guess taking the "develop an Inkscape plug-in" approach is
> probably wise for this case. I've seen a few software packages based
> on this approach, mostly just to embed metadata which is used for
> behavior during run-time.
That sounds familiar. The extensions I have in mind are for use in an
application which runs in real, performed time (a real player using Assistant
Performer software).

I was thinking of defining the following types:
     mus:type="system"
     mus:type="staff"
     mus:type="chord"
     mus:type="rest"
     mus:type="barline"
     etc.
And
     mus:msPos (int)
     mus:staffName (string)
     mus:midiChannel (int)
     mus:midiPitches (list of ints)

The system mus:msPos would be the default number of milliseconds from the
beginning of the performance.
The chord and rest mus:msPos would be the default number of milliseconds from
the beginning of the system.

I dont need a default duration (mus:msDuration) anywhere, because that value can
easily be deduced from the sequences of mus:msPos if needed. Chord durations
are, however, very often shorter in real time than their defaults would be
(think Mozart staccato), so I think they would be unnecessary ballast and a
potential source of errors...

For example:

<svg ...  xmlns:mus="http://www.james-ingram-act-two/Moritz/scoreTypes" ... >
    <!-- there will be a sequence of systems in the page -->
    <g mus:type="system" mus:msPos="0">
       <!-- a sequence of staffs in the system -->
       <g mus:type="staff" mus:staffName="Flute" mus:midiChannel="0" >

         <!-- a sequence of clefs, barlines, rests, chords etc -->

         <g mus:type="rest" mus:msPos="0" >
             <!-- the rest text character -->
             <g mus:type="drawObjects">
                <!-- objects associated with the rest -->
             </g>
         </g> <!-- end of rest -->

         <g mus:type="barline">
             <!-- the barline line -->
             <g mus:type="drawObjects">
                <!-- objects associated with the barline -->
             </g>
         </g> <!-- end of barline -->

         <g mus:type="chord" mus:msPos="1348" mus:midiPitches="64 67 83 90">
            <!-- graphics for the chord symbol -->
            <g mus:type="drawObjects">
              <!-- control texts and other objects associated with the chord -->
              <!-- The control texts can be parsed for things like dynamics
                      or patch changes ->
            </g>
         </g> <!-- end of chord -->

         <!-- etc. more chords, rests, barlines etc. -->

     </g> <!-- end of staff -->
     <!-- more staves -->
   </g> <!-- end of system -->
   <!-- more systems -->
</svg>

This has the interesting side effect that there does not have to be a rest or
chord at the start of every staff. That's very useful, because notations should
not have to insist on having tied notes where durations cross systems. We are
not restricted to standard notation. :-) There probably has to be a special type
mus:tiedChord for chord symbols which are continuations...

David has now mentioned SMIL, so I've been reading a bit about that (for the
first time). Maybe because I'm new to it, it seems less intuitive than the above
scheme, and more verbose. It would be nice to reuse an existing standard if
possible, but only if it is the right standard! :-) Does it have any advantages
over the above scheme?

Helder said:
> I guess you might also find interesting (to mix/analyze/reuse) to know
> about Audacity [2], which has some (apparently quite limited) support
> for MIDI and whose license seems to be compatible with Inkscape's.
Again, I'm not interested in the sounds themselves. My Assistant Performer
outputs MIDI signals. What happens to the output after that is outside its
control. There are lots of programs/synthesizers out there which are concerned
with timbre-creation, and can provide interpretations of incoming MIDI data. For
me, perhaps the most interesting is Max/MSP [1].

David said:
> It would be sort of like having SVG but for sound and it would allow the
construction of complex
> sounds.
Constructing complex sounds is done at a level lower than chord symbols. I'm
talking about written music, which is all about things like musical form. Levels
higher than the chord level. SVG is of course the right language for describing
scores.
> Maybe there already is something like that but I doubt that it has
> browser support to let me make music yet.
Coming soon! :-) Browsers can display SVG scores and react to user input... I'm
interested in live music making...

> And I somehow doubt that if there
> is, that they're integrating that closely with SMIL and SVG.
? I doubt it too. SMIL looks to me too complicated for my purposes, but I may be
wrong...
> Here's some fiddling I did with random music composition using audio clips
> several years ago:
> http://srufaculty.sru.edu/david.dailey/javascript/sound/sound3.html (working
> in at least IE, FF, .
Unfortunately your examples use Quicktime, which does not run on my system
(Windows Vista 64bit Ultimate).

all the best,
James

[1] http://lists.w3.org/Archives/Public/www-svg/2010Oct/0160.html
[2] http://en.wikipedia.org/wiki/Max/MSP

==========================================================================

This thread started as follows (in chronological order)

> From: James Ingram <j.ingram@...>
> Date: Wed, 27 Oct 2010 00:21:04 +0200
> Message-ID: <4CC75450.2050305@...>
> To: www-svg@...
> Hi,
>
> I have an application which currently reads/writes both music scores and
> midi. The music notation I want to use is not quite standard, so I want
> to start writing my scores in SVG.
>
> I need to include logical information about chord symbols, (such as
> their temporal duration and midi pitches) so that these do not have to
> be deduced from the (static 2D) graphics when I read and play the file.
>
> Having read a few articles on SVG, the obvious way to do this would be
> to include the information in each chord's <desc> element using a
> standard string format.
>
> My questions are:
> Is there already a recommended way to include such logical
> (temporal/MIDI) information?
> Is there a standard string format?
> Should I be doing this some other way?
>
> I have not yet written any SVG but otherwise have a lot of experience in
> this area, so I know what I'm letting myself in for. :-)
>
> best wishes,
> James Ingram
> --
> www.james-ingram-act-two.de

> From: Alex Danilo <alex@...>
> Date: Fri, 29 Oct 2010 07:56:08 +1100
> Message-Id: <K5Q0BL.30ONAN7WDXQ8@...>
> To: James Ingram <j.ingram@...>
> Cc: www-svg@...
> Hi James,
>
> --Original Message--:
> >Hi,
> >
> >I have an application which currently reads/writes both music scores and
> >midi. The music notation I want to use is not quite standard, so I want
> >to start writing my scores in SVG.
> >
> >I need to include logical information about chord symbols, (such as
> >their temporal duration and midi pitches) so that these do not have to
> >be deduced from the (static 2D) graphics when I read and play the file.
> >
> >Having read a few articles on SVG, the obvious way to do this would be
> >to include the information in each chord's <desc> element using a
> >standard string format.
> >
> >My questions are:
> >Is there already a recommended way to include such logical
> >(temporal/MIDI) information?
>
> In the past people have used SVG for music authoring programs,
> but I don't think there is any preferred way to do this.
>
> >Is there a standard string format?
>
> Not that I'm aware of.
>
> >Should I be doing this some other way?
>
> Yes.
>
> If you pack this all into a string, you end up with the pain
> of having to parse the string out which is painful at best.
>
> It might be a better idea to declare your own XML namespace
> and declare the temporal and frequency information in your
> own namespace which becomes part of the notes/chords. A lot
> of authoring tools such as Inkscape, etc. use this approach
> for custom markup.
>
> For example:
>
> <svg xmlns=" http://www.w3.org/2000/svg"
> xmlns:xlink="http://www.w3.org/1999/xlink"
> xmlns:mymusic="http://james.music.notation">
> <defs>
> <g id="middle-c" mymusic:note="middle-c" mymusic:frequency="440">
> ... graphics in here, etc.
> <g>
> <g id="major-c" mymusic:chord="root-third-fifth">
> <use xlink:href="middle-c" .../>
> <use xlink:href="middle-e" .../>
> <use xlink:href="middle-g" .../>
> <g>
> ...
> </defs>
> <g id="song" mymusic:duration="20">
> <use xlink:href="major-c" ...
> </g>
>
> This doesn't make a lot of sense musically of course, but
> hopefully gives you an idea how to put this all into the
> SVG file in a way that will be a lot easier for you to
> reprocess and parse later.
>
> Alex
>
> >I have not yet written any SVG but otherwise have a lot of experience in
> >this area, so I know what I'm letting myself in for. :-)
> >
> >best wishes,
> >James Ingram
> >--
> >www.james-ingram-act-two.de
--------------------------------------------------------------------------
> From: James Ingram <j.ingram@...>
> Date: Fri, 29 Oct 2010 10:20:39 +0200
> Message-ID: <4CCA83D7.7000606@...>
> To: www-svg@...
> Hi Alex,
>
> That was very helpful, thanks!
>
> I'm now reading all about defining namespaces. :-)
>
> James
> --
> www.james-ingram-act-two.de
--------------------------------------------------------------------------
> From: Helder Magalhães <helder.magalhaes@...>
> Date: Sat, 30 Oct 2010 09:09:46 +0100
> Message-ID: <AANLkTinYdyeNS+nTctPef194fvwt-aYFHJ3uqT8gO+Eq@...>
> To: James Ingram <j.ingram@...>
> Cc: www-svg@...
> Hi James,
>
>
> > I need to include logical information about chord symbols, (such as their
> > temporal duration and midi pitches) so that these do not have to be deduced
> > from the (static 2D) graphics when I read and play the file.
> >
> > My questions are:
> > Is there already a recommended way to include such logical (temporal/MIDI)
> > information?
>
> I guess Alex already pointed out a good possible solution. I'd only
> add to this the declarative animation support [1] already in SVG
> (using SMIL), which adds the "temporal" information you might be
> seeking about. :-)
>
>
> > Should I be doing this some other way?
>
> (Apart from the above,) You could also try using scripting (for
> example using ECMAScript - a.k.a. JavaScript - or other languages).
> You'll *definitely* want to take a look at a tightly related SVG Wow!
> demo [2]! ;-)
>
>
> > I have not yet written any SVG but otherwise have a lot of experience in
> > this area, so I know what I'm letting myself in for. :-)
>
> I'm assuming that "this area" relates to graphics and stuff and I'm
> always glad to hear when someone with expertize joins the community.
> Welcome and good luck! ;-)
>
>
> > best wishes,
> > James Ingram
>
> Hope this helps,
> Helder
>
>
> [1] http://www.w3.org/TR/SVG11/animate.html
> [2] http://svg-wow.org/blog/2009/10/04/animated-lyrics/
--------------------------------------------------------------------------
> From: James Ingram <j.ingram@...>
> Date: Sat, 30 Oct 2010 13:20:01 +0200
> Message-ID: <4CCBFF61.4000102@...>
> To: www-svg@...
> CC: helder.magalhaes@...
> Hi Helder,
> Thanks for keeping this thread alive.
>
> I'm an expert in music notation with a background in writing music scores.
> Briefly: I was Karlheinz Stockhausen's copyist 1974-2000. Wrote his
> published scores in pen and ink until 1992, thereafter using a
> combination of Finale and Freehand. In the 1990s I wrote a group of
> plug-ins [1] for Freehand to help me create the complex scores I was
> being asked to create. I will be referring to their code when creating
> my SVG graphics.
>
> Thanks for pointing me at the animation examples, but I'm not currently
> interested in animating the graphics. What interests me is real-time
> user interaction with fixed, printable scores.
>
> In my first post, I said
> > I need to include logical information about chord symbols, (such as their
> > temporal duration and midi pitches) so that these do not have to be deduced
> > from the (static 2D) graphics when I read and play the file.
>
> I should have said _default_ duration not 'temporal duration'. The
> default duration can be overridden/ignored by any person or program
> playing the score. The default duration is related to the logical width
> of the symbol, and that's a value which is used to calculate the actual
> horizontal position of the symbols on the staff. The logical width can't
> be calculated from the graphics, because its only one of the inputs to
> the algorithm which justifies the symbols across the staff. But its a
> value which is known to the author of the graphics. :-)
>
> I've already written an Assistant Performer [2] application which does
> the kind of user-interaction I have in mind. This currently reads scores
> in CapXML format [3], but when I've created some (extended) SVG it will
> be easy to make it read that too.
>
> Currently I'm developing an Assistant Composer application which will
> _write_ (extended) SVG. (I'm also working on a long-overdue update of my
> website.) The Assistant Composer uses rather personal algorithms [4],
> but I could well imagine that _any_ music authoring program could write
> the extended SVG I have in mind. My Assistant Performer could play
> scores written by _any_ music authoring program if they exported my
> (extended) SVG.
>
> If there's anyone out there working in this area, I'd be very interested
> in cooperating.
>
> My mind has been exploding since Alex's post yesterday. Discovered that
> Inkpen preserves custom markup when reading and saving files... :-))
>
> All the best,
> James
>
> [1]
>
http://james-ingram-act-two.de/stockhausen/stockhausenSoftware.freeHandXtras.htm\
l
> [2] http://james-ingram-act-two.de/moritz/moritzAssistantPerformer.html
> [3] http://www.music-notation.info/de/formats/CapXML.html
> [4] http://james-ingram-act-two.de/compositions/study2/aboutStudy2.html
--------------------------------------------------------------------------
> From: "Helder Magalhães" <helder.magalhaes@...>
> To: "James Ingram" <j.ingram@...>
> Cc: <www-svg@...>
> Sent: Monday, November 01, 2010 7:19 PM
> Subject: Re: SVG and MIDI
>
> > Hi James,
> >
> >
> >> My mind has been exploding since Alex's post yesterday. Discovered that
> >> Inkpen preserves custom markup when reading and saving files... :-))
> >
> > You mean "Inkscape" [1]? ;-)
> >
> > Yeah, I guess taking the "develop an Inkscape plug-in" approach is
> > probably wise for this case. I've seen a few software packages based
> > on this approach, mostly just to embed metadata which is used for
> > behavior during run-time.
> >
> > I guess you might also find interesting (to mix/analyze/reuse) to know
> > about Audacity [2], which has some (apparently quite limited) support
> > for MIDI and whose license seems to be compatible with Inkscape's.
> >
> > Probably this is not the most appropriate mailing list for this sort
> > of details: I'd hint you to place this sort of threads in the SVG
> > Developers group [3] in the future. ;-)
> >
> >
> >> All the best,
> >> James
> >
> > Hope this helps,
> > Helder
> >
> >
> > [1] http://inkscape.org/
> > [2] http://audacity.sourceforge.net/
> > [3] http://tech.groups.yahoo.com/group/svg-developers
--------------------------------------------------------------------------
> From: ddailey <ddailey@...>
> Date: Mon, 1 Nov 2010 20:34:42 -0400
> Message-ID: <357BA9C4F35F494D83B8908F364226E5@disxgdg31szkx7>
> To: Helder Magalhães <helder.magalhaes@...>, "James Ingram"
<j.ingram@...>
> Cc: <www-svg@...>
> I would echo two of Helder's recommendations: SMIL for synchrony and
> svg-developers (on yahoo groups) as a forum to exchange such ideas. I've
> only half tuned into this thread, but for a long time I have wanted some
> sort of musical markup notation not to annotate music but to compose and
> play it (and of course interleave with graphical presentations).
>
> So something like <chord timber="flute" id="C"><note value="A,0"/><note
> value="F,0"/><note timber="trombone" value="C,1" hold="C.end+1"/><voice
> amplitude="7db" modulation="20hx"><animate animateValue="amplitude"
> from="7db" to="4db" begin="2s" dur="1s" /></chord> could be "played" while
> I'm doing a variety of other things with HTML and SVG. It would be sort of
> like having SVG but for sound and it would allow the construction of complex
> sounds. Maybe there already is something like that but I doubt that it has
> browser support to let me make music yet. And I somehow doubt that if there
> is, that they're integrating that closely with SMIL and SVG.
>
> (Musical markup : SVG) = (system sounds + audio files : installed fonts
> +<img> + HTML)
>
> Here's some fiddling I did with random music composition using audio clips
> several years ago:
> http://srufaculty.sru.edu/david.dailey/javascript/sound/sound3.html (working
> in at least IE, FF, . I'd like ot do something like that but to have direct
> access to high level sound creation resources instead of the little
> percussive voices, nice though they are)
>
> cheers
> David
--------------------------------------------------------------------------

#64168 From: "Dailey, David P." <david.dailey@...>
Date: Wed Nov 3, 2010 5:08 pm
Subject: scripted SVG inside embed or object inside HTML inside iframe inside HTML inside Moodle
david.dailey@...
Send Email Send Email
 
scripted SVG inside (embed or object) inside HTML inside iframe inside HTML
inside Moodle

Perhaps you will believe that I had a reason to try the above thing; perhaps
not:
I was explaining about the use of embed and object as a vehicle for HTML <-> SVG
scripting for a course given in Moodle. I wanted to display a working example
inline in the other HTML, so I used an iframe (which is what I just naturally
tend to use for such things).

http://srufaculty.sru.edu/david.dailey/W3CCourse/week4/SVGinHTML.html

All went well until I put it into Moodle. Has anyone else had experiences with
SVG in Moodle? Asking the Moodle folks If they had ways of making SVG work was
received like speaking Uighur in an Aztec village.

Anyhow, the curious and interesting thing, is that for IE+ASV, the <object>
example worked but the <embed> example didn't! A reversal of the conventional
finding on this subject! So, now after umpty-seven years of having to use
<embed> to do complete round-trip scripting of HTML and SVG I have discovered a
(nother)* way of getting object to work. Just as IE+ASV is preparing to
disappear from the landscape, another solution to a perplexing problem arises!

Cheers
David


*There is also
<object id="E" type="image/svg+xml" data="ovals.svg" width="320" height="240">
  <param name="src" value="ovals.svg">
</object>

See http://www.w3.org/Graphics/SVG/IG/resources/svgprimer.html#object


[Non-text portions of this message have been removed]

#64169 From: "Mr Rauf" <cute_rauf_696@...>
Date: Thu Nov 4, 2010 4:46 am
Subject: resize and draggable the group of the SVG element.....
cute_rauf_696
Send Email Send Email
 
I am working on a SVG and now want to let a user resize an object
using draggable corners, very much like in SVG-edit (http://svg-
edit.googlecode.com/svn/trunk/editor/svg-editor.html). The
functionality should work as follows: The user selects the SVG objects,
drags it to the main `canvas' and once on the `canvas', four corners
on the outside of the object appear, the user can drag on each of the
corner points & drag to enlarge the object. The objects will be
rectangular in shape and created using paths, not using the SVG `rect'
function. Would anyone have any suggestions as to how this should be
implemented?
Thanks in Advance..

#64170 From: Narendra Sisodiya <narendra@...>
Date: Thu Nov 4, 2010 6:38 pm
Subject: Re: resize and draggable the group of the SVG element.....
skysoft_siso...
Send Email Send Email
 
On Thu, Nov 4, 2010 at 10:16 AM, Mr Rauf <cute_rauf_696@...> wrote:

>
>
> I am working on a SVG and now want to let a user resize an object
> using draggable corners, very much like in SVG-edit (http://svg-
> edit.googlecode.com/svn/trunk/editor/svg-editor.html). The
> functionality should work as follows: The user selects the SVG objects,
> drags it to the main `canvas' and once on the `canvas', four corners
> on the outside of the object appear, the user can drag on each of the
> corner points & drag to enlarge the object. The objects will be
> rectangular in shape and created using paths, not using the SVG `rect'
> function. Would anyone have any suggestions as to how this should be
> implemented?
> Thanks in Advance..
>

Download SVG-Edit source Code. Read the source code of the feature you want.
Best way to read the source code of a given mistake or feature is follows.


download the latest source code the a software trunk. Let this version is
r1000

flyback to r500  (svn update -r500 , I think this is the command but you
need to check on google for flying back to old version in svn). check source
code of the binary has the given feature or not.

If it has feature the  check r250 else check revision r750.
this is like a bianary sort. Within 6-7 iterations you will be able to
locate at the exact source code which is responsible for a given feature in
a software.

Thanks.


[Non-text portions of this message have been removed]

#64171 From: "j.ingram48" <j.ingram48@...>
Date: Thu Nov 4, 2010 1:10 pm
Subject: Re: SVG and MIDI
j.ingram48
Send Email Send Email
 
Hi,

As I said before somewhere, I am currently working on an Assistant
*Composer* project, which needs to *write* SVG files containing MIDI
information. I'm going to start with the scheme described below,
though it will probably change as I go along.

Doing it like this means that clients don't need to look at the
graphics *at all* in order to play the score.

I could well imagine that this way of doing things may eventually
become the basis for an official standard, but such things take
time, and some proofs of concept...

Okay, so here's how I'm going to start:

First, a new namespace:
xmlns:midi="http://www.james-ingram-act-two/svgMidi.html"

This namespace is going to contain:
     midi:channel // for use in midi:svgType "Staff" (see below)
     midi:noteNumbers // for use in midi:svgType "Chord" (see below)
     midi:velocity // for use in midi:svgType "Chord" (see below)

The names of all the MIDI switches, controllers and commands:
     midi:patch
     midi:expression
     midi:volume
     midi:modulationWheel
     midi:breathControl
     midi:celeste
     midi:pan
     etc.

It will also contain names for sliders - controllers
which change continuously until their next instance (or some
default value):
     midi:expressionSlider
     midi:panSlider
     midi:portamentoSlider
     etc.
Sliders will probably be defined analogously to SVG's multisegment
lines, containing<startValue>,<endValue>  and<msDuration>  values.

The following types need to be defined too:
     midi:svgType="System" // a container for a sequence of "Staff"s
     midi:svgType="Staff"
     midi:svgType="Chord"
     midi:svgType="Rest"

     midi:msPos (int)
     midi:msDuration (int)

     midi:staffName (string) // My client (the Assistant Performer)
                             // needs this when setting performance
                             // options.

"System" midi:msPos is the (default) number of milliseconds from
the beginning of a performance.
"Chord" and "Rest" midi:msPos are the (default) number of
milliseconds from the beginning of the "System".
If defined, the "Chord"'s midi:msDuration defines when its noteOffs
are sent. By default, the noteOffs are sent at the time of the
following "Chord" or "Rest".

Here's an example of how I imagine using these names:

<svg xmlns="http://www.w3.org/2000/svg"
   xmlns:midi="http://www.james-ingram-act-two/svgMidi.html"  ...>

   <!-- draw page objects here (title, page numbers etc.) -->

   <!-- there will be a sequence of Systems in the page -->
   <g midi:svgType="System" midi:msPos="0">
     <!-- draw any System specific graphics here -->

     <!-- there will be a sequence of Staffs in the System -->
     <g midi:svgType="Staff" midi:staffName="Flute" midi:channel="0">
       <!-- a sequence of Chords, Rests and other objects -->
       <!-- possibly draw a clef here -->
       <!-- possibly draw a key signature here -->
       <!-- possibly draw a time signature here -->
       <g midi:svgType="chord"
          midi:msPos="0"
          midi:msDuration="3500"
          midi:midiPitches="64 67 83 90"
          midi:velocity="101"
          midi:patch="75"
          midi:expressionSlider="20 110 3500"
          <!-- etc. -->
       >
         <!-- draw the chord symbol (and any grouped objects) -->
       </g>   <!-- end of chord -->

       <g midi:svgType="Rest"
          midi:msPos="4000"
       >
         <!-- draw the rest (and any grouped objects) -->
       </g>   <!-- end of rest -->

       <!-- etc. more chords, rests, barlines etc. -->

     </g>   <!-- end of staff -->
     <!-- more Staffs -->
   </g>   <!-- end of system -->
   <!-- more Systems -->
</svg>

Does that make sense?

Is there any way to set up a special interest group for working on
this subject? Neither this forum, nor www-svg@... seem specialized enough. It
would also be nice if I could find some sponsorship of some kind...

All the best,
James

p.s. I have also sent this mail to www-svg@....

#64172 From: "jeff_schiller" <jeff_schiller@...>
Date: Thu Nov 4, 2010 7:34 pm
Subject: Re: resize and draggable the group of the SVG element.....
jeff_schiller
Send Email Send Email
 
--- In svg-developers@yahoogroups.com, "Mr Rauf" <cute_rauf_696@...> wrote:
>
> I am working on a SVG and now want to let a user resize an object
> using draggable corners, very much like in SVG-edit (http://svg-
> edit.googlecode.com/svn/trunk/editor/svg-editor.html). The
> functionality should work as follows: The user selects the SVG objects,
> drags it to the main `canvas' and once on the `canvas', four corners
> on the outside of the object appear, the user can drag on each of the
> corner points & drag to enlarge the object. The objects will be
> rectangular in shape and created using paths, not using the SVG `rect'
> function. Would anyone have any suggestions as to how this should be
> implemented?
> Thanks in Advance..
>

Here's how SVG-edit did it:

- have listeners for mousedown, mouseup, mousemove
- if an element is clicked on (in mouseup), then that is your currently selected
element
- put a 'selector box' element on top of the selected element (that has the
visible handles you can drag)
- in your mousemove, detect if a handle is being dragged, while it's being
dragged, determine what the element's new size should be and either:  a)
recompute the element's geometry to fit into that box or b) put a transform on
that element

See SVG-edit's code involving Selector, SelectorManager and
recalculateDimensions() and the mouse event handler functions.

Note that these are not trivial pieces of code and they took awhile to get into
a working state.

Best of luck,
Jeff

#64173 From: "scalablev" <svg@...>
Date: Thu Nov 4, 2010 7:58 pm
Subject: Why is SVG performance so bad in Chrome and Firefox?
scalablev
Send Email Send Email
 
Try http://kart.nois.no/pub/oye/ie9/mapfile.svg. This file renders very fast
with the Adobe SVG Viewer, but is hopeless in Chrome 7 and Firefox 3. IE7 beta
is no better. Opera and Safari are ok. Why this big difference?

#64174 From: Guy Morton <guy@...>
Date: Thu Nov 4, 2010 8:24 pm
Subject: Re: Why is SVG performance so bad in Chrome and Firefox?
guy_mmmmmm
Send Email Send Email
 
Loaded as quickly in FF3.6 on mac as it did in safari on mac...

Since Chrome and Safari use the same engine I'm surprised you're seeing a
difference between safari and chrome in terms of performance.

Guy


On 05/11/2010, at 6:58 AM, scalablev wrote:

> Try http://kart.nois.no/pub/oye/ie9/mapfile.svg. This file renders very fast
with the Adobe SVG Viewer, but is hopeless in Chrome 7 and Firefox 3. IE7 beta
is no better. Opera and Safari are ok. Why this big difference?
>
>
>
>
> ------------------------------------
>
> -----
> To unsubscribe send a message to: svg-developers-unsubscribe@yahoogroups.com
> -or-
> visit http://groups.yahoo.com/group/svg-developers and click "edit my
membership"
> ----Yahoo! Groups Links
>
>
>

#64175 From: "cremnosedum" <richard@...>
Date: Thu Nov 4, 2010 9:51 pm
Subject: Wow factors for website
cremnosedum
Send Email Send Email
 
Hi,

This is a bit off topic but SVG is my speciality and I'd like to get more work
involvin it so that should be taken into consideration.  Besides this is
probably relevant to anybody trying to use a website to get web design work.

A business contact recently said my website made it look as if my web design
skills were "old and weak".  This man claims to have taken a web design course
but I don't know if his opinion is worth a dam (and I think the way he put this
raises serious doubts about his personal and business skills - he took over my
region of an organisation I've been dealing with for some time, for most of
which it's been run badly but that's another story).

Yeah, I probably should have re-done my website a while back.  For a start it
doesn't really get me any business.  Part of the issue is that I've been trying
to attract attention with my web comic and that's got bogged down with a 3D
graphics movie that I'd like to get finished soon.

Another consideration is that I don't want to spend ages learning something that
will be obsolete or out of fashion next week or never catch on to start with
(like SVG and VRML, did X3D ever even get off the ground?).  I've heard that not
having RSS is a sign of a lame website but I've never figured out how to use it,
every site I see says it's easy but nothing actually tells me how to do it!

As a web designer I think I need a website (at least the home page) that does
NOT look like a downloaded template.

I probably also need a home page that warns people that they should view my site
with something that can display SWF and SVG.

I want something on my home page that will work on pretty well any browser
(including IE as it's unfortunately still the commonest) but people will seldom,
if ever have seen before.

Should I design for old small screens or newer larger screens?  Is it possible
to do both?

What features tend to wow people?  Are there certain colours or patterns that
are good or bad?  Should I use (or avoid) certain things: XHTML, PHP, ASP, RSS,
CSS, Javascript, Java, Facebook's like buttons etc?  Is the rotating animated
gif logo really pase?  Is there something important that I'm completely missing?
I don't know, what do people think?

Richard Pearman       http://www.pixelpalaces.com/
The next stage in the evolution of web comics:
http://www.onlinecomics.net/pages/details/listing.php?comicID=4415
Read my Helium articles: http://www.helium.com/users/212199
South Alberta Cactus and succulent society:
http://www.facebook.com/group.php?gid=20360241008

#64176 From: "jamesd" <jcdeering1@...>
Date: Fri Nov 5, 2010 9:30 pm
Subject: Organized Crime in American Web Design
jcdeering1
Send Email Send Email
 
Heard Microsoft and Firefox were going to have limited support for SVG and
decided to create a web site the way it's "Supposed" to be done for testing
purposes. Turns out they do not support SVG, but I decided to have fun anyway.

Browser Reviews site uses nested SVG files and PNG's

SVG tutorial expounds on the presentation that I gave at SVG Open 2009

Notice the file size differences between Opera and others.

There is a bug using Webkit based browsers that effects navigation. See Known
bugs first.

Anyway, the files make good test files for Google TV and others. The Sony Google
TV from experience is total crap. Beware!

Enjoy!

James

#64177 From: "jamesd" <jcdeering1@...>
Date: Fri Nov 5, 2010 9:35 pm
Subject: Forgot the URL! James
jcdeering1
Send Email Send Email
 
deerring.com

James

#64178 From: "Robert Longson" <longsonr@...>
Date: Fri Nov 5, 2010 11:15 pm
Subject: Re: Organized Crime in American Web Design
longsonr
Send Email Send Email
 
James,

What you've discovered so far is a bug in Opera rather than any conspiracy.

In order to serve compressed svg file you must specify

Content-Encoding: gzip

in your response. Correct this and all browsers will work. Here's a correctly
configured example: http://www.svgmaker.com/gallery/3dbar.svgz that you will
find it works in all browsers.

Additionally, Firefox 4 when it appears will support SMIL and SVG images, though
not SVG fonts. Firefox has supported filters since version 3.0 so I'm not sure
why you're claiming it doesn't.

Best regards

Robert.

#64179 From: "jamesd" <jcdeering1@...>
Date: Sat Nov 6, 2010 1:19 am
Subject: Re: Organized Crime in American Web Design
jcdeering1
Send Email Send Email
 
> In order to serve compressed svg file you must specify
>
> Content-Encoding: gzip
>

And where do I specify the Content-Encoding: gzip? If it is on the server and I
don't have access to it, then I stand by my statements. Adobe (No friend of SVG)
supports opening svgz file in Adobe Illustrator.

It is made difficult on purpose IMO. I do not consider this an Opera bug, but
maybe someone from Opera can chime in.

Your right Firefox does support filters, but not much else.

James
http://deerring.com.

#64180 From: Guy Morton <guy@...>
Date: Sat Nov 6, 2010 1:28 am
Subject: Re: Re: Organized Crime in American Web Design
guy_mmmmmm
Send Email Send Email
 
I agree with Robert...I think your statements are a little intemperate, and I
love a good conspiracy theory as much as the next man.

In reality, Firefox had SVG support before Safari and Chrome. All 4
browsers-other-than-IE have decent SVG support now, and it's still improving
with each release.

Your comments are, I think, a little insulting to the volunteers who work on
open-source browsers. Perhaps if you feel passionate about SVG you should
contribute your energy to either the Mozilla or Webkit browser engine projects?

Guy

PS, if your web host doesn't send the correct http headers, you should talk to
them about it, or switch to a better hosting company.



On 06/11/2010, at 12:19 PM, jamesd wrote:

>
>> In order to serve compressed svg file you must specify
>>
>> Content-Encoding: gzip
>>
>
> And where do I specify the Content-Encoding: gzip? If it is on the server and
I don't have access to it, then I stand by my statements. Adobe (No friend of
SVG) supports opening svgz file in Adobe Illustrator.
>
> It is made difficult on purpose IMO. I do not consider this an Opera bug, but
maybe someone from Opera can chime in.
>
> Your right Firefox does support filters, but not much else.
>
> James
> http://deerring.com.
>
>
>
> ------------------------------------
>
> -----
> To unsubscribe send a message to: svg-developers-unsubscribe@yahoogroups.com
> -or-
> visit http://groups.yahoo.com/group/svg-developers and click "edit my
membership"
> ----Yahoo! Groups Links
>
>
>

#64181 From: "Charles McCathieNevile" <chaals@...>
Date: Sat Nov 6, 2010 2:36 am
Subject: Re: Re: Organized Crime in American Web Design
charlesmccn
Send Email Send Email
 
On Sat, 06 Nov 2010 02:28:07 +0100, Guy Morton <guy@...> wrote:

> I agree with Robert...I think your statements are a little intemperate,
> and I love a good conspiracy theory as much as the next man.

Yay conspiracy theories...

> In reality, Firefox had SVG support before Safari and Chrome.

Indeed. Although they were kind of late to the animation party
(something that IE still hasn't done, wich I find disappointing).

> All 4 browsers-other-than-IE have decent SVG support now, and it's
> still improving with each release.

Yes. This is good - keeps us on our toes. Of course SVG is still being
developed, and even the stable release spec gets tweaked occasionally to
deal with minor inconsitencies we didn't spot. That's why we have been
partiicpating in the SVG group so long - and it's good to see that all the
major browser are doing so now.

> Your comments are, I think, a little insulting to the volunteers who
> work on open-source browsers. Perhaps if you feel passionate about SVG
> you should contribute your energy to either the Mozilla or Webkit
> browser engine projects?

Actually, producing high-quality SVG like your site is also a valuable
contribution - it gives all of the browsers something to aim for as a way
to show off what SVG can do.

> Guy
>
> PS, if your web host doesn't send the correct http headers, you should
> talk to them about it, or switch to a better hosting company.

Yeah, that fact that people have servers which don't let them set the
right headers is a real problem, and the kind of sniffing that it takes to
handle that in the browser can potentially introduce further problems.
Even in Opera Unite it is possible to set the headers, and for something
as common as SVG is becoming it is depressing that there are still hosts
that don't figure it out by default, let alone allowing you to actually
configure it (which I think should be possible on all hosting services but
unfortunately isn't).

In an ideal world, we could all just be really strict about what we do. In
the real world we are forced to make compromises. But it's also the case
that things improve. In a lot of early SVG-enabled Opera releases (version
8.x and 9.x), we accepted SVG that had a particular error to do with not
declaring the namespace. This was actually partially the fault of the WG,
who had a neat trick for allowing the namespace to be defaulted by the
DTD, but didn't anticipate the problems that might cause later.

After a few years, we stopped allowing for this behaviour. And in the
meantime, the SVG content on the Web got better, so instead of being a
major problem on most SVG content it was something we didn't even
announce, but which didn't draw any complaints.

cheers

Chaals

> On 06/11/2010, at 12:19 PM, jamesd wrote:
>
>>
>>> In order to serve compressed svg file you must specify
>>>
>>> Content-Encoding: gzip
>>>
>>
>> And where do I specify the Content-Encoding: gzip? If it is on the
>> server and I don't have access to it, then I stand by my statements.
>> Adobe (No friend of SVG) supports opening svgz file in Adobe
>> Illustrator.
>>
>> It is made difficult on purpose IMO. I do not consider this an Opera
>> bug, but maybe someone from Opera can chime in.
>>
>> Your right Firefox does support filters, but not much else.
>>
>> James
>> http://deerring.com.
>>
>>
>>
>> ------------------------------------
>>
>> -----
>> To unsubscribe send a message to:
>> svg-developers-unsubscribe@yahoogroups.com
>> -or-
>> visit http://groups.yahoo.com/group/svg-developers and click "edit my
>> membership"
>> ----Yahoo! Groups Links
>>
>>
>>
>


--
Charles McCathieNevile  Opera Software, Standards Group
      je parle français -- hablo español -- jeg lærer norsk
http://my.opera.com/chaals       Try Opera: http://www.opera.com

#64182 From: JC Ahangama <ahangama@...>
Date: Sat Nov 6, 2010 3:20 am
Subject: A less known side of SVG
jcahangama...
Send Email Send Email
 
There is a great utility SVG provides for a fifth of the population of the
planet (if they care to use it). It is not magical graphics but OpenType
feature support. It resurrects Indic Complex Scripts from the hole they fell
into due to complexities of Unicode.

The following is a link to a (sample) WordPress blog written entirely in
transliterated Sinhala displayed using a downloadable smartfont that shows
the transliteration back in the Sinhala script. (Copy the text and paste it
to Notepad to understand)
Use Firefox, Safari, Lunascape or Google Arora:
http://www.ahangama.com/

The pages depend on support for @font-family to download a WOFF font and the
'text-rendering' instruction.
Sinhala is the language spoken in Sri Lanka. It is an Indic language like
Devanagari.

JC


[Non-text portions of this message have been removed]

#64183 From: "ddailey" <ddailey@...>
Date: Sat Nov 6, 2010 11:02 am
Subject: Re: A less known side of SVG
ddailey@...
Send Email Send Email
 
Thanks JC,

The page renders very nicely in Opera as well.

I had looked at this link before when you answered a question I asked here about
displaying Unicode in SVG, and have a note to myself to study it more carefully
when time lets me. But it is good to share and recast that information more
broadly since I suspect I am not alone in my naivete.

I wonder if your methods could be applied to the Wikipedia entry at
http://en.wikipedia.org/wiki/Sinhala_language to make the characters there
display properly.

I have some students working on a browser-based font-design engine and have been
interested in a sort of grammar of the geometry of non-western fonts: is there,
for example, a class of sub-glyphs that can predict the way an orthography's
characters are formed? The Roman alphabet seems to be characterizable by a very
few graphical primitives { | , /, \ , o, c, - and hump*) glued together, so that
its "graphemic primitive set" would tend to suggest a fairly rectilinear font
designer (which indeed is the case, apparently, for the two major font design
products on the market). My sense is that, for other alphabets, syllabaries and
logographies, the geometry of font design is in many cases likely to be very
non-rectilinear. My completely ignorant view of Sinhala** and my recent quick
lesson in Arabic*** from a colleague would tend to confirm this suspicion.

cheers
David

* hump = ( n - | ) = ( u - | ) and m = ( 2*hump + | )

**I have had some Sinhala speaking students over the years, and recall finding
out that its way of doing children's Pig Latin, like Argentinian Spanish, is
very different from English. A contrastive study of multilingual Pig Latin would
be great fun to read!

***Arabic seems to have some fascinating relaxations of geometry based on
context -- the sort of things that in the acoustic realm are called
morphophonemic conditioning. (Is there such a thing as morphographemic
conditioning?) Baseline and kerning rules are often suspended and the
permissible deviations from linearity are quite striking.


   ----- Original Message -----
   From: JC Ahangama
   To: svg-developers@yahoogroups.com
   Sent: Friday, November 05, 2010 11:20 PM
   Subject: [svg-developers] A less known side of SVG



   There is a great utility SVG provides for a fifth of the population of the
   planet (if they care to use it). It is not magical graphics but OpenType
   feature support. It resurrects Indic Complex Scripts from the hole they fell
   into due to complexities of Unicode.

   The following is a link to a (sample) WordPress blog written entirely in
   transliterated Sinhala displayed using a downloadable smartfont that shows
   the transliteration back in the Sinhala script. (Copy the text and paste it
   to Notepad to understand)
   Use Firefox, Safari, Lunascape or Google Arora:
   http://www.ahangama.com/

   The pages depend on support for @font-family to download a WOFF font and the
   'text-rendering' instruction.
   Sinhala is the language spoken in Sri Lanka. It is an Indic language like
   Devanagari.

   JC

   [Non-text portions of this message have been removed]





[Non-text portions of this message have been removed]

#64184 From: "Robert Longson" <longsonr@...>
Date: Sat Nov 6, 2010 2:07 pm
Subject: Re: Organized Crime in American Web Design
longsonr
Send Email Send Email
 
> And where do I specify the Content-Encoding: gzip? If it is on the server and
I don't have access to it, then I stand by my statements. Adobe (No friend of
SVG) supports opening svgz file in Adobe Illustrator.

So if the problem is with your web host then it's still the browser's fault. If
drove your cat towards a bridge, ignoring the signs and the people who tell you
that the bridge is out and you crash, that's a problem with the car in your
world I guess.

Adobe Illustrator isn't a web application, Content-Encoding does not apply to
it.

> It is made difficult on purpose IMO. I do not consider this an Opera bug, but
maybe someone from Opera can chime in.

You are wrong again, it's made this way because the specifications that
originate with the international standards body, the w3c say it should work that
way in order to be interoperable.

Best regards

Robert.

#64185 From: "Erik Dahlstrom" <ed@...>
Date: Sun Nov 7, 2010 1:53 pm
Subject: Re: Re: Organized Crime in American Web Design
erida539
Send Email Send Email
 
On Sat, 06 Nov 2010 02:19:49 +0100, jamesd <jcdeering1@...> wrote:

>
>> In order to serve compressed svg file you must specify
>>
>> Content-Encoding: gzip
>>
>
> And where do I specify the Content-Encoding: gzip? If it is on the
> server and I don't have access to it, then I stand by my statements.

If you put your content on the server then I think you do have access.
According to the headers your server is Apache, so try uploading a file
named ".htaccess" (without the quotes) with the following raw text content:

# Adding the SVG media type and encoding in case they aren't already
AddType     image/svg+xml             svg svgz
AddEncoding gzip                      svgz
AddCharset  utf-8 .svg


If you want, you don't actually have to rename your files to *.svgz, and
instead just let the server transmit the files using gzip compression
automatically. To get this you can append the following to the .htaccess
file:

# gzip compression.
<IfModule mod_deflate.c>
    # html, txt, css, js, json, xml, htc:
    AddOutputFilterByType DEFLATE text/html text/plain text/css
application/json
    AddOutputFilterByType DEFLATE text/javascript application/javascript
application/x-javascript
    AddOutputFilterByType DEFLATE text/xml application/xml text/x-component

    # webfonts and svg:
    <FilesMatch "\.(ttf|otf|eot|svg)$" >
      SetOutputFilter DEFLATE
    </FilesMatch>
</IfModule>


To conclude I would like to recommend browsing the following two sites for
some tips & tricks on serving web content:

    http://html5boilerplate.com
    http://svgboilerplate.com

Cheers
/Erik

--
Erik Dahlstrom, Core Technology Developer, Opera Software
Co-Chair, W3C SVG Working Group
Personal blog: http://my.opera.com/macdev_ed

#64186 From: "th_w@..." <th_w@...>
Date: Sun Nov 7, 2010 2:43 pm
Subject: Re: Organized Crime in American Web Design
th_w@ymail.com
Send Email Send Email
 
--- In svg-developers@yahoogroups.com, "Erik Dahlstrom" <ed@...> wrote:
>
> On Sat, 06 Nov 2010 02:19:49 +0100, jamesd <jcdeering1@...> wrote:
>
> >
> >> In order to serve compressed svg file you must specify
> >>
> >> Content-Encoding: gzip
> >>
> >
> > And where do I specify the Content-Encoding: gzip? If it is on the
> > server and I don't have access to it, then I stand by my statements.
>
> If you put your content on the server then I think you do have access.
> According to the headers your server is Apache, so try uploading a file
> named ".htaccess" (without the quotes) with the following raw text content:
>
> # Adding the SVG media type and encoding in case they aren't already
> AddType     image/svg+xml             svg svgz
> AddEncoding gzip                      svgz
> AddCharset  utf-8 .svg
>
>
> If you want, you don't actually have to rename your files to *.svgz, and
> instead just let the server transmit the files using gzip compression
> automatically. To get this you can append the following to the .htaccess
> file:
>
> # gzip compression.
> <IfModule mod_deflate.c>
>    # html, txt, css, js, json, xml, htc:
>    AddOutputFilterByType DEFLATE text/html text/plain text/css
> application/json
>    AddOutputFilterByType DEFLATE text/javascript application/javascript
> application/x-javascript
>    AddOutputFilterByType DEFLATE text/xml application/xml text/x-component
>
>    # webfonts and svg:
>    <FilesMatch "\.(ttf|otf|eot|svg)$" >
>      SetOutputFilter DEFLATE
>    </FilesMatch>
> </IfModule>
>
>

Yeah, you can count on the Good Guys from Europe!  In your face, American Web
Design Criminals!

Kidding aside, many thanks for this post!  Up to now I uploaded my SVG and XSLT
files with extension .xml.  That works, but it's nicer with the proper
extension.

Thomas W.

#64187 From: Cameron Laird <claird@...>
Date: Sun Nov 7, 2010 4:35 pm
Subject: Re: how to visualise an arbitrary size matrix with svg?
Cameron_Laird
Send Email Send Email
 
On Sun, Oct 24, 2010 at 02:15:20PM +0100, Jonathan Chetwynd wrote:
			 .
			 .
			 .
> 2 Queries around the same idea:
>
> 1: Is there a simple way to visualise an arbitrary size matrix with svg?
> ie say: vary opacity or hue, as a gradient over another arbitrary size
> rectangle.
>
> very basic method: fill in a rectangle for each value  in the matrix
>
> one longwinded method: use radial gradient with
> one stop 0.24 and another using a 3x3 kernel to give an average value
> ~0.2575**
> and a radius calculated from the scale of the matrix (19x19) to the
> displayed size of the  graphic
>
>
> 2: is there a way to input colour or alpha values  for an image
> directly?
> as suggested here: "To illustrate, suppose you have a input image
> which is 5 pixels by 5 pixels, whose color values for one of the color
> channels are as follows:"
> http://www.w3.org/TR/SVG/filters.html#feConvolveMatrixElement
>
> Jonathan
>
> **using the value at the second row and second column of the matrix
> attached:
			 .
			 .
			 .
I know mathematics, and SVG, but I truly don't see the
connection you're making here.  I suspect a lot of it
has to do with "simple way"--no, it's a certainty that
pathologic cases will break any such scheme you propose,
but, yes, if you have information about the matrix that
perhaps is obvious to you, but I don't apprehend, then
useful visualizations are feasible.

I'd love to understand better what you have in mind.
What would it take to make a minimal example of "matrix
visualization" for you?

#64188 From: "ddailey" <ddailey@...>
Date: Mon Nov 8, 2010 3:07 am
Subject: canonical expressions -- part 1
ddailey@...
Send Email Send Email
 
[Part 1 is background. Part 2 is the part that makes the most sense to read:
practical questions. Part 3 is a generalization pertaining to the nature of
writing and visual expression with finite alphabets.]

One of the many things that appeals to some of its enthusiasts about SVG SMIL*
is its sparseness and elegance. Having the  animation "close" (in the
document/reading/authoring sense)  to the objects being animated **  makes good
semantic sense.***

But beyond the good sense of having things close to the very properties that
define their uniqueness, there is the sheer parsimony of it all. Having fewer
keystrokes translates (often) into more understandable and maintainable code.
****

A similar sense of elegance in areas, not necessarily involving animation,
appeals to others in the SVG community because there is a sense, in so many
instances, that of all the intriguingly different ways of making the same
"picture" with SVG, some are obviously "better".*****

One of my students recently inquired about sources for public domain SVG
imagery. The obvious repository, thanks in large part to the Inkscape community,
is http://www.openclipart.org/ . Another of my students inquired about accessing
those images through server-side scripts to dynamically bring them into web
pages, and this, of course, made me go and revisit some of the sodipodi-infested
discards and treasures at that site.****** .

From there I visited Wikimedia Commons, another good source of iconography. That
is where part 2 of this story commences.

:)
David

*as differentiated from SMIL, and as differentiated from "SVG animation" which
might be any of a variety of animation techniques including SVG SMIL and
scripted animation (either through JavaScript timing or through AJAX)

**rather than tucked away in some possibly encrypted CSS file served from an
off-shore data-warehouse

*** which means enhanced accessibility in, at least, some universe.

****Though developing ISO 14000 guidelines for declarative programming is
probably a decade or two away since we'll have to revamp ISO 14000 to become
parsimony-compliant first, and that will require a needs analysis that is,
itself,  ISO 14000 compliant)

***** though it would be hard to characterize what "better" means, in a way that
would generalize beyond the uniqueness of particular circumstances.

******  The treasures there are numerous, but they are often neither scriptable
nor accessible. I have written some scripts to help add descriptors to the
content, but it made me wonder again about the overall efficacy of
robot-generated tags for human accessibility. Where does garbage go in the
information age?

[Non-text portions of this message have been removed]

#64189 From: "ddailey" <ddailey@...>
Date: Mon Nov 8, 2010 4:31 am
Subject: Re: canonical expressions -- part 2: A challenge: accessbility and symbols of the public domain (wikipedia)
ddailey@...
Send Email Send Email
 
Challenge: come up with "better" symbols for signifying "public domain" or
"copyright free."

Begin here http://granite.sru.edu/~ddailey/svg/pd3.svg . Look at the source code
and then see what you think. I'll get back to that example toward the end of
this message.

As a bit of searching in Google Images*, Wikipedia and Wikimedia Commons will
reveal,  there are several symbols meant to depict the concepts of "copyright
free" or "public domain" or "copyleft." Not only do these concepts have slightly
different nuances of meaning, but the symbols have a many-to-many relationship
with the concepts. And furthermore, the symbols have differential levels of
accessibity, depending on for whom we define "making" "allowing" or "enabling" 
to be accessible. And, many of the symbols, while looking alike, have very
different underlying file structure.

Following a recent visit to openclipart.org**  I was rather prepared for what
Jeff Schiller calls "cruft"  when I saw the earlier image at
http://commons.wikimedia.org/wiki/File:Publicdomain.svg
as described there.I did the following   [Hand edited to remove sodipodi and
inkscape references, remove unused gradients, remove unused styles, replaced
duplicated paths by <use> elements, simplified complex cubic beziers as simple
arc subcommands; used integer arithmetic. Replaced complex arcs by circles. New
file is 18 (<lkb) lines of code -- old file was 144 lines (>5kb). New file
should have better semantics for re-editing basic objects.]

Well 18 lines and 895 bytes defintely seems better than 5 kilobytes of code. But
is the new code more accessible? Well, I think it is, but how can I tell for
sure? How does one come up with the "best" expression for such a simple figure?

Look inside the two figures and you'll see several questions that pose
themselves:
is it better to use <use>?
does striking all the sodipodi stuff erase some of the artist's brushstrokes?***
are two paths with one rotating the other better than one that has twice as
coordinates listed?
doesn't it make more sense to let color be inherited from the group rather than
individually defined for each path?
what about the optical illusion of the letters pd for public domain? Should that
be made semantic in our markup?

I confess it took me a while of fidding to replace all those cubic beziers from
Inkscape by the "canonical" arc-equivalents. But I figure that the seven
coordinates (or so) that I used,  instead of sixty or so in the original path
ought to make the content more accessible to future analysists if anyone ever
wants to modify it!

Next question (and maybe more important):

Take a look at http://granite.sru.edu/~ddailey/svg/pd3.svg

The image on the left is one of the current images served by wikimedia as the
symbol for "copyright free".[2]  Perhaps it is based on [3] . Perhaps the
metadata associated with the file should show its ancestry?

The file history shows some well-deserved attempt to rid the file of unneeded
complexity and cruft.
The current image (in its eleventh incarnation on wikipedia). It consists of
four circles and three rectangles. One of the rectangles looks like it has been
added merely to carve out a portion of a circle to make it look like a "c." This
doesn't seem very accessible.

So in my quick attempt, I put a "c" in the middle of the circle. I defined the
circle as not two circles but one. I defined the rectangle as not two but one,
and I defined the "C" as not two circles and a rectangle, but as a "c". I also
made a stab at adding <title> and <desc> tags to describe the "why and what" of
the file.

So here is the challenge: can we come up with a better version of the symbol
that what is there right now?

Can we come up with one we will all agree is better?

What I don't like about my attempt is that the "C" is dependent upon system
fonts??? Changing from sans-serif to arial makes a huge difference in some
browsers!

Should the circle be one circle or two?

Should the circle really be carved by a clipPath consisting of two arcs or
should it be a circle with a line (rect) that crosses it? I chose a crossing
line but was not convinced this was right.

I stretched the "C" horizontally to make it appear to conform to the circle
outside. Circles would have conformed better!

What is the canonical <title> and <desc> information to go with the proper file?

What is the proper way to refer to this discussion thread should we ever agree
on my desire to replace the four circles and three rects

cheers
David

*I discovered to my great dismay that Ditto.com, as of about 6 months ago, no
longer exists[1]. Their lawsuit paved the way for Google images which followed
almost to the day the initial ruling in favor of Ditto.com.

**After spending a bit of time reminding myself of why I (wearing various hats
that I do) don't use more images from http://www.openclipart.org/ , I wrote a
bit of script to help me find the relevant <path> objects (amidst gradients and
filters that are never used) that actually draw the interesting shapes
(assigning mouseover event that parse and modify the "style" of the active
object).

*** I remember in the 1980's trying to help students (and a wife) recover their
corrupted word-processed files and realizing that the archival copy actually
contained not only the document but the "edit history" of the document including
backspaces, deletes, copies and pastes!

[1] http://srufaculty.sru.edu/david.dailey/copyright/legalthumb.htm
[2] http://en.wikipedia.org/wiki/File:PD-icon.svg

[3] http://en.wikipedia.org/wiki/File:Red_copyright.svg

[Non-text portions of this message have been removed]

#64190 From: "bruce" <bruce.rindahl@...>
Date: Mon Nov 8, 2010 5:06 am
Subject: Re: fun but buggy -- gears
brucerindahl
Send Email Send Email
 
Here is another interesting animation in the same vein.  It shows two sliding
blocks, one moving horizontally and the other moving vertically.  A rod is pined
to the centers of the two blocks.  When this is done the motion of the ends of
the rod traces ellipses.  The following works in IE/ASV, FF4, WebKit, and Opera
but interestingly does not work in Batik.

------------------------------------------------------------
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN"
           "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd" [
   <!ENTITY dur "9s">
   <!ENTITY hCirCW "M -25 0 A 25 25 0 1 1 25 0 A 25 25 0 1 1 -25 0">
   <!ENTITY hCirCCW "M -25 0 A 25 25 0 1 0 25 0 A 25 25 0 1 0 -25 0">
   <!ENTITY vCirCW "M -25 0 A 25 25 0 1 1 25 0 A 25 25 0 1 1 -25 0">
   <!ENTITY vCirCCW "M 25 0 A 25 25 0 1 0 -25 0 A 25 25 0 1 0 25 0">
]>

<svg width="100%" height="100%" viewBox="-100 -125 200 250"
  xmlns="http://www.w3.org/2000/svg" >

<rect x="-75" y="-75" width="150" height="150" fill="blue" />
<rect x="-75" y="-10" width="150" height="20" fill="gray" />
<rect x="-10" y="-75" width="20" height="150" fill="gray" />
<g>
	 <animateMotion begin="0s" dur="&dur;" path="&hCirCW;" repeatCount="indefinite"
/>
	 <rect x="-20" y="-10" width="40" height="20" fill="green" >
	 <animateMotion begin="0s" dur="&dur;" path="&hCirCCW;" repeatCount="indefinite"
/>
	 </rect>
</g>

<g>
	 <animateMotion begin="0s" dur="&dur;" path="&vCirCW;" repeatCount="indefinite"
/>
	 <rect x="-10" y="-20" width="20" height="40" fill="green" >
	 <animateMotion begin="0s" dur="&dur;" path="&vCirCCW;" repeatCount="indefinite"
/>
	 </rect>
</g>

<g>
	 <animateMotion begin="0s" dur="&dur;" path="&hCirCW;" repeatCount="indefinite"
/>
	 <line x1="100" y1="0" x2="-50" y2="0" stroke-width="5" stroke="black"
stroke-linecap="round" >
       <animateTransform attributeName="transform" attributeType="XML"
            type="rotate" from="0" to="-360"
            begin="0s" dur="&dur;" repeatCount="indefinite" />
	 <animateMotion begin="0s" dur="&dur;" path="&hCirCCW;" repeatCount="indefinite"
/>
	 </line>
</g>
<g>
	 <animateMotion begin="0s" dur="&dur;" path="&hCirCW;" repeatCount="indefinite"
/>
	 <circle x="0" y="0" r="1"  fill="yellow" >
	 <animateMotion begin="0s" dur="&dur;" path="&hCirCCW;" repeatCount="indefinite"
/>
	 </circle>
</g>
<g>
	 <animateMotion begin="0s" dur="&dur;" path="&vCirCW;" repeatCount="indefinite"
/>
	 <circle x="0" y="0" r="1"  fill="yellow" >
	 <animateMotion begin="0s" dur="&dur;" path="&vCirCCW;" repeatCount="indefinite"
/>
	 </circle>
</g>

<ellipse cx="0" cy="0" rx="50" ry="100"
fill="none" stroke="red" stroke-width="0.2"  />
<ellipse cx="0" cy="0" rx="100" ry="50"
fill="none" stroke="red" stroke-width="0.2"  />

</svg>
-----------------------------------------------------------------

The really strange thing is an early version of this file.  I thought it would
be simple to replicate the code for one block and rotate it by 90 degrees to get
the second block.  It didn't work but rotating it 180 degrees did (in Chrome
where I was testing).  When I thought I was done, I checked in FF4 - same
result.  In Opera, I got radically different results.  IE/ASV showed the same as
Opera.  I believe Opera and ASV have the behavior correctly as I coded it. 
Again Batik does not show the rod correctly  but shows the blocks as ASV and
Opera.
Any idea why FF4 and WebKit show the same but different display?

--------------------------------------------------------------------
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN"
           "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd" [
   <!ENTITY dur "9s">
   <!ENTITY largeCirCW "M -25 0 A 25 25 0 1 1 25 0 A 25 25 0 1 1 -25 0">
   <!ENTITY largeCirCCW "M -25 0 A 25 25 0 1 0 25 0 A 25 25 0 1 0 -25 0">
]>

<svg width="100%" height="100%" viewBox="-100 -150 200 300"
  xmlns="http://www.w3.org/2000/svg" >

<rect x="-75" y="-75" width="150" height="150" fill="blue" />
<rect x="-75" y="-10" width="150" height="20" fill="gray" />
<rect x="-10" y="-75" width="20" height="150" fill="gray" />
<g>
	 <animateMotion begin="0s" dur="&dur;" path="&largeCirCW;"
repeatCount="indefinite" />
	 <rect x="-20" y="-10" width="40" height="20" fill="green" >
	 <animateMotion begin="0s" dur="&dur;" path="&largeCirCCW;"
repeatCount="indefinite" />
	 </rect>
</g>

<g transform="rotate(180)">
	 <animateMotion begin="0s" dur="&dur;" path="&largeCirCW;"
repeatCount="indefinite" />
	 <rect x="-10" y="-20" width="20" height="40" fill="green" >
	 <animateMotion begin="0s" dur="&dur;" path="&largeCirCCW;"
repeatCount="indefinite" />
	 </rect>
</g>

<g>
	 <animateMotion begin="0s" dur="&dur;" path="&largeCirCW;"
repeatCount="indefinite" />
	 <line x1="100" y1="0" x2="0" y2="0" stroke-width="5" stroke="black"
stroke-linecap="round" >
       <animateTransform attributeName="transform" attributeType="XML"
            type="rotate" from="0" to="-360"
            begin="0s" dur="&dur;" repeatCount="indefinite" />
	 <animateMotion begin="0s" dur="&dur;" path="&largeCirCCW;"
repeatCount="indefinite" />
	 </line>
</g>
<g>
	 <animateMotion begin="0s" dur="&dur;" path="&largeCirCW;"
repeatCount="indefinite" />
	 <circle x="0" y="0" r="1"  fill="yellow" >
	 <animateMotion begin="0s" dur="&dur;" path="&largeCirCCW;"
repeatCount="indefinite" />
	 </circle>
</g>
<g transform="rotate(180)">
	 <animateMotion begin="0s" dur="&dur;" path="&largeCirCW;"
repeatCount="indefinite" />
	 <circle x="0" y="0" r="1"  fill="yellow" >
	 <animateMotion begin="0s" dur="&dur;" path="&largeCirCCW;"
repeatCount="indefinite" />
	 </circle>
</g>

<ellipse cx="0" cy="0" rx="50" ry="100"
fill="none" stroke="red" stroke-width="0.2"  />

</svg>
-------------------------------------------------------------------

Bruce

#64191 From: "ddailey" <ddailey@...>
Date: Mon Nov 8, 2010 5:07 am
Subject: Re: canonical expressions -- part 3: more efficient ways of packing text into rectangles
ddailey@...
Send Email Send Email
 
The concept of "how best" to write something got me wondering about the
following.

Using an alphabet or a syllabary (like most of the languages of the world
excepting Chinese, Japanese, Mayan, and a few hundred others)  how much "space"
does it take to convey our meaning.*

Here's the question: if we relax the rules of English orthography just a bit, so
that instead of writing from left to write, we write from left to right, or
downward, or inward (by allowing glyphs to be "inside" one another) , can we
write legibly in less space?

http://granite.sru.edu/~ddailey/svg/canonical.svg

This link shows a way of packing letters into a space under the relaxed rules of
right-or-down-or-inside.

If we confine legibility by some empirically defined threshold on the minimum
size of a glyph, then if we allow physics to constrain the two dimensional
placement of our glyphs, subject to rotation scaling and translation, to pack
tightly, then can we find ways of expressing English (or another language using
some alphabet) using less space than by writing simply unidirectionally?

Vincent Hardy's work with cameras at http://svg-wow.org/blog/2010/08/14/camera/
reinforces this idea that writing need not be unidirectional. And from many
languages we know that it need not be. By what grammar might we guide the
maximization of our expressiveness per unit of space and time?

cheers
David

* As a kid I subscribed to Quino Lingo and observed that English took up far
less room, on average, that French, Spanish, Italian, Russian, German, Latin or
Basque. I studied Navajo as a big kid and can testify that it takes up *room* to
write it, though not so extravagantly as most languages. Chinese seems to be
quite effective.

   ----- Original Message -----
   From: ddailey
   To: svg-developers@yahoogroups.com
   Sent: Sunday, November 07, 2010 11:31 PM
   Subject: Re: [svg-developers] canonical expressions -- part 2: A challenge:
accessbility and symbols of the public domain (wikipedia)



   Challenge: come up with "better" symbols for signifying "public domain" or
"copyright free."

   Begin here http://granite.sru.edu/~ddailey/svg/pd3.svg . Look at the source
code and then see what you think. I'll get back to that example toward the end
of this message.

   As a bit of searching in Google Images*, Wikipedia and Wikimedia Commons will
reveal, there are several symbols meant to depict the concepts of "copyright
free" or "public domain" or "copyleft." Not only do these concepts have slightly
different nuances of meaning, but the symbols have a many-to-many relationship
with the concepts. And furthermore, the symbols have differential levels of
accessibity, depending on for whom we define "making" "allowing" or "enabling"
to be accessible. And, many of the symbols, while looking alike, have very
different underlying file structure.

   Following a recent visit to openclipart.org** I was rather prepared for what
Jeff Schiller calls "cruft" when I saw the earlier image at
http://commons.wikimedia.org/wiki/File:Publicdomain.svg
   as described there.I did the following [Hand edited to remove sodipodi and
inkscape references, remove unused gradients, remove unused styles, replaced
duplicated paths by <use> elements, simplified complex cubic beziers as simple
arc subcommands; used integer arithmetic. Replaced complex arcs by circles. New
file is 18 (<lkb) lines of code -- old file was 144 lines (>5kb). New file
should have better semantics for re-editing basic objects.]

   Well 18 lines and 895 bytes defintely seems better than 5 kilobytes of code.
But is the new code more accessible? Well, I think it is, but how can I tell for
sure? How does one come up with the "best" expression for such a simple figure?

   Look inside the two figures and you'll see several questions that pose
themselves:
   is it better to use <use>?
   does striking all the sodipodi stuff erase some of the artist's
brushstrokes?***
   are two paths with one rotating the other better than one that has twice as
coordinates listed?
   doesn't it make more sense to let color be inherited from the group rather
than individually defined for each path?
   what about the optical illusion of the letters pd for public domain? Should
that be made semantic in our markup?

   I confess it took me a while of fidding to replace all those cubic beziers
from Inkscape by the "canonical" arc-equivalents. But I figure that the seven
coordinates (or so) that I used, instead of sixty or so in the original path
ought to make the content more accessible to future analysists if anyone ever
wants to modify it!

   Next question (and maybe more important):

   Take a look at http://granite.sru.edu/~ddailey/svg/pd3.svg

   The image on the left is one of the current images served by wikimedia as the
symbol for "copyright free".[2] Perhaps it is based on [3] . Perhaps the
metadata associated with the file should show its ancestry?

   The file history shows some well-deserved attempt to rid the file of unneeded
complexity and cruft.
   The current image (in its eleventh incarnation on wikipedia). It consists of
four circles and three rectangles. One of the rectangles looks like it has been
added merely to carve out a portion of a circle to make it look like a "c." This
doesn't seem very accessible.

   So in my quick attempt, I put a "c" in the middle of the circle. I defined the
circle as not two circles but one. I defined the rectangle as not two but one,
and I defined the "C" as not two circles and a rectangle, but as a "c". I also
made a stab at adding <title> and <desc> tags to describe the "why and what" of
the file.

   So here is the challenge: can we come up with a better version of the symbol
that what is there right now?

   Can we come up with one we will all agree is better?

   What I don't like about my attempt is that the "C" is dependent upon system
fonts??? Changing from sans-serif to arial makes a huge difference in some
browsers!

   Should the circle be one circle or two?

   Should the circle really be carved by a clipPath consisting of two arcs or
should it be a circle with a line (rect) that crosses it? I chose a crossing
line but was not convinced this was right.

   I stretched the "C" horizontally to make it appear to conform to the circle
outside. Circles would have conformed better!

   What is the canonical <title> and <desc> information to go with the proper
file?

   What is the proper way to refer to this discussion thread should we ever agree
on my desire to replace the four circles and three rects

   cheers
   David

   *I discovered to my great dismay that Ditto.com, as of about 6 months ago, no
longer exists[1]. Their lawsuit paved the way for Google images which followed
almost to the day the initial ruling in favor of Ditto.com.

   **After spending a bit of time reminding myself of why I (wearing various hats
that I do) don't use more images from http://www.openclipart.org/ , I wrote a
bit of script to help me find the relevant <path> objects (amidst gradients and
filters that are never used) that actually draw the interesting shapes
(assigning mouseover event that parse and modify the "style" of the active
object).

   *** I remember in the 1980's trying to help students (and a wife) recover
their corrupted word-processed files and realizing that the archival copy
actually contained not only the document but the "edit history" of the document
including backspaces, deletes, copies and pastes!

   [1] http://srufaculty.sru.edu/david.dailey/copyright/legalthumb.htm
   [2] http://en.wikipedia.org/wiki/File:PD-icon.svg

   [3] http://en.wikipedia.org/wiki/File:Red_copyright.svg

   [Non-text portions of this message have been removed]





[Non-text portions of this message have been removed]

#64192 From: "ddailey" <ddailey@...>
Date: Mon Nov 8, 2010 5:46 am
Subject: Re: Re: fun but buggy -- gears
ddailey@...
Send Email Send Email
 
Great job! Declarative machinery is the best machinery!

cheers
David
   ----- Original Message -----
   From: bruce
   To: svg-developers@yahoogroups.com
   Sent: Monday, November 08, 2010 12:06 AM
   Subject: [svg-developers] Re: fun but buggy -- gears



   Here is another interesting animation in the same vein. It shows two sliding
blocks, one moving horizontally and the other moving vertically. A rod is pined
to the centers of the two blocks. When this is done the motion of the ends of
the rod traces ellipses. The following works in IE/ASV, FF4, WebKit, and Opera
but interestingly does not work in Batik.

   ----------------------------------------------------------
   <?xml version="1.0" standalone="no"?>
   <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN"
   "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd" [
   <!ENTITY dur "9s">
   <!ENTITY hCirCW "M -25 0 A 25 25 0 1 1 25 0 A 25 25 0 1 1 -25 0">
   <!ENTITY hCirCCW "M -25 0 A 25 25 0 1 0 25 0 A 25 25 0 1 0 -25 0">
   <!ENTITY vCirCW "M -25 0 A 25 25 0 1 1 25 0 A 25 25 0 1 1 -25 0">
   <!ENTITY vCirCCW "M 25 0 A 25 25 0 1 0 -25 0 A 25 25 0 1 0 25 0">
   ]>

   <svg width="100%" height="100%" viewBox="-100 -125 200 250"
   xmlns="http://www.w3.org/2000/svg" >

   <rect x="-75" y="-75" width="150" height="150" fill="blue" />
   <rect x="-75" y="-10" width="150" height="20" fill="gray" />
   <rect x="-10" y="-75" width="20" height="150" fill="gray" />
   <g>
   <animateMotion begin="0s" dur="&dur;" path="&hCirCW;" repeatCount="indefinite"
/>
   <rect x="-20" y="-10" width="40" height="20" fill="green" >
   <animateMotion begin="0s" dur="&dur;" path="&hCirCCW;"
repeatCount="indefinite" />
   </rect>
   </g>

   <g>
   <animateMotion begin="0s" dur="&dur;" path="&vCirCW;" repeatCount="indefinite"
/>
   <rect x="-10" y="-20" width="20" height="40" fill="green" >
   <animateMotion begin="0s" dur="&dur;" path="&vCirCCW;"
repeatCount="indefinite" />
   </rect>
   </g>

   <g>
   <animateMotion begin="0s" dur="&dur;" path="&hCirCW;" repeatCount="indefinite"
/>
   <line x1="100" y1="0" x2="-50" y2="0" stroke-width="5" stroke="black"
stroke-linecap="round" >
   <animateTransform attributeName="transform" attributeType="XML"
   type="rotate" from="0" to="-360"
   begin="0s" dur="&dur;" repeatCount="indefinite" />
   <animateMotion begin="0s" dur="&dur;" path="&hCirCCW;"
repeatCount="indefinite" />
   </line>
   </g>
   <g>
   <animateMotion begin="0s" dur="&dur;" path="&hCirCW;" repeatCount="indefinite"
/>
   <circle x="0" y="0" r="1" fill="yellow" >
   <animateMotion begin="0s" dur="&dur;" path="&hCirCCW;"
repeatCount="indefinite" />
   </circle>
   </g>
   <g>
   <animateMotion begin="0s" dur="&dur;" path="&vCirCW;" repeatCount="indefinite"
/>
   <circle x="0" y="0" r="1" fill="yellow" >
   <animateMotion begin="0s" dur="&dur;" path="&vCirCCW;"
repeatCount="indefinite" />
   </circle>
   </g>

   <ellipse cx="0" cy="0" rx="50" ry="100"
   fill="none" stroke="red" stroke-width="0.2" />
   <ellipse cx="0" cy="0" rx="100" ry="50"
   fill="none" stroke="red" stroke-width="0.2" />

   </svg>
   ----------------------------------------------------------

   The really strange thing is an early version of this file. I thought it would
be simple to replicate the code for one block and rotate it by 90 degrees to get
the second block. It didn't work but rotating it 180 degrees did (in Chrome
where I was testing). When I thought I was done, I checked in FF4 - same result.
In Opera, I got radically different results. IE/ASV showed the same as Opera. I
believe Opera and ASV have the behavior correctly as I coded it. Again Batik
does not show the rod correctly but shows the blocks as ASV and Opera.
   Any idea why FF4 and WebKit show the same but different display?

   ----------------------------------------------------------
   <?xml version="1.0" standalone="no"?>
   <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN"
   "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd" [
   <!ENTITY dur "9s">
   <!ENTITY largeCirCW "M -25 0 A 25 25 0 1 1 25 0 A 25 25 0 1 1 -25 0">
   <!ENTITY largeCirCCW "M -25 0 A 25 25 0 1 0 25 0 A 25 25 0 1 0 -25 0">
   ]>

   <svg width="100%" height="100%" viewBox="-100 -150 200 300"
   xmlns="http://www.w3.org/2000/svg" >

   <rect x="-75" y="-75" width="150" height="150" fill="blue" />
   <rect x="-75" y="-10" width="150" height="20" fill="gray" />
   <rect x="-10" y="-75" width="20" height="150" fill="gray" />
   <g>
   <animateMotion begin="0s" dur="&dur;" path="&largeCirCW;"
repeatCount="indefinite" />
   <rect x="-20" y="-10" width="40" height="20" fill="green" >
   <animateMotion begin="0s" dur="&dur;" path="&largeCirCCW;"
repeatCount="indefinite" />
   </rect>
   </g>

   <g transform="rotate(180)">
   <animateMotion begin="0s" dur="&dur;" path="&largeCirCW;"
repeatCount="indefinite" />
   <rect x="-10" y="-20" width="20" height="40" fill="green" >
   <animateMotion begin="0s" dur="&dur;" path="&largeCirCCW;"
repeatCount="indefinite" />
   </rect>
   </g>

   <g>
   <animateMotion begin="0s" dur="&dur;" path="&largeCirCW;"
repeatCount="indefinite" />
   <line x1="100" y1="0" x2="0" y2="0" stroke-width="5" stroke="black"
stroke-linecap="round" >
   <animateTransform attributeName="transform" attributeType="XML"
   type="rotate" from="0" to="-360"
   begin="0s" dur="&dur;" repeatCount="indefinite" />
   <animateMotion begin="0s" dur="&dur;" path="&largeCirCCW;"
repeatCount="indefinite" />
   </line>
   </g>
   <g>
   <animateMotion begin="0s" dur="&dur;" path="&largeCirCW;"
repeatCount="indefinite" />
   <circle x="0" y="0" r="1" fill="yellow" >
   <animateMotion begin="0s" dur="&dur;" path="&largeCirCCW;"
repeatCount="indefinite" />
   </circle>
   </g>
   <g transform="rotate(180)">
   <animateMotion begin="0s" dur="&dur;" path="&largeCirCW;"
repeatCount="indefinite" />
   <circle x="0" y="0" r="1" fill="yellow" >
   <animateMotion begin="0s" dur="&dur;" path="&largeCirCCW;"
repeatCount="indefinite" />
   </circle>
   </g>

   <ellipse cx="0" cy="0" rx="50" ry="100"
   fill="none" stroke="red" stroke-width="0.2" />

   </svg>
   ----------------------------------------------------------

   Bruce





[Non-text portions of this message have been removed]

#64193 From: Jacob Beard <jbeard4@...>
Date: Mon Nov 8, 2010 9:19 am
Subject: Re: canonical expressions -- part 3: more efficient ways of packing text into rectangles
jbeard4@...
Send Email Send Email
 
On 10-11-08 06:07 AM, ddailey wrote:
>
> The concept of "how best" to write something got me wondering about
> the following.
>
> Using an alphabet or a syllabary (like most of the languages of the
> world excepting Chinese, Japanese, Mayan, and a few hundred others)
> how much "space" does it take to convey our meaning.*
>
> Here's the question: if we relax the rules of English orthography just
> a bit, so that instead of writing from left to write, we write from
> left to right, or downward, or inward (by allowing glyphs to be
> "inside" one another) , can we write legibly in less space?
>
> http://granite.sru.edu/~ddailey/svg/canonical.svg
> <http://granite.sru.edu/%7Eddailey/svg/canonical.svg>
>
> This link shows a way of packing letters into a space under the
> relaxed rules of right-or-down-or-inside.
>
> If we confine legibility by some empirically defined threshold on the
> minimum size of a glyph, then if we allow physics to constrain the two
> dimensional placement of our glyphs, subject to rotation scaling and
> translation, to pack tightly, then can we find ways of expressing
> English (or another language using some alphabet) using less space
> than by writing simply unidirectionally?
>
That's pretty interesting. I think there's a bit of work from the field
of visual modelling that might be useful and relevant here. For one
thing, it would probably be useful to formally define a notion of
"insideness" in the language definition of your graphical language (the
"abstract syntax of the concrete syntax", in use modelling parlance). In
your language definition, you would probably say that each glyph may
have some region in which other glyphs may be placed, and that doing so
has some relation to the abstract syntax, or the structure of the
language. You may also define some constraints in terms of layout in the
language definition.

You can see some similar work has been done here:
http://msdl.cs.mcgill.ca/people/hv/teaching/MSBDesign/notes.ClassificationFramew\
orkVisualLanguages.pdf

The author discusses classes of visual language, including
"geometry-based languages", in which the meaning of the relationships
between elements is primarily expressed in terms of their geometric
properties (e.g. position relative to one another in the coordinate
system, but I suppose this could be generalized). This includes a formal
notion of "insideness" (see page 10, definition of ULinclude).

Once you have formally defined the notion of "insideness" for your
language, and have defined the special "inside" region for each element
of your language (each glyph), and the special relationships between
each element in the language, then it may be possible to begin applying
existing layout algorithms, again perhaps from the domain of visual
modelling languages. I'm thinking Harel's paper "An algorithm for blob
hierarchy layout", while not completely relevant, might be an
interesting place to start as a model for examining the efficacy of a
particular layout for a particular graphical language:
http://portal.acm.org/citation.cfm?id=345240

There would be many ways of analyzing such algorithms, including
usability/readability, and space-efficiency.

Jake


[Non-text portions of this message have been removed]

#64194 From: "Dailey, David P." <david.dailey@...>
Date: Mon Nov 8, 2010 4:24 pm
Subject: RE: canonical expressions -- part 2: A challenge: accessbility and symbols of the public domain (wikipedia)
david.dailey@...
Send Email Send Email
 
Oops, the second file I was talking about here was actually
http://granite.sru.edu/~ddailey/svg/pd4.svg
That's the familiar copyright free symbol in use by Wikipedia.

The basic question is "how best to make it semantically correct and visually
consistent with the appearance?"

Cheers
David


From: svg-developers@yahoogroups.com [mailto:svg-developers@yahoogroups.com] On
Behalf Of ddailey
Sent: Sunday, November 07, 2010 11:32 PM
To: svg-developers@yahoogroups.com
Subject: Re: [svg-developers] canonical expressions -- part 2: A challenge:
accessbility and symbols of the public domain (wikipedia)



Challenge: come up with "better" symbols for signifying "public domain" or
"copyright free."

Begin here http://granite.sru.edu/~ddailey/svg/pd3.svg . Look at the source code
and then see what you think. I'll get back to that example toward the end of
this message.

As a bit of searching in Google Images*, Wikipedia and Wikimedia Commons will
reveal, there are several symbols meant to depict the concepts of "copyright
free" or "public domain" or "copyleft." Not only do these concepts have slightly
different nuances of meaning, but the symbols have a many-to-many relationship
with the concepts. And furthermore, the symbols have differential levels of
accessibity, depending on for whom we define "making" "allowing" or "enabling"
to be accessible. And, many of the symbols, while looking alike, have very
different underlying file structure.

Following a recent visit to openclipart.org** I was rather prepared for what
Jeff Schiller calls "cruft" when I saw the earlier image at
http://commons.wikimedia.org/wiki/File:Publicdomain.svg
as described there.I did the following [Hand edited to remove sodipodi and
inkscape references, remove unused gradients, remove unused styles, replaced
duplicated paths by <use> elements, simplified complex cubic beziers as simple
arc subcommands; used integer arithmetic. Replaced complex arcs by circles. New
file is 18 (<lkb) lines of code -- old file was 144 lines (>5kb). New file
should have better semantics for re-editing basic objects.]

Well 18 lines and 895 bytes defintely seems better than 5 kilobytes of code. But
is the new code more accessible? Well, I think it is, but how can I tell for
sure? How does one come up with the "best" expression for such a simple figure?

Look inside the two figures and you'll see several questions that pose
themselves:
is it better to use <use>?
does striking all the sodipodi stuff erase some of the artist's brushstrokes?***
are two paths with one rotating the other better than one that has twice as
coordinates listed?
doesn't it make more sense to let color be inherited from the group rather than
individually defined for each path?
what about the optical illusion of the letters pd for public domain? Should that
be made semantic in our markup?

I confess it took me a while of fidding to replace all those cubic beziers from
Inkscape by the "canonical" arc-equivalents. But I figure that the seven
coordinates (or so) that I used, instead of sixty or so in the original path
ought to make the content more accessible to future analysists if anyone ever
wants to modify it!

Next question (and maybe more important):

Take a look at http://granite.sru.edu/~ddailey/svg/pd3.svg

The image on the left is one of the current images served by wikimedia as the
symbol for "copyright free".[2] Perhaps it is based on [3] . Perhaps the
metadata associated with the file should show its ancestry?

The file history shows some well-deserved attempt to rid the file of unneeded
complexity and cruft.
The current image (in its eleventh incarnation on wikipedia). It consists of
four circles and three rectangles. One of the rectangles looks like it has been
added merely to carve out a portion of a circle to make it look like a "c." This
doesn't seem very accessible.

So in my quick attempt, I put a "c" in the middle of the circle. I defined the
circle as not two circles but one. I defined the rectangle as not two but one,
and I defined the "C" as not two circles and a rectangle, but as a "c". I also
made a stab at adding <title> and <desc> tags to describe the "why and what" of
the file.

So here is the challenge: can we come up with a better version of the symbol
that what is there right now?

Can we come up with one we will all agree is better?

What I don't like about my attempt is that the "C" is dependent upon system
fonts??? Changing from sans-serif to arial makes a huge difference in some
browsers!

Should the circle be one circle or two?

Should the circle really be carved by a clipPath consisting of two arcs or
should it be a circle with a line (rect) that crosses it? I chose a crossing
line but was not convinced this was right.

I stretched the "C" horizontally to make it appear to conform to the circle
outside. Circles would have conformed better!

What is the canonical <title> and <desc> information to go with the proper file?

What is the proper way to refer to this discussion thread should we ever agree
on my desire to replace the four circles and three rects

cheers
David

*I discovered to my great dismay that Ditto.com, as of about 6 months ago, no
longer exists[1]. Their lawsuit paved the way for Google images which followed
almost to the day the initial ruling in favor of Ditto.com.

**After spending a bit of time reminding myself of why I (wearing various hats
that I do) don't use more images from http://www.openclipart.org/ , I wrote a
bit of script to help me find the relevant <path> objects (amidst gradients and
filters that are never used) that actually draw the interesting shapes
(assigning mouseover event that parse and modify the "style" of the active
object).

*** I remember in the 1980's trying to help students (and a wife) recover their
corrupted word-processed files and realizing that the archival copy actually
contained not only the document but the "edit history" of the document including
backspaces, deletes, copies and pastes!

[1] http://srufaculty.sru.edu/david.dailey/copyright/legalthumb.htm
[2] http://en.wikipedia.org/wiki/File:PD-icon.svg

[3] http://en.wikipedia.org/wiki/File:Red_copyright.svg

[Non-text portions of this message have been removed]



[Non-text portions of this message have been removed]

#64195 From: "Mr Rauf" <cute_rauf_696@...>
Date: Mon Nov 8, 2010 5:51 am
Subject: Re: resize and draggable the group of the SVG element.....
cute_rauf_696
Send Email Send Email
 
--- In svg-developers@yahoogroups.com, "jeff_schiller" <jeff_schiller@...>
wrote:
>
>
> --- In svg-developers@yahoogroups.com, "Mr Rauf" <cute_rauf_696@> wrote:
> >
> > I am working on a SVG and now want to let a user resize an object
> > using draggable corners, very much like in SVG-edit (http://svg-
> > edit.googlecode.com/svn/trunk/editor/svg-editor.html). The
> > functionality should work as follows: The user selects the SVG objects,
> > drags it to the main `canvas' and once on the `canvas', four corners
> > on the outside of the object appear, the user can drag on each of the
> > corner points & drag to enlarge the object. The objects will be
> > rectangular in shape and created using paths, not using the SVG `rect'
> > function. Would anyone have any suggestions as to how this should be
> > implemented?
> > Thanks in Advance..
> >
>
> Here's how SVG-edit did it:
>
> - have listeners for mousedown, mouseup, mousemove
> - if an element is clicked on (in mouseup), then that is your currently
selected element
> - put a 'selector box' element on top of the selected element (that has the
visible handles you can drag)
> - in your mousemove, detect if a handle is being dragged, while it's being
dragged, determine what the element's new size should be and either:  a)
recompute the element's geometry to fit into that box or b) put a transform on
that element
>
> See SVG-edit's code involving Selector, SelectorManager and
recalculateDimensions() and the mouse event handler functions.
>
> Note that these are not trivial pieces of code and they took awhile to get
into a working state.
>
> Best of luck,
> Jeff
>
Tanks Jeff,Narendra Sisodiya
  but i want more help from you.you are the only man guide me on right path.when
you mousedown and selector rectangle is appear,one or more element are selected,
the group elements can drag.but the problem is that how to make the rectangle on
the mousedown and increase size on mousemove..
thaks again,
jeff and Narendra Sisodiya

#64196 From: "jeff_schiller" <jeff_schiller@...>
Date: Mon Nov 8, 2010 7:24 pm
Subject: Re: resize and draggable the group of the SVG element.....
jeff_schiller
Send Email Send Email
 
--- In svg-developers@yahoogroups.com, "Mr Rauf" <cute_rauf_696@...> wrote:
>
>
>
> --- In svg-developers@yahoogroups.com, "jeff_schiller" <jeff_schiller@> wrote:
> >
> >
> > --- In svg-developers@yahoogroups.com, "Mr Rauf" <cute_rauf_696@> wrote:
> Tanks Jeff,Narendra Sisodiya
>  but i want more help from you.you are the only man guide me on right
path.when you mousedown and selector rectangle is appear,one or more element are
selected, the group elements can drag.but the problem is that how to make the
rectangle on the mousedown and increase size on mousemove..
> thaks again,
> jeff and Narendra Sisodiya
>

You do realize that Narendra and I are different people, correct? :)

You can determine as the user moves the mouse, how much they've moved (delta x
and y), then apply those changes to the element selected.

Jeff

Messages 64167 - 64196 of 66117   Oldest  |  < Older  |  Newer >  |  Newest
Add to My Yahoo!      XML What's This?

Copyright © 2010 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines NEW - Help