Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Jordi Pakey-Rodriguez
    @0xdec
    Testing Testing 123
    Ian Douglas
    @iandoug
    Hi. Eventually managed to find my way here. I see you have been rather active. I have also done a few things, but not yet on the branch I created. I still need to figure out 1) how to work in KDevelop, 2) particularly with Git, and 3) how to merge the changes I did elsewhere into that code. Then I need to see how to integrate your cleanups etc. Did you come right with the whole serialization thing? Just wondering if you were working in the right place because I see there .min. versions of everything and we can't work directly in those. So far on my side, I have:
    Ian Douglas
    @iandoug
    Oh geez, DON'T press enter... this thing thinks it's Twitter. Okay. 1) Added code for step size and angle size for moving, sizing and rotating keys or keyblocks. 2) Obtained from around the net a largish collection of samples. Some I had to fix, then I rearranged them into 4 categories (Full, Compact, Ergo, Legacy) and redid the sample/layout directory structure. I see you did something similar so now we have two different solutions to the same problem. This also entailed changes to bootsrap.css, and I fixed a typo there (and some in ijprest's code). So the dropdowns are more compact now. 3) Currently busy with replacing the fonts, getting rid of all the proprietry Microsoft and Apple fonts, both in bootstrap and kb.css. I've picked 'suggested' replacements for them, using Google Fonts and other free ones. Currently a bit stumped with the Engravers Gothic one, since there is NO free replacement for it, and it itself was a compromise for the original Signature Plastics font. So this will probably change again in the future. I've tried things like Copperplate etc, not really the same, and too wide. 4) Integrated the WASD colour swatches from your code, which I assume you borrowed from one of the posts. 5) Integrated a patch from one of the posts to "show currently used colours" in a separate palette. 6) I've been using the other fork which does the SVG images, so that's included too, but won't work on my Firefox. 7) Updated all the included libraries etc (Bootstrap, FontAwesome, AngularJS). Tried the latest JQuery as well but it throws serialization errors so that's still at the original version. Will Git manage to figure out all my directory restructuring, included files etc, and package that all up nicely? I'm going to try to get hold of ijprest again, and if I can't, will also put up a live version. I see you are disabling server saving for now, I agree. In fact I think we need these things saved to a database, along with proper meta data like author, title, version, private/public, etc. That way we can build a nice gallery of 'public' designs for others to use as starting points. I have my own webserver with plenty of space so hosting won't be a major issue. I did /layouts/samples and /layouts/user and put all the samples in samples, and wanted to use /layouts/user for local saves. Let me first do some paying work and get that out the way, they try KDevelop.
    Jordi Pakey-Rodriguez
    @0xdec

    For the serialization thing, take a look at jsonl.grammar.js. It's the file that gets passed to jison (a node package) to create jsonl.js and jsonl.min.js. I've modified it to copy the standard JSON example, but it still doesn't work. I think it would be best to forgo jsonl altogether and just use the standard JSON.parse().

    Also, you can press shift+enter to enter a newline.

    2) what did you do to redo the layouts/samples?
    3) Fonts...ugh. Let me know if you need any help
    4) Yeah it was a pull request from somebody
    5) ooooh that's awesome, me gusta
    6) I'll have to take a look at this too
    7) I'll go ahead and do this too
    git should be able to figure out your new directory structures and everything. And yeah, I think a database is necessary. I don't know anything about angular, but I'm gonna toss my vote in for MongoDB (I'd imagine it's usable with Angular)
    Jordi Pakey-Rodriguez
    @0xdec
    I put the user saves in a /saves/ directory, but that's very temporary. I think a database is the way to go
    with proper JSON...]
    Also, a way to save or load a .json file is a must, so that user's can keep a copy offline
    As for contacting Ian, let me know if you hear anything, because I'm currently counting on him being okay with attribution/credit
    Ian Douglas
    @iandoug
    re (2), many of the samples I found were 'broken' .. so I fixed up the json to make it display properly. Some were more difficult to do than others. But what I was actually referring to was changing the original directory structure. ATM I have
    layouts
    ............ user (== your 'saves')
    .............samples
    .......................... compact
    .......................... ergo
    ...........................full
    ..........................legacy
    During this process I discovered FF was annoyingly caching things even though I was cache-busting (shift-reload), eventually just switched to Konqueror and Chrome to debug. Got tired of clearing FF cache.
    Haven't done any work work ... let me do some of that first then try gitting things...
    Jordi Pakey-Rodriguez
    @0xdec
    Okay sounds good. Currently I have /layouts/ for physical keyboard layouts, /keysets/ for keycap sets (aesthetics only), and /saves/ for user saves (but I'd like to rename this to something else, maybe /user/). The reason I did this is that in the future I would like to have it so that you can create a physical layout separately from the keycaps. For example, you'd load the Ergodox layout and then 'apply' a keyset to it, and it will automatically apply the correct colors/text to the correct keys. And if you have keys in your layout that are not covered by the keyset, it will warn you.
    That obviously requires a lot of work, but I think it would be a great feature
    Ian Douglas
    @iandoug
    Ah, I was wondering what criteria you were using to separate layouts from keysets. One of the compact layouts I have is 'blank'. I guess we are coming from different places ... I was using KLE to design a keyboard from scratch, but I see many (most?) people just use it to design colour schemes etc. So yes I think it would be a good idea to have a set of 'blank' layouts to start with, eg ANSI 104, ISO, ergodox, etc. I'll take a look at what I have and see what I can do.
    Jordi Pakey-Rodriguez
    @0xdec
    Yeah I think separating layout from design is good because it's more representative of real keyboards
    Jordi Pakey-Rodriguez
    @0xdec
    any thoughts on using Polymer?
    Ian Douglas
    @iandoug
    Had a quick look at their site... do you want to basically rebuild everything from scratch? Or some other plan (sorry am rather tired ATM. Should go sleep :-).. need to do something after midnight which is almost here.
    Jordi Pakey-Rodriguez
    @0xdec
    I don't know...I mean, we still don't know if we are allowed to do this. The only license on the KLE repo is a copyright, so...
    And yikes, I forgot for a second how much later it is where you are...7hrs I think
    Ian Douglas
    @iandoug
    I wonder it Polymer will allow one to dynamically add a new font to a page (since it seems able to mess with the DOM). Since there is a need to specify a font for a key (or board), we can't provide every possible font. So perhaps the user could pick one from Google. Then you need a way of
    1) uniquely identifying it for next time
    2) the ability to dynamically add it to the page. Dunno if that's possible since fonts are usually in the HEAD or css .... don't know enough about those sorts of tricks.
    Jordi Pakey-Rodriguez
    @0xdec
    I bet there's a way...if anything can do it, Polymer can. It's pretty powerful
    Also, assuming we can contact Ian, any ideas on license? I'm thinking probably GPL
    Ian Douglas
    @iandoug
    Posted a message on Deskthority, Geekhack does not want to load. No idea about licences, but suppose GPL or similar should be fine. I THINK I have, after much fun and games, managed to upload my stuff to github. Still coming to terms with using KDevelop, git, etc etc .. so a bit messy. https://github.com/iandoug/keyboard-layout-editor If you are able to somehow check it, that would be cool. I should point my local nginx to that directory now to see if it works. Think I must go sleep now :smile:
    Jordi Pakey-Rodriguez
    @0xdec
    Oooooh looks good! I'll take a look and get back to you tomorrow. Also, I think I may have figured out how to save a .json file to the user's computer...yet to test...
    Ian Douglas
    @iandoug
    I was going to create it on the server and generate a link to it. If necessary a cron job could clean up once a day. Else you need to do force-feed downloads or somesuch? My first upload didn't include the fonts and layouts, they're there now.
    Jordi Pakey-Rodriguez
    @0xdec
    I'm using file-saver.js to save a file
    Ian Douglas
    @iandoug
    I broke something or left out a changed file so the whole display is buggered. Attempting to fix.
    Ian Douglas
    @iandoug
    Hope things are fixed. I see you've done a lot of commits, I should take a look and see how to synchronize.
    Bed NOW!!!!!!!!!!!!!!
    Jordi Pakey-Rodriguez
    @0xdec
    hahaha see you tomorrow
    Jordi Pakey-Rodriguez
    @0xdec
    I FIXED JSON
    YES
    And I added a save file button
    Jordi Pakey-Rodriguez
    @0xdec
    When you get the chance, could you add the new fonts by themselves to a PR on my repo? alerque pointed out that attribution is always key. Also, do you want to just make further changes on my repo, since we're working together on some things? I can give you write access.
    Ian Douglas
    @iandoug
    BTW how do I integrate your json fixes without causing world war 3?
    Re attributions and all that: I see from http://fadefade.com/json-comments.html that one is not supposed to add comments to Json, but can't one just add fields that whichever program uses the file, knows what to do with? Eg author, datetime, version, title, etc, and just Does Not Worry if they are missing? Beyond this, if we are going to add further data to each key field, we may need a version number on the json so that we know what fields to expect.
    Ian Douglas
    @iandoug
    Have started watching Calum's video, very educational. I've tested adding other tags to the json and it doesn't break things, as long as I put it at the bottom. eg:
    [{"Author":"Ian Douglas"},{"Title":"Programmer's KeyBoard"},{"Version":"1.85"},{"DateTime":"2015-06-30 14:33:00 GMT"},{"Public":"Yes"},{"KLEVersion":"0.001"},{"KLEKey":"jd3e9jw"}]
    Ian Douglas
    @iandoug
    The thing that so annoys me about Javascript (and made worse by all these new libraries and their own funny syntaxes) is that when, after hours of struggle and going around in circles, you finally get the damn thing to work, it looks so blindingly obvious, that you wonder why the other 500 blindingly obvious things you already tried didn't work ... I feel like Edison and his 1000 lightbulb failures before success.
    Ian Douglas
    @iandoug
    "I FIXED JSON" ... where? Like to see what you're doing and how :)
    Jordi Pakey-Rodriguez
    @0xdec
    The latest code has working, correct JSON
    go to editor.d1sc0te.ch/kb.html to see it
    As for attribution, I just meant for github commits. I’m currently working through alerque’s videos.
    And hahaha yeah, I feel you on the JS thing…it can be so frustrating.
    Ian Douglas
    @iandoug
    What I meant was in which file :-) ..... I'm asking because in my work work I've had to return json to an API from php, and php has this very nice function for doing it... just build an array, call it and you're done. Even nested arrays.
    $reply = array();
    $reply['Result'] = 'OK';
    $reply['CereliaClientTime'] = $now;
    print json_encode($reply);
    I see there is something similar for Javascript: https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify
    your editor. site say: 404 There isn't a GitHub Pages site here.
    Jordi Pakey-Rodriguez
    @0xdec