How difficult would it be to change the background to this app? [Java - I think]

I have never touched programming of any sort at all ever in my life. period.

http://www.codealchemists.com/jdarkroom/

But, I feel like it wouldn't be too difficult to tell this software to display an image for it's background rather than a solid colour - then again...I don't know anything about programming, so maybe it's difficult.
I'm not looking to do anything flashy with it. Just a static image for the background, no effects or anything need to be applied either. I don't even need to have a UI element to direct the file path, if it can be done in the programming language, I'll just tell it to seach for the image and that's good enough. Doesn't need to be fancy.

Is it possible? Is it simple for a pleb like myself?

This is appears to be a closed source application, therefore it isn't a free piece of software that you can modify. So technically you could be breaking some copyright laws by changing the code in the Jar file (which might be compiled already, its been a while since I've programmed in Java). However, the odds of a developer going after one user for simply changing the background is probably low. That said, if you were to maybe ask the dev, they may give you the source code.

A potentially better option is to learn how to code your own application that does something similar to this. I don't think it would be incredibly difficult. The hard part I see is getting the text to appear above the image you want and writing the settings for that. I don't think I would do it in Java though, probably C#, python, or C++.

If you want the no interruptions text editing, maybe try using a terminal app like Vim or even Nano for basic things. Vim for sure is very customizable so you might be able to find what you are looking for. It also has much better support than an old Java app that hasn't been worked on since 2010.

Without access to the source, it would be questionable to edit it. But, real talk here: If we all obeyed that kind of standard Minecraft modding couldn't have happened. Minecraft modding was and is done by decompiling the .jar files that make up the game and by inserting new code alongside the original code. So yes, it's entirely possible. That doesn't stop it from being a complete waste of time, however.

Just use Atom, it has a package for it: http://timnew.me/blog/2014/08/14/atom-editor-background-image/

1 Like

Sorry for the very late reply, you caught me at a bit of a transitory period, so replying I wasn't really able to make a reply.

Anyways, as much as I wouldn't mind learning to code, I remember my days modding Oblivion, and I get that the scripting is very simple and not very similar to most REAL programming, but it was still too difficult for me to wrap my head around. There are of course many changes I would like to make to the software - I would even love to have it have a nice UI selection to direct the background image path and then have the software automatically apply a gaussian mask and tint mask to make text more legible over busy images, but I know that would take a lot more effort, so I figured I can just do that myself in Photoshop and then through decompiling and recompiling the java file I can just direct it in the script what image to use.
Per using terminal apps and @DizzySkin 's recommendation of Atom, I'm not using this software for scripting or programming - obviously, I was just saying I don't understand it and know dick-all about it. What I like about JDarkRoom is that it doesn't have any distracting elements. Looking at Atom and seeing the number lines reminds me of Notepad++ and I am worried there is going to be too many bells and whistles for what I need it for.
I use it for writing. Writing mountains of paragraphs. And I want just me and the words, I don't want anything correcting me, and I don't want anything distracting me. The reason I wanted a photo for the background is to post...hm.....motivational pictures to remind me to work hard and keep going! (as silly as that sounds.....I know....)

I would argue that Atom is suited to that. You can simply disable any features (such as numbered lines) that get in your way. Granted, it has a learning curve, but every good tool does.

As you can see I disabled almost every package I have in Atom (took maybe 90s to figure out which I didn't want since they all have clear explanations) and I got the editor down to basically nothing. I have an extension enabled to hide the tree-view so that I don't have to disable it, which is why there is a couple pixel wide margin on the left. And I've hidden the menu, which I can reveal again by pressing Alt. You could disable the tree view entirely if you wanted.

It's easy to install packages:

And it's easy to manage them / disable the built-in ones:

Well, can't say I didn't try.
I downloaded Atom and gave it a shot, but this is too much fiddliness. Having to scroll through this ugly UI - okay, not ugly, but it seems to favor looks over usefulness - trying to locate all the packages to disable.
Changing colours of the UI is not a simple task, it seems. It seems like I have to download a theme for that, of which I tried several, each of them fucked with formatting settings and just lead me down a rabbit hole of a more and more undesirable software.
Trying to get the background image for Atom thing you linked me didn't work either. I tried first routing the file path to a png and that didn't work, so I changed the png to a jpeg and it didn't work. So I tried not changing anything (other than user name). I even changed the image name to "batou.jpg" as is on the page you linked, and still nothing.

I just wanted to sit down and write tonight and instead I have spent the past hour faffing about in this software. Sorry, but I don't think this is what I am looking for, but thank you for the recommendation.

I wish you luck in finding the right tool, but I'm unaware of any editor with that feature other than Atom. You could try making the window transparent as suggested here: https://forum.sublimetext.com/t/question-can-i-set-editor-background-image/8826/4

Ehhhh....I'm probably just shit out of luck. Maybe on my day off I'll try fiddling around with Atom some more. I like the idea of Atom, but I was already getting concerned about it's design choices when the installed had a flashy animation...kind of seemed like a good summary of what to expect: style over substance. But I believe there is something of use there...

Though, I still have 0 idea why the Styles Sheet text wouldn't change Atom. The link you gave me is just style sheet code right? It doesn't require any package or anything, does it?

Looks to me like the LeSS in that link is outdated, tried it and it did not work as you said. Here is a modified snippet that works with the latest version:

.editor-contents--private {
  background: #0e1112;

  .scroll-view {
    padding-left: 0;
    margin-left: 10px;
    background: url('/Users/{User Name}/.atom/images/{image name}.jpg') no-repeat fixed;
    background-size: cover;
  }

  .lines div {
      background-color: rgba(0,0,0,0) !important;
  }

  .lines {
    background-color: rgba(21, 23, 24, .7) !important;
  }

  .lines .cursor-line, .lines .highlights .selection .region {
    background: rgba(90,90,90,.4) !important;
  }
}
  • Drop your image in your .atom folder in a new folder (just to stay organised) called 'images'.
  • Copy the above code into the file: .atom\style.less
  • Modify the URL to the background image with your username and image name.

Let me know if you have any issues.

It worked! Thank you so much!
Now, can you confirm something for me; I need to know if this is my fuck up or if this is a problem with Atom.

When I opened my text file (standard .txt file, I'm pretty sure is saved with ANSI encoding) it doesn't save any of my formating - mainly the tabbed indents.

Then lastly, I think once that is resolved my last MAJOR complaint with atom are the colours. How do you change the displayed font colour? Once I can solve that, I think it will be usable for my writing.

edit:
sorry, I should be more clear about the font colour since there is UI font and file font.
I'm talking about the file font colour.

Atom defaults to UTF-8, check preferences > core

Edit styles.less (edit > stylesheet) (keep in mind atom does syntax highlighting as well for things that arent just txt files.)

atom-text-editor {
  // color: white;
  // background-color: hsl(180, 24%, 12%);
}

Atom is fully configurable.. is complaint the wrong word?

1 Like

I think you missed the point I was making.
When opening up a .txt file saved from JDarkRoom into Atom, it doesn't save any of the indents made in the file. It's just a big block of text.

Not sure what you've done but saving out of JDR and then opening in Atom worked fine for me. Try opening the file in notepad, JDR may be at fault here. Another option is to turn on 'show Invisibles' in Atom.

  • File > Settings > Editor. Scroll to the bottom and check 'show invisibles'.

If there really are tab characters there and they appear to be zero width, check that you haven't changed the tab length in the editor settings. It's on the same page as 'show invisibles'.

Lastly, if you have to rebuild your indentation then you can select blocks of text at a time and press tab or shift + tab to indent a block at a time.

By the way, I just noticed this package exists: https://atom.io/packages/zen
Seems like something you might want to use. Note that if you do use it you will want to increase the width in the settings for the package. Otherwise, everything will be super thin and unindented. That package, toggling off the menu bar in the view settings, and turning off line numbers, basically makes it atom like JDR. Then just adjust your shortcut keys to be the same as JDR and you're done.

3 Likes

Thanks again for your help! We're getting closer.
So fiddling with the indents, it looks like they ARE still there, however, it seems to indent the whole block of text, rather than just the single line of text. However, if I were to transfer this document to a different editor, like JDR or MS Word, the indents are correct. So it's just a matter of the way Atom is displaying indents...and it's unfortunately a bit annoying. I'm not sure what setting I could have flipped to make this it's behavior. I've been scrolling through packages and settings and can't seem to figure out what I must have done.

edit
it's like the softwrap "hanging indent" needs to be set to a negative value, but it won't let me do that.

After playing around for a while I got this:

Of course, I use Atom for source, not writing, so ignore the fancy text colours for the purpose of a .txt file.

Here's the Less I used for that:

atom-panel-container.left, atom-panel-container.right, atom-pane-container {
    background-color: rgba(8, 9, 10, .85) !important;
}

.editor-contents--private {
    background-color: rgb(21, 23, 24);

    .scroll-view {
    background: url('/image-url') no-repeat fixed;
    background-size: cover;
}

.gutter-container {
    width: 0;
}

.lines div {
    background-color: rgba(0,0,0,0) !important;
}

.lines {
    background-color: rgba(8, 9, 10, .85) !important;
}

.lines .cursor-line, .lines .highlights .selection .region {
    background: rgba(220,255,245,.12) !important;
}
}

Not sure why you would want a negative value on hanging indentation, I set mine to 4 for the screenshot above and it works fine.

1 Like

Well because the indents should be inverted. The first line should have the indent and the wrapped lines should not be indented.
So what I want is standard writing/reading indentation:


But what Atom is currently displaying is a single block of text being entirely indented:

And when I use hanging indent, it affects indents how I want, but to the opposite effect.

If I could use a negative value for hanging indent, then the block of text should be indented properly as shown in the first picture. Or, then again, if there is just an option I need to tick to make the indent work as I want, then that would be fine too.

Edit:
and after a quick google I noticed other people seem to be having the OPPOSITE of my problem, so I decided to wipe clean Atom and uninstall/reinstall it....aaaaaand, it still seems to indent the whole block of text when using soft wrapping rather than just the first line of the block of text.

Right, I see. The reason googling soft wrap hanging indentation would have yielded the opposite is that you are reading older posts from before March of 2015 when the feature was implemented. There is no option currently that supports turning off hanging indent completely, but it probably wouldn't be hard to write a package to do that.

But, in other words, there is no solution available?

Not yet ;)

hmmm....not sure if you are hinting at something...