473,598 Members | 3,266 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

svg: problem of scaling in group of elements

SMRCA
2 New Member
Hello to all,

I am new in svg and don't have any idea of all functions

first let me clear what I want to implement,

I want to make a shape in dia that have one textbox, one rectangle on its right side and 2 images in rightmost side,

the code is like .....

Expand|Select|Wrap|Line Numbers
  1. <?xml version="1.0"?>
  2. <shape xmlns="http://www.daa.com.au/~james/dia-shape-ns" xmlns:svg="http://www.w3.org/2000/svg">
  3.   <name>shape - m2o</name>
  4.   <description>M2O</description>
  5.   <icon>m2o_real.png</icon>
  6.   <aspectratio type="free"/>
  7.   <textbox x1="-60.0" y1="20.0" x2="-60.0" y2="15.0" resize="no" align="right"/> 
  8.   <svg:svg  width="165" height="40">
  9.     <svg:rect x="0" y="5" width="150" height="20" fill="default" stroke="#777777" stroke-width="0.2"/>
  10.     <svg:image x="145" y="-10" width="40" height="40" href="1.png"/>
  11.     <svg:image x="165" y="-10" width="40" height="40" href="2.png" />
  12.   </svg:svg>
  13. </shape>
  14.  

Now i want to scale the rectangle but not the 2 images ,

Can any one tell me what property to set for image ,

I think its preserveAspectR atio but not exactly have any idea,

Please replay me its very urgent,

Thanks,




***Added code tags****
-stang02gt
Nov 14 '08 #1
1 1281
Stang02GT
1,208 Recognized Expert Top Contributor
Please make sure when you post code that you are using code tags.
Nov 14 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

7
3818
by: Karthik | last post by:
Hi, I am just curious if there is any existing API in PHP for rendering SVG (Scalable Vector Graphics). A quick search in Google pointed to me a place in zend.com - http://www.zend.com/zend/trick/tricks12apr.php . where I feel the support for SVG is not very clear to be exact. Just curious if there is a library that comes with PHP that can help us to create PHP without exactly boggling down in the SVG syntax ( XML ) as given in the...
6
2066
by: Sascha Kerschhofer | last post by:
Hi, I wonder if SVG can be scaled, when embedded in a HTML Dokument like an image with its width and height atributes.. Adobe SVG Viewer seems to crop my SVG image when using width and height. Is there any solution? Sascha Kerschhofer
27
3900
by: Mark | last post by:
I'm curious to get feedback regarding the potential SVG has in performing the same functionality as PDF for fixing documents. Thanks. Mark
4
1650
by: alainpoint | last post by:
Hi, I have a simple question. How do you get Opera to work with SVG and Javascript? Can someone point me to a site where the two work together? Many thanks Alain
1
1265
by: RC | last post by:
The Subject says its all. Sorry for waste your time. I couldn't find the SVG (Scalable Vector Graphics) discuss group. Since SVG is XML file, so I posted this message in this XML group. If you know the SVG group(s) and/or
1
10446
by: David DeLella | last post by:
I currently have a SVG object using the adobe svg plugin for Visual C# .NET 2003. The tool is working fine....I can load the svg and use all the feature of svg including zooming, scaling, etc. What i want is a way to control the SVG from a navigational panel outside the SVG component in the C# program. Here is some code of the component so people can know what I am using: private AxSVGACTIVEXLib.AxSVGCtl mySVG; can someone help me as...
9
1461
by: Alan J. Flavell | last post by:
A chance remark on the German-language web authoring group (dciwam) called my attention to http://code.google.com/webstats/index.html An interesting survey of web pages. I haven't really drawn any conclusions yet, but I thought readers here would find it of interest, if they hadn't got there already. (Needs an SVG viewer to see the plots. I took their advice and used FF1.5).
61
4710
by: phil-news-nospam | last post by:
Why does SVG need a different tag than other images? IMHO, SVG should be implemented as an image type just like any other image type, allowing it to work with <img> tags, and ... here is the important part ... also work with backgrounds in other tags. I fail to see any wisdom in making SVG different than say PNG (of course the implementation of the rendering code would obvious be different). --
3
6352
by: SMH | last post by:
Normally an SVG document is loaded/parsed/interpreted inside an HTML document using an 'object' (or 'embed') element, although there are supposedly other ways too. The problem is, the SVG document must be static this way. I want to use the DOM interface to build SVG dynamically inside an HTML document. I am guessing I can build it inside HTML within an 'object' (or maybe 'iframe'?) element. My intentions/goals:
0
7899
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8392
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8264
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
5850
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
3897
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
3939
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2412
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1504
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1250
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.