تخطَّ إلى المحتوى

SVG إلى PDF

حوّل الرسوم المتجهية إلى PDF دون تحويلها إلى بكسلات.

تتم المعالجة على جهازك

تعمل هذه الأداة داخل متصفحك بالكامل. لا يُرفع ملفك أبدًا، ويمكنك التحقق من ذلك في تبويب الشبكة بمتصفحك. تحقّق بنفسك: افتح تبويب الشبكة في متصفحك وراقب. سترى طلبًا صغيرًا واحدًا يسأل إن كان لديك مهام متبقية — اسم أداة وبصمة تجزئة، وليس الملف أبدًا.

ماذا تفعل هذه الأداة

This translates the SVG's geometry into PDF drawing operations rather than rasterising it. Paths, rectangles, circles, ellipses, polygons, lines, strokes, fills and text all become PDF vectors, so the result stays sharp at whatever size a printer sets it. The parts of SVG that have no PDF equivalent are named in the result banner rather than drawn flat, so you learn what was left out instead of wondering why the artwork looks thin.

Use it when a printer, a form or a colleague asks for a PDF of something you only have as an SVG: a logo for a sign or a banner, a diagram exported from a drawing tool, an icon sheet, or a chart out of a plotting library that writes SVG and nothing else.

كيف تعمل

  1. Drop your .svg files onto this page. Up to 100 at a time, each up to 25 MB.
  2. Choose the page size. Match makes the page exactly the size of the drawing plus the margin, which is what a print shop usually wants; A4, Letter and A3 centre the artwork on that sheet instead.
  3. Set the margin if you want whitespace around the drawing. It is 0 by default, because artwork sized to its own bounds is easier to place afterwards.
  4. Choose the background. Transparent leaves the page unpainted, which is right for something going on top of another design; white paints a white rectangle, which is right for anything printed on its own.
  5. Press Convert. Each SVG becomes a one-page PDF, and the banner names anything in the file that could not be drawn.

The easy way to build this tool is to rasterise: draw the SVG to a canvas and embed the pixels. It is also the wrong way, because the reason anybody converts SVG to PDF is to keep it sharp at print size, and a 150 dpi picture of a logo defeats the whole exercise. Here the geometry is translated instead, so the drawing scales like the original and a sign printed at two metres is as clean as an icon printed at two centimetres.

What that costs is honesty about the parts of SVG with no PDF counterpart. Filters, masks, clip paths more complicated than a rectangle, gradients, patterns, markers, use references, foreignObject, animation and anything scripted are collected as they are met and reported by name. Naming them is the point: gradient, filter tells you what to change in your drawing program, whereas two unsupported features tells you nothing. Flatten those parts to plain shapes in your editor and convert again.

Text is drawn as real PDF text, so it stays selectable and searchable, but the typeface named in the file is not the one you get. A font-family list is mapped onto the three families available here - anything mentioning mono, courier, consolas or menlo becomes monospace, anything mentioning serif, times, georgia or garamond becomes serif, and everything else becomes sans. Character widths therefore differ from the browser's rendering, so a tightly positioned label can shift. If exact position matters, convert the text to outlines in your drawing program first and it will come across as geometry.

Page size and scale interact in a way worth knowing before you tune either. With Match, the page is the drawing at your chosen scale plus twice the margin, and nothing is resized after that. With a fixed sheet, the drawing is scaled by your percentage and then reduced further if it still does not fit inside the margins - never enlarged past the sheet - and centred on the page. So on A4 a scale above 100 per cent has no effect once the drawing already fills the sheet.

Only images written into the file as data URIs are embedded. A linked image points at a file or a web address, and going out to fetch it would be an outbound request from a tool that promises none, so it is reported as a linked image instead of being retrieved. Each SVG becomes its own single-page PDF; if you want a set of drawings in one document, run Merge PDF on the results.

ما لا تستطيع هذه الأداة فعله

  • Filters, masks, gradients, patterns, markers, use references, foreignObject and animation cannot be drawn. They are named in the result rather than approximated.
  • The typeface named in the file is not embedded. Text is set in one of three families and character widths differ, so tightly positioned labels can shift.
  • Linked images and other external references are not fetched, because that would be an outbound request. Only data URIs are embedded.

أسئلة يطرحها الناس

هل يبقى ملف PDF حادًّا عند طباعته بمقاس كبير؟
نعم. يُترجَم الرسم إلى عمليات متجهية في PDF بدل رسمه بكسلات، فلا توجد في الملف دقة يمكن أن تنفد. وملف PDF نفسه يُطبع نظيفًا شعارًا على بطاقة عمل ولافتةً بطول مترين، وهذا هو السبب الكامل لتحويل SVG بدل تصدير صورة PNG.
تقول النتيجة إن شيئًا تعذّر رسمه. ما معنى ذلك؟
معناه أن الملف يستخدم خاصية في SVG لا مقابل لها في PDF - مرشّحًا، أو قناعًا، أو تدرجًا لونيًا، أو نقشًا، أو مسار قصّ معقدًا، أو علامة، أو مرجع use، أو foreignObject، أو حركة. وبدل رسمها مسطّحة وتركك تتساءل لماذا يبدو العمل خاطئًا، يسمّي المحوّل ما تخطّاه. سطِّح تلك العناصر أو وسّعها في برنامج الرسم لديك ثم حوّل من جديد.
ماذا يحدث للنص في ملف SVG؟
يُرسم نصًا حقيقيًا في PDF، فيبقى قابلًا للتحديد والبحث في الملف النهائي. لكن الخط الموجود في الملف لا يُضمَّن: يُربَط اسم العائلة بخط غير مذيّل أو مذيّل أو ثابت العرض، وتختلف العروض عمّا يرسمه المتصفح. ولعمل فني يجب أن يجلس فيه العنوان حيث وضعته بالضبط، حوّل النص إلى مسارات قبل تحويل الملف.
ما مقاس الصفحة الذي سأحصل عليه؟
مع خيار المطابقة، مقاس الرسم بالضبط زائد ضعف الهامش، مأخوذًا من عرض الملف وارتفاعه أو من viewBox. وملف SVG الذي لا يعلن أيًّا منهما يتراجع إلى 300 × 150 نقطة، وهو الافتراضي في الصيغة نفسها وعلامة عادةً على أن الملف كُتب يدويًا. أما اختيار A4 أو Letter أو A3 فيعطيك تلك الورقة والرسم متوسّط فيها.
هل يُرفع عملي الفني؟
لا. يُحلَّل ملف SVG ويُرسم في ملف PDF داخل متصفحك، ولا يُرسَل شيء عن الملف - وهذا يعني أيضًا أنه لا يمكن جلب صورة مرتبطة، لأن ذلك هو الطلب الذي ترفض هذه الأداة إرساله. والأصل الوحيد الذي تحمّله هذه الصفحة هو خط Noto، من مصدر هذا الموقع نفسه، وذلك فقط حين يحتوي الرسم على نص.

أدوات ذات صلة