IRC Logs

Log of #ghostscript at irc.freenode.net.

Search:
 <<<Back 1 day (to 2011/09/29)2011/09/30 
chrisl kens: the problem with Bug 692561 is in pdf_ops.ps in the procedure "setshowstate"08:18.46 
kens Yes, I figured that much08:28.37 
  Your fix might correct my problems with pdfwrite and Tr 3 :-)08:28.55 
chrisl Oh, back again..... :-)08:45.45 
kens For now.....08:45.53 
chrisl So, that tr 3 thing is a funny one - I'm really surprised it hasn't come up before08:46.37 
kens Well, as I said in the thread, I think its rare for a marking operation to rely on the currnepoint being moved by a non-marking (3 Tr) operation08:47.07 
  I think thre's still a different problem with the pdfwrite usage though :-(08:47.40 
  Still, good to get it fixed.08:47.53 
  Did you notice that it affected *all* the text ? It just wasn't obvious unless there were two characters together ;-)08:48.19 
  Hmm, this means I'm goign to end up having to redo all my changes to pdf_ops.ps when I come to commit them, oh well.08:48.56 
chrisl I noticed the problem affected most of the text, I was comparing with mupdf08:49.12 
kens Ah, I was comparing with Acrobat08:49.21 
chrisl Do your changes clash with mine?08:49.38 
kens No, but I am modifying pdf_ops.ps so I'll need a merger08:50.02 
  merge08:50.07 
chrisl Yeh, but if you commit locally, then do a pull/rebase, if there isn't a clash, it should merge automatically08:50.40 
kens Yeah, and I trust that ? ;-)08:50.49 
  I'll do it manually :-)08:50.59 
chrisl git is *much* better at it than svn/perforce - I still check the end result, but it rarely fouls up for me.08:51.46 
kens OK your changes are not affecting my pdfwrite problems, shame :-(08:54.23 
  If its pdfwrite we never enter that piece of code.08:54.42 
  So, back to figuring out what pdfwrite is up to....08:54.53 
chrisl I'd expect it to be doing something not too different - the "show" that I've sorted out the currentpoint after seems rather redundant if not going to a vector device!08:56.07 
kens Its quite different, the current point is nonsense after pdfwrite executes a 3 Tr operation.08:57.08 
  But pdfwrite uses a totally different set of text rendering procs, and I've heavily modified those as well08:57.28 
chrisl Hmm, so I wonder why it does a show there at all......08:58.18 
kens Wel, I think ps2write might quite like it ;-)08:58.40 
  Although I'm not certain about that, it may handle text rendering modes itself as well. I should check08:59.17 
chrisl But ps2write only needs the currentpoint updated for Tr 3, doesn't it?08:59.50 
kens I would think so, yes.09:00.04 
  Can't think of any reason for emitting the actual text09:00.14 
chrisl Unless it spits out some pdfmark magic for hidden text09:00.29 
kens Well it 'might' set Tr 3 and the prolog might handle that, which is waht I meant when I said I'd have to check./09:01.02 
  It might be why I got so many diffs on my last run.09:01.12 
chrisl and txtwrite I would expect to be treated as a vector device as well, so would use the pdfwrite procs09:01.43 
kens It does.09:02.10 
  One of its outptu modes write the text rendering mode as part of the text attributes.09:02.36 
chrisl Well, it does sound the "show" is pointless, but it's easy enough to fix, so I'm going to leave it there.09:03.17 
kens It seems harmless for now, I'd be inclined to pass it to Alex and let him decide.09:03.37 
chrisl At this point, my inclination is to leave it - it is remotely possible that there is code out there in the wild that expects it now.09:16.36 
kens Seems reasonable.09:16.47 
chrisl kens: thanks for cutting the file down, there, it made things much easier!09:37.45 
kens Didn't realise you'd used the reduced file....09:40.56 
chrisl Yeh, I'd just got the first page alone, and decompressed and was about to start hacking when the bugzilla mail came through with your cut down file - great timing09:44.22 
kens :-)09:44.33 
Robin_Watts tor8: Did you see the mail from Company K ?11:06.06 
  It was about text extraction, so I left it to you to answer.11:06.26 
tor8 Robin_Watts: any ideas for how to improve it? the current method uses a distance based on the font size as a trigger, in the absence of a space character. I believe kens used a distance based on the width of another character (was it 'i'?) for the textwrite device11:09.55 
Robin_Watts tor8: Anything you do is going to be a heuristic.11:10.41 
tor8 the only "hard" solution is to get the producer to output space characters11:11.02 
kens tor8 I'm using the average of all the glyphs in the text fragment11:11.18 
Robin_Watts I'd be tempted to take the minimum of whatever value you have now for the estimated space width, and the width of the 'i' character.11:11.27 
tor8 if there is an 'i' character in the subset font :)11:11.59 
  but yeah, we could try that11:12.11 
Robin_Watts I'd personally be tempted to think that a gap counts as a space if it's > 1/2 the average width of a char, and less than 2 average widths of a char.11:13.00 
kens that's what I use ;-)11:13.09 
  But only for joiing text fragments11:13.31 
Robin_Watts But ideally that logic should be kept separable in the code so that other people can alter it to do smarter stuff if they want.11:13.59 
  (I could imagine people using dictionaries for specific languages to decide whether stuff forms into words or not)11:14.47 
kens Arabic and CJKV are easy11:15.19 
  Hmmm I can't use the swapcolors_quick method if the colour I'm swapping to is a pattern colour :-(13:36.36 
Robin_Watts Why not ?13:36.58 
kens It crashes pdfwrite13:37.05 
  Probably because pdfwrite captures patterns as high level spaces.13:37.28 
Robin_Watts swapcolors_quick is intended to be used for you to swap the colors, do something, then swap back.13:37.37 
kens It GPFs13:37.49 
  Or rather, pdfwrite GPFs trying to use the swapped colour13:37.59 
Robin_Watts where "do something" is "do something simple"13:38.07 
kens All I do is emit the colour, the colour emission is what barfs13:38.27 
  pdc->colors.pattern.p_tile is NULL13:39.23 
  pdc is of type gx_drawing_color13:39.39 
Robin_Watts That's probably because the dev_color hasn't been set ?13:39.47 
  (Definitely, if you intend to do any drawing operations, you should use gs_swapcolors)13:40.19 
kens I thought that was the point of gx_remap_color13:40.20 
Robin_Watts Right. So you gs_swapcolors_quick, then call gs_set_dev_color (which calls gx_remap_color) ?13:40.44 
kens Hmm, I was calling gx_remap_color directly.13:41.06 
  You think I should call gs_set_dev_color ?13:41.16 
Robin_Watts I would personally have called gs_set_dev_color, cos it's what all the rest of the code does.13:41.31 
kens Well that seems a reasonable reason13:41.46 
  I can do that easily enough its only 2 changes13:42.06 
Robin_Watts gx_set_dev_color, rather.13:42.11 
  but... I can't see that that will solve your problem.13:42.20 
kens Ah, that explains why I can't find gs_set_dev_color.....13:42.31 
Robin_Watts unless the !color_is_set thing saves you.13:42.53 
kens Might do, I'll try it.13:43.04 
  I don't understand the internal colour stuff at all. The PS end I can handle13:44.03 
  Well, it didn't crash13:44.25 
  And the output looks OK too :-)13:44.48 
Robin_Watts Don't look directly into it's eyes!13:45.17 
  Just back away slowly...13:45.21 
kens No, time for another cluster push.13:45.31 
  Will still (probably) leace 2 files with seg faults and a slew of other problems.13:45.46 
Robin_Watts I'm in clist hell.13:46.00 
kens On the plus side, a test file which never worked is much improved, and teh outptu is much more efficient13:46.03 
Robin_Watts It's adjacent to rop hell. Less goo, but more sharp corners.13:46.16 
kens In some ways its worse, some of it is written in PostScript....13:46.43 
  Bizarrely the Tr 3 problem I was having was completely different from the Tr 3 problem Chris and I looked at this morning, but the effect was similar13:47.09 
  I now have so may windows open I can't find anything... :-(13:47.38 
Robin_Watts kens: What editor do you use?13:47.58 
  kens: You need to buy another monitor.13:48.21 
kens I think you're right about the monitor, or possibly a virtual desktop thing13:49.09 
Robin_Watts I find 2x 1920x1200 works nicely.13:49.29 
kens I sue lots of different editors from Notepad to VS. Depends what I'm doing13:49.29 
  err, use, not sue....13:49.45 
Robin_Watts 1920x1200 is about right for VS. And that leaves another one for chatzilla/console2 etc.13:49.57 
kens Git, Firefox, Acrobat, news reader,.....13:50.37 
Robin_Watts Git runs in Console 2.13:51.04 
  Firefox I pop up when I need it (often on the second monitor, so I can copy/paste into VS etc)13:51.28 
  Acrobat (on whichever monitor doesn't have the ghostscript output I'm comparing to).13:51.59 
kens ponders second monitor13:51.59 
Robin_Watts kens: Does your graphics card have a second output? If so, it's a no brainer.13:52.23 
kens crawls on the floor to find out.13:52.43 
  Looks like it doesn't, the other plug looks like VGA13:53.20 
Robin_Watts Lots have 1 VGA, 1 DVI.13:53.33 
kens Yes, that looks like it13:53.47 
Robin_Watts Both of my monitors are connected via VGA.13:53.55 
  (through DVI -> VGA adapters).13:54.13 
kens I wonder if I could stick a second one on the VGA output, I have an old CRT here somewhere....13:54.22 
Robin_Watts I have a KVM switch on one that works on VGA.13:54.26 
  kens: Almost certainly. Got to be worth a try.13:54.39 
  What graphics card is it?13:54.43 
kens ATI something or other.13:54.54 
Robin_Watts Ah, right. Well the ATIs are very good at handling dual monitors and have been for ages (I've had many ATI cards, and done dual head with all of them)13:55.22 
kens 256 Mb ATI Radeon X1200PRO13:55.23 
  130013:55.33 
  Or possibly its just time to invest in a new PC13:56.19 
Robin_Watts Time for Uncle Miles to buy you an i7?13:57.12 
kens Maybe, but I hate changing computers, and it would come with Windows 7....14:01.21 
Robin_Watts Windows 7 seems like a brilliant update to vista.14:01.36 
  I'm reluctant to move from Windows XP :)14:01.49 
kens I'm unconvinced, it hides even more stuff14:01.50 
  And lies.14:01.56 
Robin_Watts kens: I think a 2nd monitor will 'just work' with what you have.14:03.20 
kens I may well try it. Of course I don't want to use a CRT long term so I'd have to invest in a second monitor. Do you kow if the two can be different resolutions ?14:04.01 
Robin_Watts Yes.14:04.11 
  different resolutions/timings/color depths.14:04.21 
kens OK, then I guess I'd better go lug that old one out.14:04.27 
Robin_Watts http://www.amazon.co.uk/Samsung-2443BW-24-Inch-Monitor/dp/tech-data/B001EX01YM/ref=de_a_smtd14:06.53 
kens Hmm, my screen resolution changed.14:07.26 
Robin_Watts kens: The driver may currently be set to 'clone' the output.14:08.34 
  so it might have resized down to a res that both can cope with.14:08.48 
kens I don't think so it didn't have teh scond monitor then14:09.39 
  But it does now.14:09.44 
  OK now my main is back to 1920x120014:10.26 
  second is at 1280x102414:10.44 
  Not sure what it will support14:10.51 
Robin_Watts and you can drag windows between the two OK? (i.e. it's not cloning)14:11.09 
kens not sure yet14:11.22 
  Yes I can drag across. Second monitoir at 1600x1200 which is tops. Obviously it reconfigured the primary to be the same14:12.00 
Robin_Watts Cool, sounds like you're sorted then.14:12.54 
  I warn you, this will ruin ever working on a laptop for you :)14:13.05 
kens I already feel that way, VS is well-nigh impossible on a laptop display14:13.41 
  I guess I should pick this monotir up off the floor and find some desk space.14:13.56 
  Not looking forward to lifting it up.14:14.09 
Robin_Watts Mind your belt buckle :)14:14.48 
kens I'd forgotten how much these things weigh...14:15.09 
Robin_Watts My big iiyama monitor came with a large sign on the screen warning that people often scratch the screen with the buckle as they lift 'em.14:15.22 
kens Hmm, now I have trouble remembering where I left the mouse ;-)14:22.31 
Robin_Watts kens: Windows has various things for that.14:22.49 
  One will give the mouse pointer a trail to make it easier to spot.14:22.59 
  Another will locate it with rings when you hit a key.14:23.10 
kens yes, I think the first thing is to make the text bigger....14:23.29 
  Ore esolution smaller....14:23.43 
  Its a bit flickery.14:23.49 
Robin_Watts Probably best to lower the res on the CRT then, cos you'll get larger text and faster refresh.14:24.13 
kens Yes, that's what I'm working on14:24.31 
Robin_Watts You'll probably find that it's been set up as 'default monitor'.14:24.31 
  IF you change that to the right monitor definition you'll get better results.14:24.46 
kens Its already correct, auto detected it.14:25.20 
Robin_Watts oh, ok. DCC is working then.14:25.33 
kens OK 85 Hz, now I can look at it14:26.06 
  Without my eyes hurting14:26.30 
  Low resolution though, to think I once used this as my primary display ;-)14:26.48 
  That's better, now the screen is on the left and so is the desktop14:27.24 
Robin_Watts I lugged a large CRT monitor up onto the desk the other day to use with the board from company I, and it failed to cope with 1024x768.14:27.48 
kens !!!14:28.06 
  THis ancient one is running at that14:28.13 
Robin_Watts Time to throw that one away, and reclaim several cubic feet of office space methinks.14:28.20 
kens Well yes, except that it wasn't previously occupying any space in my office, its my emergency backup display14:28.43 
  And was stored away14:28.51 
Robin_Watts I meant my one. I have 2 such backup CRTs, and that's more than I need.14:29.30 
kens Cool, using gx_set_dev_color seems to have got rid of all my seg faults.14:29.43 
Robin_Watts woo hoo.14:30.06 
kens Its a good start.14:30.16 
  Now I have to look at the 298 diffs and then figure out why they have the wrong colours.14:30.48 
  especially ps2write, which I expetced to be unchanged.14:31.18 
Robin_Watts This may be a really dumb question, but....14:45.53 
  when using the clist, should I expect the offsets given by -ZL during the writing phase to match up with those given during the reading phase ?14:46.26 
kens No idea, sorry.14:50.55 
  But it seems likely to me14:51.06 
tkamppeter chrisl, I am seeing your LCMS patch. You are also deactivating the option to use LCMS2 shared. Do you also have very many fixes there?15:06.11 
  chrisl, and is upstream ignoring or refusing them?15:06.27 
Robin_Watts tkamppeter: Our lcms2 is currently 'stock', I believe.15:06.59 
chrisl tkamppeter: We have problems with lcms2 that haven't been addressed at all yet.15:07.04 
Robin_Watts But using lcms2 at all is experimental at this stage.15:07.55 
  For at least one file, it goes wrong.15:08.02 
  For others it will be slower than our lcms1 (significantly so).15:08.21 
  When we get the lcms2 problem fixed, we will port our lcms1 changes to lcms2, and post them upstream.15:08.52 
tkamppeter Robin_Watts, so then I will use shared lcms2 during the development cycle of Ubuntu 12.04 to get a broader testing. If it performs too badly and produces too many reported bugs which do not get fixed in time I will pull back to built in lcms1 shortly before Ubuntu 12.04 release.15:10.16 
Robin_Watts What happens during the development of 12.04 is of less concern to me than what happens during the imminent release (which is 11, right?)15:11.37 
tkamppeter Robin_Watts, the current release is 11.10 to go out on Oct 13.15:15.34 
Robin_Watts Right. And in that, you are shipping gs built against a stock lcms1, right ?15:15.54 
tkamppeter Robin_Watts, I would like to use the embedded lcms1 for that release, but they do not let me.15:16.03 
Robin_Watts As long as they realise that that means any bugs they report will be ignored.15:17.04 
tkamppeter Right, that's it, and they do not let me switch to the embedded one, which I wanted to do to address the Apple-generated figures bug, and which I also want to do now to fix other possible segfaults and color quality shortcomings.15:18.05 
  Robin_Watts, or are the problem only segfaults?15:18.25 
Robin_Watts both segfaults and, I believe, color correctness.15:18.44 
tkamppeter Robin_Watts, are the colors generally off with the stock liblcms1, defeating CM completely or ar these glitches here and there?15:28.02 
Robin_Watts tkamppeter: mvrhel2 is the authority on the color fixes that have been done to lcms, but I *believe* it's more than some files will use profiles in a way that lcms1 doesn't support properly, and radical colour differences will be given for those files.15:29.04 
  The larger problem with lcms1 (in my eyes) is the lack of checking for allocation failures.15:29.30 
  If you run gs in a position where you are running low on free memory, and an lcms allocation fails, it will SEGV.15:30.06 
  (because it will assume the allocation succeeded and then indirect through NULL).15:30.34 
  We've fixed at least some of those problems in our version.15:31.02 
tkamppeter Robin_Watts, trying to convice them to use your fixed lcms1 in GS at least for an update package for 11.10.15:56.21 
Robin_Watts tkamppeter: Cool.15:56.54 
henrys tkamppeter:just curious how this is organized, when you say "convince them" who are you referring to?16:15.43 
tkamppeter henrys, once the technical lead of the Ubuntu Desktop team and also a person of the release team.16:26.24 
henrys kens did NoSu talk to you about pdfmark and modifying the cropbox? he was looking for you.16:44.57 
tkamppeter henrys, the Ubuntu guys left for the weekend now. I will try to move it on next week.16:48.30 
chrisl tkamppeter: is there anything *we* could do to help you make the case?16:50.12 
kens henrys NoSu didn't, but someone else did16:50.40 
  Heading off now, have a good weekend all16:51.36 
henrys take care kens16:51.45 
Robin_Watts you too kens16:51.47 
tkamppeter chrisl, perhaps you could directly e-mail some people. I can give you the mail addresses in a private dialog.16:52.34 
  henrys, ^^16:52.44 
Robin_Watts Would it help for us to produce a definitive statement of what the situation is with lcms etc?16:54.02 
mvrhel2 good morning16:54.34 
Robin_Watts i.e. describe the kind of fixes we've done, why we haven't moved to lcms 2, what we hope to do etc, what the problem with shared libs in this instance is ?16:55.12 
  morning mvrhel2, ray_laptop 16:55.27 
  ray_laptop: I'm stuck in clist hell.16:55.34 
henrys tkamppeter:this does seem rather odd to me. What if we made the ubuntu packages would the same, I think we used to make an rpm package - would you use it as is?16:56.30 
  s/would the same/would we have the same issues/16:56.59 
mvrhel2 maybe I should write my own cmm16:57.00 
chrisl mvrhel2: you must have a couple of hours spare, then..... ;-)16:57.49 
ray_laptop the entire business of preferring (unknown version) shared libraries seems at odds with having a quality supported product16:58.02 
mvrhel2 :)16:58.04 
tkamppeter mvrhel2, if you write your own cmm, it has no upstream outside Ghostscript, then we can package it with Ghostscript without any problems. Then your cmm in GS is the original upstream.16:58.35 
chrisl So we could just rename our lcms, and hope no-one notices......16:59.21 
mvrhel2 hehe16:59.55 
ray_laptop chrisl: GPL allows people to fork software -- we can change the name of our version16:59.56 
  gscms17:00.14 
tkamppeter henrys, Ubuntu would not accept third-party-made packages as core part of the distro.17:00.35 
ray_laptop and we can strip out all of the stuff we don't need17:00.40 
mvrhel2 yes17:00.44 
tkamppeter chrisl, you have my message?17:00.47 
henrys lcms is not GPL but yes17:00.48 
chrisl tkamppeter: yes, not typing fast enough to reply.....17:01.07 
Robin_Watts I suspect the issue for the Ubuntu guys is that if updates appear (security fixes etc) then they want to apply them in one place, and everything gets the benefits.17:01.10 
tkamppeter but lcms is at least free software?17:01.10 
mvrhel2 yes. it has an MIT license which is rather liberal17:01.36 
  if I recall the Mozilla folks used lcms for the basis for their cmm17:01.58 
tkamppeter Robin_Watts, that's it. Security updates are probably still accepted for lcms1 by LCMS upstream.17:02.02 
henrys tkamppeter:we are happy to write a letter than, let chrisl know the recipients.17:02.05 
Robin_Watts But in this case, lcms1 is not being updated any more. Effectively we have our own fork. We are therefore the "upstream" for it. So I don't see the problem with Ubuntu accepting our 'fork' as being ok.17:02.13 
tkamppeter henrys, chrisl got the list and confirmed.17:02.31 
henrys mvrhel2:what is the status of informing marti or our changes, are you keeping up with that?17:02.44 
  maybe by the next release this won't be an issue.17:03.01 
mvrhel2 I need to get the most recent changes to him.17:03.01 
ray_laptop Robin_Watts: that sort of makes sense. Ubuntu would have to accept a shared lib built from our fork as an update in that case17:03.13 
mvrhel2 There is a color conference in November that I am thinking about going to. He may be there17:03.28 
Robin_Watts ray_laptop: I'm not proposing that we become the maintainers of the lcms used in general by Ubuntu.17:03.51 
ray_laptop Robin_Watts: you mean lcms1 or lcms2 as well ?17:04.12 
tkamppeter chrisl, henrys, tell that the built-in lcms1 of GS has once a systematic checking of memory allocation, to eliminate segfaults and second, that the colors of the shared lcms are not correct, defeating our inclusion of color management in Ubuntu.17:04.34 
ray_laptop the upstream for lcms1 bugs wouldn't be too bad17:04.36 
henrys I can understand the distros position - suppose there is an important security fix for lcms and marti fixes it...17:04.42 
Robin_Watts I mean that we should be allowed to have our own internal, non-shared, lcms1 fork as part of our build.17:04.43 
chrisl tkamppeter: Okay, I will try to get a mail out before I finish today.17:05.26 
ray_laptop chrisl: thanks (also to ken) for the fast response on cust 532's Tr bug17:06.41 
chrisl ray_laptop: no problem - and thanks for explaining to Len how broken the file was! Nice one to get fixed for us as well.17:07.23 
ray_laptop that file is sure severely flawed !17:07.29 
chrisl That's an understatement, IMHO!17:07.43 
tkamppeter For the integration in the distro my plan is to not touch the lcms package which is part of the distro. There are too many dependencies on it. What I would do is to switch GS from using the shared LCMS to using the built-in lcms1.17:07.44 
Robin_Watts tkamppeter: That would seem an ideal solution to us.17:08.13 
ray_laptop isn't that what chrisl 's commit did ?17:08.53 
chrisl ray_laptop: yes, but Ubuntu is getting, essentially, 9.04, so still had the option of using the shared lib17:09.32 
henrys tor8:hows the iOS stuff coming? I have miles' ipad now so I can try stuff out if you need.17:19.33 
tor8 henrys: I got the cross compilation working with the makefiles, so I don't have to maintain the stupid Xcode project file for all the libraries at least17:21.31 
henrys sigh the pcl changes to do device gray for text have cascaded into a huge change17:26.00 
  if anybody knows of a good tool to find included but unneeded include files let me know.17:35.49 
chrisl Okay, calling it a day there - enjoy your weekends, everyone!17:41.15 
henrys bye chrisl you too!17:41.31 
tkamppeter chrisl, can you resend the mail17:41.38 
  chrisl, you mis-typed one address.17:41.48 
chrisl tkamppeter: just going to now - sorry about that17:41.50 
tkamppeter chrisl, thanks.17:45.59 
chrisl tkamppeter: done - was weird, I deleted the full stop, and it kept coming back!17:46.10 
Robin_Watts Aargh.17:56.39 
  (c<<3) + 8 != c << 3 + 817:56.52 
sebras Robin_Watts: time to read up on the precedence table? ;)17:57.34 
Robin_Watts sebras: No, annoyingly, I am really well aware of that one.17:58.06 
  I just missed it.17:58.10 
sebras Robin_Watts: I realize, maybe it's more a matter of having your fingers automagically know the table than being aware of it.17:59.48 
Robin_Watts Was buried in a macro, so too many parens already.18:00.09 
 Forward 1 day (to 2011/10/01)>>> 
ghostscript.com
Search: