Coding My Own Text Editor Again (Ded S02E01)

แชร์
ฝัง
  • เผยแพร่เมื่อ 19 ก.ย. 2024

ความคิดเห็น • 132

  • @alexs6986
    @alexs6986 ปีที่แล้ว +295

    I think it would be really cool if you did Advent of Code using only tools that you built: text editor (ded), programming language (porth), ...

  • @gustavoh5143
    @gustavoh5143 ปีที่แล้ว +169

    the most impressive skill this man has in my opinion is to be able to code without having a colorful code

    • @kiryls1207
      @kiryls1207 ปีที่แล้ว +3

      at the beginning of my dev journey i didn't like colors so i programmed without syntax highlighting black text on white background
      also I can't see s#it anymore

    • @nofeah89
      @nofeah89 ปีที่แล้ว +3

      isnt he using syntax highlighting?

    • @0ia
      @0ia 11 หลายเดือนก่อน

      Took me a month to get used to no syntax highlighting. Improved my ability to reason about code.

    • @SoftBreadSoft
      @SoftBreadSoft 9 หลายเดือนก่อน +2

      @@nofeah89 a minimal syntax highlighting yea, keywords, variable names, comments.

  • @mitya
    @mitya ปีที่แล้ว +42

    It's nice to see the way of thinking and the insights of a fellow developer :)
    One small note: your way of handling line ends assumes that EOL is always one character. You may want to reconsider that, in order to be able to handle files with '
    '

    • @jan_harald
      @jan_harald ปีที่แล้ว +3

      just store the line ending char, replace it with one character (like
      ) and then replace back ;P
      basically dos2unix file.c;$EDITOR file.c;unix2dox file.c

    • @ocaly
      @ocaly ปีที่แล้ว +7

      I was about to comment this. Microsoft Windows problems :D

    • @mitya
      @mitya ปีที่แล้ว

      @@jan_harald well, hey, good luck with that and to whoever hires you to do a software engineer job :)

    • @mitya
      @mitya ปีที่แล้ว +3

      @@ocaly No, it is not. We don't always choose the source of the files we need to work with. It a complex world, with multiple OSes and their quirks. Basic compatibility is important.
      Otherwise you're just going the way of Microsoft, Apple and others whose motto is: "It's our way or the highway".
      Linux is about freedom of choice as well.

    • @jan_harald
      @jan_harald ปีที่แล้ว +1

      @@mitya you basically never want mixed line endings anyway, and use tr, unix2dos, sed, python, or whatever, with text files it's easy and common to convert them like that, heck, git loves to auto-convert the files FOR you, so go ahead and fire git's developers while at it ;P
      obviously nothing applies 100% of the time, but I doubt that you'll be working with text files which must contain mixed line endings, or which cannot be converted like that, nobody sane writes literal newlines into strings and stuff, if they care about what bytes come out the other side

  • @Zwiebelgian
    @Zwiebelgian ปีที่แล้ว +52

    1:57 „… like all other text editors…“
    Vim:

    • @TsodingDaily
      @TsodingDaily  ปีที่แล้ว +25

      Interesting! I never noticed that! Even though I've been using vim for quite some time already...

    • @root317
      @root317 ปีที่แล้ว +3

      exactly my thought lol

    • @batatavoadora1136
      @batatavoadora1136 ปีที่แล้ว +9

      @@TsodingDaily I'm pretty sure you can enable the cursor wrap, but the default is off

    • @mndtr0
      @mndtr0 ปีที่แล้ว +3

      @@batatavoadora1136 set whichwrap+=,h,l,[,] I'm find that

  • @biggestthreattoyourexistence
    @biggestthreattoyourexistence ปีที่แล้ว +40

    You know you're nuts when you code your own text editor.

  • @lucaslindgren3237
    @lucaslindgren3237 ปีที่แล้ว +10

    You're really good at coding bro

  • @amosnimos
    @amosnimos ปีที่แล้ว +2

    The text editor I coded added nothing original, but yours actually inovated the ehole concept by using a dynamic camera system. It may not be the most practical thing but it's very cool and unique, I don't like the rainbow color and would like a green crt glow instead but that's a good start. By taking some inspiration from the cool retro terminal this project could really shine.

    • @Jack-sy6di
      @Jack-sy6di ปีที่แล้ว +1

      a realistic green phosphor look, so when it's very zoomed in you can actually see scanlines and bloom, would be cool

  • @ecosta
    @ecosta ปีที่แล้ว +6

    About the limits of C around 46:00. I never thought about it, but I would love to see what Tsoding thinks about using a subset of C++ just to overcome C limitations, since C++ is meant to be compatible with C.

    • @Bobbias
      @Bobbias ปีที่แล้ว +2

      I can't speak for him, but I get the feeling that if he viewed that approach favorably he'd be writing code that way in his videos. It's not difficult to write C with a few C++ features sprinkled in if you want to (though I believe there would need to be some changes to accommodate the switch).
      If I had to guess, I suspect the downsides of C++ would outweigh the benefits, even given that you can still write C++ in a very C-like manner.

  • @kurciqs8355
    @kurciqs8355 ปีที่แล้ว +8

    finally saw the keyboard

  • @Tiger_CZ
    @Tiger_CZ ปีที่แล้ว +4

    Hello, great video. I just want to point out (idk how to say it politely, but I dont want to offend you) you have or youtube has a mistake in references. The link to rope data structure is missing ")", but it is actually written after the link.

  • @j-wenning
    @j-wenning ปีที่แล้ว +11

    I was kinda hoping this would involve some sort of interacting with a piece table. I guess the point of this isn't necessarily to make an absurdly efficient editor though.

  • @CarterColeisInfamous
    @CarterColeisInfamous ปีที่แล้ว +1

    YATTSE - Yet Another Text TSoding Editor

  • @peduran1987
    @peduran1987 ปีที่แล้ว +2

    Awesome stream, thank you thank you thank you!

  • @CaterpillarOGM
    @CaterpillarOGM ปีที่แล้ว +9

    porn folder 8.1 Gb?

  • @NateROCKS112
    @NateROCKS112 ปีที่แล้ว +2

    7:02 I haven't finished yet, but couldn't you just store the indices to the beginning of each line? The next newline is just at the next `lines` index minus one.

  • @MrRegdis
    @MrRegdis ปีที่แล้ว +24

    have you ever considered setting another camera just for your hands/keyboard?

    • @pedropesserl
      @pedropesserl ปีที่แล้ว +7

      actually GREAT idea. I would be very entertained by that

  • @luizfelipeg.5364
    @luizfelipeg.5364 ปีที่แล้ว

    Okay, in my mind noed, cannonically stands for 'no one escapes ded'

  • @IveGotBeef
    @IveGotBeef ปีที่แล้ว

    41:06
    i did not expect that reference

  • @mndtr0
    @mndtr0 ปีที่แล้ว +4

    Is you usually use Emacs?

  • @izergaer
    @izergaer ปีที่แล้ว +6

    ne again, a snova

  • @D-V-O-R-A-K
    @D-V-O-R-A-K ปีที่แล้ว

    7:30 Why store the location of
    , when
    always == (the next line's start position - 1)?

  • @TheApgreyd
    @TheApgreyd ปีที่แล้ว +1

    Рад, что наткнулся на канал

  • @berndeckenfels
    @berndeckenfels 4 หลายเดือนก่อน

    48:50 when doubling clamp it to a max increment (2gb) and also to maxinteger

  • @gsilva877
    @gsilva877 ปีที่แล้ว +2

    My text editor
    🤣🤣🤣🤣🤣🤣

  • @ValuedValue
    @ValuedValue ปีที่แล้ว +3

    ? Bro what's written in the bottom?
    Corn folder : 8.1gb

    • @Solomonwo
      @Solomonwo ปีที่แล้ว +1

      Lmaooo

    • @twentyeightO1
      @twentyeightO1 ปีที่แล้ว

      He probably made his own porn in C, you know using his own graphics library.

  • @ltvnf
    @ltvnf ปีที่แล้ว +1

    seems like Apple epic keynote shit. :o
    "One more thing to C"

  • @abrarmasumabir3809
    @abrarmasumabir3809 11 หลายเดือนก่อน

    He is using hhkb that's a great keyboard!

  • @titanovsky
    @titanovsky ปีที่แล้ว

    с новым годом!

  • @Ryan-xq3kl
    @Ryan-xq3kl ปีที่แล้ว

    holy fuck amazing work dude

  • @Omena0
    @Omena0 3 หลายเดือนก่อน

    Bussin GriddyCode????

  • @energyman100
    @energyman100 ปีที่แล้ว

    What did you use to do that zoom in and highlight with your mouse at 0:20 ?

  • @nvpyt2235
    @nvpyt2235 ปีที่แล้ว

    Hey man, I was looking for a great place to start learning python (or how and where to learn it) and I was wondering if you have any good places that you know of that I can learn? Nice video BTW

  • @alexvitkov
    @alexvitkov ปีที่แล้ว +1

    the 2nd link in description is missing the closing bracket

  • @KoshakMine
    @KoshakMine ปีที่แล้ว

    Чел харош, редактор "Дед"

  • @robimuhammad95
    @robimuhammad95 ปีที่แล้ว

    This is lit 🔥🔥
    This will be great if we use it on VR virtual monitor 🔥
    Is this the future of text editor? 🔥

  • @rakanottrubick1857
    @rakanottrubick1857 ปีที่แล้ว +1

    dude im quite new to programming and tell me how it is even possible to make text float like that, changing color mid-character? That seems literally impossible

    • @TsodingDaily
      @TsodingDaily  ปีที่แล้ว +26

      But if a video game was doing something like that you would not be surprised?

  • @BryanChance
    @BryanChance ปีที่แล้ว

    Briliant!

  • @xnhp3
    @xnhp3 6 หลายเดือนก่อน

    1:07:26 still see some tea left.

  • @wubsyman5796
    @wubsyman5796 ปีที่แล้ว

    Hahah took me way too long to realise the text at the bottom is a joke lmao

  • @noeldc
    @noeldc ปีที่แล้ว +2

    What's with the stats at the bottom of the screen? :)

  • @abdullahkhaled6162
    @abdullahkhaled6162 ปีที่แล้ว +1

    0:20 how do you do this in x11?

    • @flleaf
      @flleaf ปีที่แล้ว

      his application called "boomer" on github. can't post links on youtube because youtube

  • @LongestYardstick
    @LongestYardstick ปีที่แล้ว

    where did you go? I miss your videos :( we will support you with patreon if you want money

  • @chriskerwell-gresla4403
    @chriskerwell-gresla4403 ปีที่แล้ว

    Hhkb - tasteful

  • @antropod
    @antropod หลายเดือนก่อน

    People don't buy RAM these days, they download it from internet

  • @bibliusz777
    @bibliusz777 ปีที่แล้ว

    could you do a video on using GPU framework independent?

  • @kawaikaede2269
    @kawaikaede2269 ปีที่แล้ว

    yay

  • @OSeuGall
    @OSeuGall ปีที่แล้ว

    sorry, maybe this is not, but i read: "Porn-folder" in the code editors footer. just commenting

  • @zyxyuv1650
    @zyxyuv1650 ปีที่แล้ว

    My comment got censored check your quarantine.

  • @lucifer-5ybtn
    @lucifer-5ybtn ปีที่แล้ว

    1:25 what is the name (model) of the keyboard that you’re using? It sounds really nice

    • @rubenarce5514
      @rubenarce5514 ปีที่แล้ว

      It seems like HappyHacking keyboard

    • @c4llv07e
      @c4llv07e ปีที่แล้ว +7

      It is qwerty keyboard.

    • @SimGunther
      @SimGunther ปีที่แล้ว

      HHKB2

    • @hanqnero
      @hanqnero ปีที่แล้ว

      @@SimGunther Hell that costs a lot

    • @ValuedValue
      @ValuedValue ปีที่แล้ว

      @@c4llv07e 😑

  • @RuslanKovtun
    @RuslanKovtun ปีที่แล้ว

    You are moving 4M of data on each insert/remove operation and caring about view/representation of the cursor..

  • @nneural
    @nneural ปีที่แล้ว

    bro i would give away all my money for that.

  • @______9364
    @______9364 ปีที่แล้ว +2

    41:05 :)

  • @sangramsingha11
    @sangramsingha11 ปีที่แล้ว

    Here me configuring neovim.. 😀

  • @FelixNielsen
    @FelixNielsen ปีที่แล้ว +8

    C is a good language.
    C is a proper language.
    C is great!
    Seriously, it hurts me to my soul, to hear you say such things about C, not because I feel any need to defend C, it is hardly necessary, but because it rather affects my (for lag of a better term) respect for you. I thought you where one of the few who actually understood C, end perhaps even understood the value of not abstracting away, everything that is fun and interesting, and how counterproductive it really is to do so.
    This is not to say that C is perfect, not even close, and it never will be, until such time as we can all agree on what makes the perfect language, and I think we can at least agree, that this is never going to happen, so we have to make due with the resemblance of perfection, that is C, for the foreseeable future at least, as I very much fear that C is, slowly but surely, going the way of C++, looking at the C23 specs. I sure hope that I am wrong.
    There was a time when C++ too was great, when even I, used and appreciated it, but now there's basically nothing left, of the C++ I knew, so I do C instead, and quite frankly, I'm happy to do so. I'm glad to be forced into comprehension, in order for things to actually work, and I do not believe for a second, that any other language is really more efficient or enables higher productivity, as so many would claim. In short, it simple creates harder problems/bugs, which can then be solved after release, maybe, when the paying user has had plenty of time to appreciere the flaws, which will then, in turn, create other problems, and so on and so forth, for no other reason, than not enforcing the comprehension that enables developers to do their work properly, because of the illusion of increased productivity.
    Well, enough ranting, and I may well be an utter moron, but I firmly believe these things, and I have a very hard time respecting anyone, who actually labels C, a bad language. Seriously, I cannot believe you're actually serious. Must be a language barrier, or something.

    • @Ryan-xq3kl
      @Ryan-xq3kl ปีที่แล้ว

      Modern C++ is quite nice too, it is just not fun for messing around with or writing small scripts. Whenever I write C++ with a focused goal and design for my program I get clean fast small highly abstractable code. Smart pointers for example are a blessing and clean up much of the issue with raw pointers and garbage collection in one swing.

    • @FelixNielsen
      @FelixNielsen ปีที่แล้ว +1

      @@Ryan-xq3kl I must admit that I have been out of the loop, when it comes to C++, for rather a long time, since I gave up, keeping up, but that being said, back they, it was rather my impression that many, if not most, wrote wrote code in C++, including myself, didn't really write C++, but rather C, employing a few nice too haves from the C++ superset, but never really using the language, as indented.
      Perhaps it is indeed the case, that the days of constant and significant changes, and not least additions, to the language, quite often in an entirely wrong direction, seemingly without any consideration for the larger picture, are over. Perhaps I should investigate further, though it won't really change all that much, as I will never become a fan of OOP and excessive, and unnecessary, abstraction.
      In fact, I am rather of the opinion, arrogant though it may sound, that any programmer who honestly prefer that kind of abstraction, that outright discourages fundamental comprehension, is not any more of a programmer, than the average jocker, is an Olympic sprinter.
      Learning a programming language, does not a programmer make, anymore than learning Chinese makes you, well, Chinese. You have to understand their society, history and culture, to even come close, and even then, it may be so foreign to you, that you're really not able to.
      This is exactly what I see as the greatest problem, in the software industry. You take what others have done, and blindly add what is missing, and expect things to just work, because that is how it is supposed to work, lean back, and accept people to just accept the status que, and hand over their money, in return for a defektive product that may, at some point in the future, get fixed to a point, where it is actually useable.
      I really don't know why I cannot sit down, at a keyboard, without ranting for hours on end, about things, that normal people care little about, but there you have it.
      The sad thing is, i actually mis rather significant parts of C++, still, but at least I know what I'm doing, even though I'm getting nowhere fast.

    • @reinhold1616
      @reinhold1616 ปีที่แล้ว +8

      he says he hates all languages equally. plus you put way too many commas.

    • @_inetuser
      @_inetuser ปีที่แล้ว

      @@FelixNielsen but do you think in a complicated world it is feasable to not use others peoples code and still be time effective?

    • @FelixNielsen
      @FelixNielsen ปีที่แล้ว

      ​@@_inetuser Yes and no. It's a balance act. I'm not saying not to stand on the shoulders of others, simply not to do so blindly, and to not have others stand on your shoulders, at the same time, to employ, I think, a reasonably apt analogy.
      As for the time efficiency argument, if you keep your deadline, and thus am time efficient, but release a product that is so flawed, that it doesn't live up to even the most reasonable of expectations, which rather seem to be the norm these days, considering the time you'll spend fixing it, customer support, not to speak of the bad press, administration of refunds and so on, I hardly think you can actually claim to have kept your deadline, but of course, on paper, it very much looks like it, and that is what matters to those in power.

  • @cyanmargh
    @cyanmargh ปีที่แล้ว +7

    ha, дед

  • @crazygames1144
    @crazygames1144 ปีที่แล้ว

    How bout you make a text editor inside your text editor

  • @texoport
    @texoport ปีที่แล้ว

    pog

  • @yashkalyan
    @yashkalyan ปีที่แล้ว

    Code - Gym - Temple - Repeat.
    But you look like just code bro, take your health also in consideration.

  • @SimGunther
    @SimGunther ปีที่แล้ว

    If you take the good parts of C, JAI, Odin, Racket, Rust, Erlang, Prolog, Verse, HolyC, and Smalltalk, I'm sure that'll make for a much better language that most would be willing to work in. The big problem however is that legacy code exists, so we'll just have to empower people to make new legacy code with this "uber-language" that fixes plenty of problems with C but introduces its own problems like you said in the C rant ;)

    • @5omebody
      @5omebody ปีที่แล้ว

      but what are the good parts of each language?!
      it's worth noting that many of the languages have conflicting goals... a lot of things exist as a duality - you can have one at a time, or the other, but not both.
      and often optimizing for one means your language needs to be designed around it, preventing you from optimizing for the other.
      and if you try to do everything... y'know what they say - jack of all trades, master of none. in this case it's forced, by not prioritizing one over the other you _must not_ optimize for one usecase by making another usecase less optimized. and as a result you end up with a language architecture well suited for none of the things, and badly suited for all of them

  • @neilvninja
    @neilvninja 5 หลายเดือนก่อน

    HHKB :D

  • @BrainChili
    @BrainChili ปีที่แล้ว +1

    WHY ARE YOU WEIRD

  • @callisto960
    @callisto960 ปีที่แล้ว

    What keyboard

    • @rubenarce5514
      @rubenarce5514 ปีที่แล้ว

      It seems like HappyHacking keyboard

  • @ItsSchwifty
    @ItsSchwifty ปีที่แล้ว

    ded

  • @starc0w
    @starc0w ปีที่แล้ว

    50:42 Thx for sharing your stuff!
    Isn't it a problem if you lose your old pointer (da)->items when realloc fails?

    • @rndtrash
      @rndtrash ปีที่แล้ว +4

      as you can see in the code, after failed realloc tsoding is gonna ram-shame you :)

    • @starc0w
      @starc0w ปีที่แล้ว

      @@rndtrash Haha, yes, true! :-)
      (Nonsense was written here)

    • @VojtaJavora
      @VojtaJavora ปีที่แล้ว

      @@starc0w you have to define NDEBUG for assert to do nothing. Just don't do that and problem solved.

    • @starc0w
      @starc0w ปีที่แล้ว

      @@VojtaJavora(Nonsense was written here)

    • @VojtaJavora
      @VojtaJavora ปีที่แล้ว

      @@starc0w what release mode?

  • @markcuello5
    @markcuello5 ปีที่แล้ว

    HELP

  • @krillin3613
    @krillin3613 ปีที่แล้ว

    This is so cool i would love to get this working on windows! does anyone have the current version working on windows?

  • @kamal3777
    @kamal3777 ปีที่แล้ว

    The waffle house has found its new host

  • @ruman3726
    @ruman3726 ปีที่แล้ว

    Че по английски шпрехаешь, а не на родном великом и могучем?

  • @eyephpmyadmin6988
    @eyephpmyadmin6988 ปีที่แล้ว

    Have your text editor have an auto word finishing but with some python or rust, I've always wanted one that works for rust

  • @hahamartin6595
    @hahamartin6595 ปีที่แล้ว

    hi tsoding ,my english is bad ,but l like your stream about programming , recently i watch your stream about context free grammar but now l can't find the stream url . can u packing the stream ,and upload the youtube? thanks @Tsoding Daily

  • @OggieSutrisna
    @OggieSutrisna ปีที่แล้ว

    what font is he use?

    • @effede6365
      @effede6365 ปีที่แล้ว

      Victor Mono

    • @auntiecarol
      @auntiecarol ปีที่แล้ว

      @@effede6365 Looks more like Iosevka to me.

    • @effede6365
      @effede6365 ปีที่แล้ว

      @@auntiecarol Thanks for a nice font I didn't know! Tsoding said he used Victor on a previous video.

    • @auntiecarol
      @auntiecarol ปีที่แล้ว

      @@effede6365 I am happy to be proved wrong! How else do we learn?