There is a beautiful script producing a rectangle with rounded corners here:
http://gnuplot-surprising.blogspot.de/2011/10/round-corner-rectangle-in-gnuplot.html
It works so far and I'm able to adapt this example to my needs.
The problem is that it does not work properly in case of pdf output and I have no idea why .. there seems to be a problem with pdf and filledcurve in a way, that the area is not properly filled. Viewing the pdf you can clearly see that the filling consists of stripes and in between them are white lines separating them. It looks really bad on screen and on paper.
Again: the problem only occurs if the script is adapted to pdf output!
I've been working on this all day and still no clue how to fix this.
Does anyone see a way out? Or is it an inherent problem of the way curves are filled?
Related
I am getting really frustrated. I have code that works, as in it literally does what it says it will do, however, it doesn't always correctly read my images on the slides as images. I even went so far as naming them all "Picture" and using it as a variable. It actually worked for a second but then 5 pictures in it stopped working again.
This is the code and it DOES work:
With shp.Fill.PictureEffects
Dim eff As PictureEffect
Set eff = .Insert(msoEffectSharpenSoften)
eff.EffectParameters(1).Value = 1
End With
Why will this block of code not work on all of my images? Even when it throws the error it WILL sharpen the image as intended, but then stop??? I do not understand the problem or what a possible fix might be. This is literally the last bit of my work process that I need to solve...
For the record, I have code that will adjust the Height, Width, and center the image perfectly on the slide with no issues whatsoever, code that will put images in a placeholder and then format text... but for some reason THIS block of code won't work...
I have also tried deleting the image, manually reuploading it using the Insert Picture function in the program and it still doesn't work??? Is it possible this has something to do with the fact I am using PowerPoint 2013?
I tested it a different way by changing the picture format, it seemed like it was working but it didn't. Whether I automate it, whether I insert picture, no matter what I do, whether it's in a pre positioned container or not, this line of code refuses to work. Why are my images, in both PNG and JPEG format not being accepted by PowerPoint VBA?
I've seen a number of issues dealing with saving inkscape drawings as anything other than a svg but haven't seen a discussion specifically about transparent objects in PDFs. What's happening is that when I export a png any transparent object looks fine but if I save it as a PDF or eps the transparency is lost.
I've created an example which you can see at this link ( http://imgur.com/a/ieVuu )
I've looked at a lot of other posts and feel like the explanation to this is layered within the responses but I'm a beginner and can't read between the lines to understand it. I wanted to just ask why this is happening and what can be done about it directly?
Use Alpha Channel to set the transparency instead of Opacity option.
Typically this is an issue with the pdf printing program that you are using. Perhaps it's a configuration issue, perhaps it's just not advanced enough to handle it.
Try out several other programs that can print to pdf and see if you can find one that works for your use case.
What I am ultimately trying to do is to create a grid of images for print that are minor variations of the same thing (different text is all). Looking through online resources I was able to create a script that changes the text and exports all of the images necessary (several hundred). What I am trying to do now is to import all of these images into a new photoshop document and lay them all out in a grid and I can't seem to find any examples of this.
Can anyone point me in the right direction to place a file at a specific coordinate (I'm using CS5 and have the design suite so if there is a way in illustrator to do this quickly...)?
Also, I'm open to other ideas on how to do this (even other programs) easily. It's for labels so the positioning on the sheet has to be pretty precise...
The art layer object has a translate() method that takes delta x and y params. You'll need to open each image, copy it to the target document, get its current location (using artLayer.bounds) and do the math to find the deltas to position it where you want it. Your deltas can be in pixels so you'll get plenty of precision.
Check out your 'JavaScript Scripting Reference' pdf in your Adobe install directory for more details.
Ok I'm marking Anna's response as the answer because though I didn't fully test it, it seems like it should work and answers the original question with jsx. However I'm also leaving my final solution in case anyone else runs across this with the same issue and may prefer this method as well.
What I ended up doing instead is using InDesign. I figured out that it has a grid option that lets you import a number of files and place them all in an equal grid in a single command. This is almost exactly what I was looking for, except that it leaves a small border/margin in between the columns and grids and mine were designed to meet exactly.
I couldn't figure out how to make it not have the border (I have very little experience with InDesign, it may be possible). However I was able to select all my images and scale them uniformly to be the correct size, then I just selected each column and dragged it over to snap to the adjacent column and the same with rows...
I'm trying to use pdf content (mathematics) in my webpage. I basically want to convert the pdf to some vector image. Converting the pdf to swf does the job very well, but as flash isn't supported on every platform, I'm trying to find another solution.
I read about svg, but as those pdf's contain a lot of mathematics, the result of the converters I found is really ugly and incorrect.
I've also thought about retyping the latex, and displaying it using mathjax, in some way this is the best solution, but also very time consuming.
The only thing I want is to convert it to a nice vector image, I don't want to change the content, or anything else. Besides converting to swf or retyping it, is there any other solution ?
Edit:
this is svg output
and here original pdf
The only solution I could find is illustrator.
Just open the pdf, save as svg, and choose to embed all used glyphs.
Result is perfect:
https://dl.dropboxusercontent.com/u/58922976/Sol-10.1.svg
what about using flash + raster image in case of platform without flash, if flash mostly works for you?
Your PDF is a little difficult for reasons that are probably not apparent to you.
The core problem with it is that some of the graphics in the document are actually drawn using custom glyphs. You can see this if you copy and paste the text out of Acrobat. There are a variety of unusual characters in there that don't seem to serve any useful purpose. That's those squares at the bottom of your SVG with EEs and FFs in them.
However these characters are actually custom glyphs for things like the braces around the matrices at the bottom of the page. So they are both fairly important and also very specific to this document.
I tried ABCpdf .NET to convert your PDF to SVG. It worked fine apart from these custom glyphs at the bottom. The output was about 90KB. It looked very similar to your inkscape SVG output but just a bit smaller (the inkscape one is 160KB).
The only way to get rid of these non-Unicode glyphs is to vectorize the text. I did this using ABCpdf and the output looked fine in SVG. But... vectorized text is big and SVG isn't a particularly efficient medium. The output was about 1MB! Zipped it goes down to half that but it's still no-where near as efficient as the original PDF.
The problems I am seeing here are going to be universal whatever format you use. These custom characters are always going to be problematic whether you output to SVG, SWF, HTML canvas, VML or indeed any vector format.
So what would I suggest? Well the obvious vector format that is widely used on the web is... PDF!
I know it's not quite what you're looking for but I think this is the realistic solution given the constraints above. :-)
I'm creating a program to generate PDF files in VB.Net.
Everything is working fine except that the image is being displayed with a blue background while the image provided doesn't have any.
Following are the lines of code being used:
sColor = IIf(mvarEncodeASCII85, ToASCII85(ImgColor),
(System.Text.Encoding.GetEncoding(1252).GetString(ImgColor)))
What am I doing wrong?
There is not alot of details, but my first thougt is that it is .png-files or .gif-files.
Am I correct? In that case it may be an issue with adobe acrobat handling the transparent backgrounds.
As I said it's hard to say exactly without any further details.