[–] [S] 2 points 4 days ago* (last edited 4 days ago) (3 children)

thanks for the tip. I did not know LaTeX had a viable competitor. Does it support arbitrarily placing text in an absolute position on the page independant of other content? I probably wouldn’t be enthusiastic about taking on a new learning curve, but nonetheless it would be interesting to know situations where it’s more powerful than LaTeX.

  • source
  • parent
  • context
  •  

    cross-posted from: https://lemmy.sdf.org/post/61503899

    I needed to forcibly place some origami fold marks in absolute locations on the page. This seemed like a useful pkg for at least some of the objects:

    \usepackage[absolute]{textpos}
    

    The problem is that it clobbers/ignores the ocg environment. E.g.

    \textblockorigin{-18pt}{0mm}
    \setlength{\TPHorizModule}{1mm}\setlength{\TPVertModule}{1mm}
    \begin{ocg}{region boundaries}{rb}{on}
    \begin{textblock*}{0pt}(0mm,0.5\paperheight) {\color{green}\rule[0.5ex]{\hmgn}{1pt}} \end{textblock*}
    \begin{textblock*}{0pt}(\paperwidth-\hmgn,0.5\paperheight) {\color{green}\rule[0.5ex]{0.5\paperwidth-0.25\paperheight}{1pt}} \end{textblock*}
    \begin{textblock*}{0pt}(\paperwidth-\hmgn,0.5\paperheight) {\color{green}\rule{1pt}{0.5\paperheight-\hmgn}} \end{textblock*}
    \begin{textblock*}{0pt}(\hmgn,\hmgn) {\color{green}\rule{1pt}{0.5\paperheight-\hmgn}} \end{textblock*}
    \end{ocg}
    

    It would probably work if a \begin{ocg}… were nested inside of every single \begin{textblock*}, but fuck that.

    The textpos docs mention that care is taken to put the objects into the background and that the overlay option can be used to put the stuff on top. I thought that might be a hack to get it to respect the ocg environment, but no. It does not work.

     

    I needed to forcibly place some origami fold marks in absolute locations on the page. This seemed like a useful pkg for at least some of the objects:

    \usepackage[absolute]{textpos}
    

    The problem is that it clobbers/ignores the ocg environment. E.g.

    \textblockorigin{-18pt}{0mm}
    \setlength{\TPHorizModule}{1mm}\setlength{\TPVertModule}{1mm}
    \begin{ocg}{region boundaries}{rb}{on}
    \begin{textblock*}{0pt}(0mm,0.5\paperheight) {\color{green}\rule[0.5ex]{\hmgn}{1pt}} \end{textblock*}
    \begin{textblock*}{0pt}(\paperwidth-\hmgn,0.5\paperheight) {\color{green}\rule[0.5ex]{0.5\paperwidth-0.25\paperheight}{1pt}} \end{textblock*}
    \begin{textblock*}{0pt}(\paperwidth-\hmgn,0.5\paperheight) {\color{green}\rule{1pt}{0.5\paperheight-\hmgn}} \end{textblock*}
    \begin{textblock*}{0pt}(\hmgn,\hmgn) {\color{green}\rule{1pt}{0.5\paperheight-\hmgn}} \end{textblock*}
    \end{ocg}
    

    It would probably work if a \begin{ocg}… were nested inside of every single \begin{textblock*}, but fuck that.

    The textpos docs mention that care is taken to put the objects into the background and that the overlay option can be used to put the stuff on top. I thought that might be a hack to get it to respect the ocg environment, but no. It does not work.

    [–] [S] 1 point 5 days ago* (last edited 5 days ago)

    Indeed I mentioned that. The point is that when FM is cancelled, DAB listeners will still experience analog artifacts while at the same time having the other disadvantages of DAB (e.g. slow decoding when channel surfing, no sound at all on degraded but otherwise acceptable signals).

    Hopefully whoever goes to bat for preserving FM will find this thread when building their case.

    I’m not sure what the bubbling mud is.. I guess I have not experienced that.

  • source
  • parent
  • context
  •  

    I sometimes get:

    Ksh…Ksh…Ksh…Ksh…Ksh…Ksh…

    About ½ second spacing. Would not expect this on DAB radio. Surely it must be some kind of interference in an analog signal before digital encoding. I’ve heard it in the past but quite a lot today. Not sure if it’s different stations or just the one. Guess I’ll have to track that.

    This is another consideration as one EU nation after another decides to cancel FM.. DAB has its own issues and yet still does not relieve us of static.

     

    I naturally upvote myself when I post, because naturally I agree 100% with every single thing I say -- without exception. Lemmy devs know this, so the client is coded to automatically upvote my own posts.

    Now most of my upvotes for myself are gone. Interestingly, they are not 100% gone. A minority of them seem to have persisted, as well as my upvotes for others. I have no idea what extent the voting data was lost, or if my votes on content of other SDF locals was lost.

     

    I wrote this post and linked to this (now non-existent) comment:

    https://lemmy.sdf.org/post/52446618/26894334

    The post that the comment falls under is still there, but the link to the comment is broken.

    Querying the sitewide modlog on myself is not interesting. Just shows some unrelated nutty shit with a slrpnk.net mod. The thread looks like just a conversation with myself, effectively thinking out loud as I dig more. If the comment were by me and deleted by myself, there would be a trace left of it. Or even if it were someone else’s comment, a placeholder would be left.

    My best theory is that SDF had some data loss or disaster, and they rebuilt the DB in a way that caused comments to get a new primary key. But wouldn’t the post have gotten a new number as well?

    I think I linked to the comment that is now:

    https://lemmy.sdf.org/post/52446618/24104545

    but strangely, that id number is smaller than the comment that was written before it.

    [–] [S] 1 point 1 week ago* (last edited 1 week ago) (1 child)

    Thanks! I did not realize there were different compression levels. So I discovered optipng. If I scan to PBM, that can be fed into optipng set for max compression:

    $ convert sample_scan.pbm sample_IM.png; # ImageMagick for comparison
    $ optipng -out sample_optipng_default.png sample_scan.pbm; # run with defaults (moderate effort, -o2)
    $ optipng --strip all -o7 -out sample_optipng_min.png sample_scan.pbm; # max effort (smallest result)
    $ pdfjam --a4paper -o sample_optipng_min.pdf sample_optipng_min.png
    $ cjb2 -lossless sample_scan.pbm sample_lossless.djvu; # DjVu for comparison
    $ du -h …
    24K     sample_lossless.djvu
    68K     sample_optipng_min.png
    68K     sample_optipng_default.png
    72K     sample_optipng_min.pdf
    80K     sample_IM.png
    

    The tightest PNG compression w/metadata stripped (or even just the optipng default) is much smaller than ImageMagick’s output. The PDF produced by pdfjam is bigger than the png it contains (rightfully so). So I’m pleased with this. I’ll replace ImageMagic with optipng. And if a scanned doc is just 1 page, I won’t even bother with pdfjam and just keep the png.

    I thought PNG was inherently lossless but the pngquant tool proves there is a lossy compression algo. Although I suppose anything can be lossy with image processing done independently. I did not fiddle with pngquant because it seems to only be relevant to color reduction, which makes no sense on a bitonal image.

    DjVu is a clear winner. ⅓ the size and still lossless. But there is no LaTeX pkg for DjVu so the smaller size obviously comes with a big trade off. But then we must consider that a DjVu file can be directly converted to PDF (LaTeX importable) using ddjvu. So we have:

    $ ddjvu -format=pdf -quality=150 sample_lossless.djvu sample_ddjvu_lossless.pdf; # 150→highest possible quality
    $ pdfimages -all sample_ddjvu_lossless.pdf innards; # because we want to see what’s inside that thing
    $ du -h …
    24K     sample_lossless.djvu
    44K     sample_ddjvu_lossless.pdf
    44K     innards-000.ccitt
    4.0K    innards-000.params
    
    $ cat innards-000.params; # to get an idea of what the CCITT is (fax or whatever)
    -4 -P -X 2464 -B -M
    

    The PDF size (from DjVu) is still smaller than the smallest PNG. And we can see that ddjvu did not do anything foolish like stuff a jpg in the PDF. It’s not fun to work with CCITT files, but I suppose that would be rare. In the end, DjVu seems like a winner for archiving because ddjvu can always make a PDF that is still smaller than a PNG, and LaTeX can work with that.

  • source
  • parent
  • context
  •  

    I recall there was an IRC channel during the US election in past years where an IRC bot printed results as they came in. And throughout the election night you could query the bot for stats in a given state.

    I tried /msg alis list *election* and got nothing interesting. Is this just done on the 4-year POTUS elections?

     

    I often use a command like this:

    $ pdfjam --a4paper -o "$pdf" "$png"
    

    The input png file is 105kb and the resulting pdf is 97kb. The beauty and strength of pdfjam is that it uses pdfpages to simply insert images as they are without manipulation (whereas most other tools such as ImageMagick insist on transcoding images).

    So what explains the fact that the output is smaller? If some kind of non-lossy compression is used within the PDF container, the PNG should not be that significantly compressable, I would think. Otherwise that would imply a notable inefficiency in the png algorithm.

    [–] [S] 1 point 1 week ago*

    The bugs host and the reportbugs host would have to be considered separately. The bugs host is strictly for viewing text, just like the other onion hosts. The reportbugs host could be abused, but because the Debian project is non-transparent, makes no announcement, we can only guess what’s going on when they silently take a spontaneous action. Only after they express what action they took, and why, can we analyze whether it was sensible and how to move forward. Certainly it would be possible to deploy an onion host that accepts bug reports, and then put the traffic through an appropriate process, such as spamassassin scoring.

  • source
  • parent
  • context
  • [–] [S] 2 points 1 week ago* (last edited 1 week ago)

    Since you didn’t share the username/instance,

    Doesn’t this link work for you?

    https://lemmy.sdf.org/post/39819472/25666072

    AFAIK, SDF is open access. From there, you click … to reach that user’s modlog, which leads you here: https://lemmy.sdf.org/modlog?userId=27699421

    I wouldn’t say it’s a bug

    I’m calling it 5 bugs.

    but it is very easy for an admin to use incorrectly or withoutout care for the ramifications.

    It’s the job of the software to make the user understand what the software does.

  • source
  • parent
  • context
  • [–] [S] 4 points 1 week ago* (last edited 1 week ago)

    Banning an account means his whole content is deleted (that’s how it was done since the 90s)

    Lemmy did not exist in the 90s. When a usenet account or email account ceased to exist for any reason, the content on news servers and mailing lists was separate. Software can be crudely designed (web-based in particular), or it can be well designed.

    Saying “(that’s how it was done since the 90s)” implies a conventional wisdom fallacy. It’s irrelevent how it was done in whatever span of time. Tech was often designed better before the 90s. Advancements are obviously made but I see design approaches worsening.

    Most importantly, the tool /can/ be smarter. A good tool might remove all content as a starting point, then a spamassassin-like process could run that works out likely ham, which could then be either reinstated or flagged for human review, depending on resource constraints (both human and machine). A blunt remove all is important to have but crude and reckless if it’s the only option.

    Spammers do write some random content to pretend they are not bots, again a fact.

    And? Intent doesn’t matter. The end game is still about separating spam from ham. Your claim just supports the view that there is some ham to save.

  • source
  • parent
  • context
  •  

    cross-posted from: https://lemmy.sdf.org/post/61287283

    I posted this thread, without issues. A year later, I finally got a really insightful reply that wholly answered my question well:

    https://lemmy.sdf.org/post/39819472/25666072

    Now it is “Removed by mod”. But I am the mod.. the only mod (wtf?). No, I do not have multiple personality disorder as the modlog shows.

    So somewhere, someone booted that user. That had a ripple effect of destroying all that user’s content. So then I found a “restore content” button, used it, and had to give a reason. I thought I would just be sending myself a useless alert, but it actually restored the content.

    So it’s fixed to some extent. But I would like to understand more about what happened. I cannot tell from that user’s modlog who banned them, or even which instance did the banishment. It may be true that it was an anti-spam control, and perhaps rightful, but it’s a bit fucked up how it killed all that user’s content when obviously some of it was useful.

    I have seen this before in communities I moderate where a comment is gone because a user is banned. I never looked further. But now it’S clear this is not optimum. It was only in the case at hand that a user’s comment was useful enough that I remembered it, and it happened to be recent.

    Clearly this is a bug: I am given the option to “restore comment” but I cannot review the comment before clicking that. So how can I first give a reason for restoring the comment if I am restoring it just to see if it should be restored?

    To be clear, there are many bugs:

    1. Banishment should give the banisher 3 options: ① remove all content ② remove no content ③ remove posts selectively.
    2. The modlog should not hide who did the ban.
    3. Mods should /always/ have a view of deleted content for which they have power to undelete.
    4. Mods should (if they want) receive a notice when a bulk removal affects comments under their purview. There should be a view by which they can easily see on a timeline all bulk removed content that may be worth undeleting.
    5. (edit) The msg “Removed by mod” is false. Since I am the mod where that happened, it could have only been an admin banning a user from the whole system.
     

    I posted this thread, without issues. A year later, I finally got a really insightful reply that wholly answered my question well:

    https://lemmy.sdf.org/post/39819472/25666072

    Now it is “Removed by mod”. But I am the mod.. the only mod (wtf?). No, I do not have multiple personality disorder as the modlog shows.

    So somewhere, someone booted that user. That had a ripple effect of destroying all that user’s content. So then I found a “restore content” button, used it, and had to give a reason. I thought I would just be sending myself a useless alert, but it actually restored the content.

    So it’s fixed to some extent. But I would like to understand more about what happened. I cannot tell from that user’s modlog who banned them, or even which instance did the banishment. It may be true that it was an anti-spam control, and perhaps rightful, but it’s a bit fucked up how it killed all that user’s content when obviously some of it was useful.

    I have seen this before in communities I moderate where a comment is gone because a user is banned. I never looked further. But now it’S clear this is not optimum. It was only in the case at hand that a user’s comment was useful enough that I remembered it, and it happened to be recent.

    Clearly this is a bug: I am given the option to “restore comment” but I cannot review the comment before clicking that. So how can I first give a reason for restoring the comment if I am restoring it just to see if it should be restored?

    [–] [S] 2 points 1 week ago

    Could you please cite your source?

    It’s wholly anecdote from decades of experience. AFAIK, there have been no peer reviewed scientific studies about this. But there should be. It would be interesting to research why it is that testers and bug report contributors are generally widely regarded as needy and demanding of favors. That’s not Debian specific. It’s FOSS wide.

    The public perception is that devs are the sole contributors and testers are perceived as tasking the devs for their own personal gain. It impacts software quality because I often encounter bug reports that are very old when searching for prior reports of bugs I discover.

    A project that effectively promotes good quality makes it very easy to submit bug reports anonymously, without imposing much of an obsticle, so that bug submissions are not disouraged and so everyone has good awareness of the bug history. Debian has been good on this, which is why Debian is a relatively high-quality project. But they are slipping amid the fight against spam and bots.

    Where are they saying this?

    IRC

    Are they actually treating connections from Tor exit nodes or Torbrowser differently?

    Yes. It is no longer possible to submit bugs over Tor, and bugs.debian.org quietly drops packets if the user’s user agent is not what they want.

  • source
  • parent
  • context
  •  

    The page onion.debian.org lists onion services for the Debian project. There are a lot of them, but nothing for:

    • bugs.debian.org
    • reportbug.debian.org

    Part of the problem arises from an unhealthy attitude that bug reporting is a service that benefits the tester. That it is okay to make testers go through cumbersome hoops. Testers are actually contributors. The project should be doing all that it can to make it as easy as possible to submit bug reports because bug reports are inherently labor intensive. Bug reports improve the software for everyone. The tester may or may not even be a stakeholder. They are making a charitable contribution.

    The Debian project is unapologetically telling testers to switch to clearnet and mainstream browsers when the bug services discriminate against users based on the network or browser version they use. Yikes. I hate to see Debian go in this direction.

     

    Snikket servers made a recent change that broke Profanity (the text-based XMPP client). And no one noticed.

    Both Profanity and Snikket have joined Microsoft’s exclusive walled-garden (github) which means a bug will only be reported by someone who is in the intersection of profanity users with an account on a snikket server, and who is not in Microsoft’s excluded group.

    Searching the #profanity hashtage yields extremely sparse results. So who is in that tiny segment of an intersection of 3 tiny groups to report the bug?

     

    I am writing a new package that does not use tikz but uses the standard latex2e picture environment. I am pleased that I could get the needed graphics without tikz. This means when the general public uses the package, it will not impose a tikz dependency on them (which is big and can have side-effects).

    The problem is that objects need to be placed in absolute positions independant from other text on the page and without affecting other objects, like fold marks on a letter.

    A similar question was answered:

    https://overflow.ocus.top/exchange/tex/questions/386324/place-image-in-absolute-position-independently-from-text

    It’s not a great answer because it relies on importing an external package (tikzpagenodes). We should not have to pull in the whole tikz infrastructure just to (for example) place a fold mark on a page. This is my starting attempt:

      \setlength{\unitlength}{1mm}
      \begin{ocg}{foldmarks}{fm}{on}\color{red}
        \noindent\hspace{\dimexpr(-\oddsidemargin-1in)}\begin{picture}(0,0)
          \put(0,0){hello, this is the origin!}
        \end{picture}
      \end{ocg}
    

    The “h” in “hello” is rightfully against the far left edge of the paper. It’s ugly that I had to subtract off a left margin and an arbitrary 1 inch (which is hard-coded into the page layout), but it works for the horizontal. Doing the same with a negative \vspace{} (e.g. \vspace{\dimexpr(-\footskip-1in)}) has no effect, so a bottom margin or footer is forced.

    How can this be overcome without using tikz?

    view more: next ›