TeXworks for newcomers-and what's new for old hands
Kew, Jonathan
This presentation introduces TeXworks, a simple TeX environment based on modern standards\Dash including Unicode text encoding, and PDF output by default Dash with an uncluttered interface that does not overwhelm the newcomer. It is built using cross-platform, open-source tools and libraries, so as to be available on all today’s major operating systems, with a native “look and feel” for each.
 So people who have been at conferences before may have also heard me talk about ZTech, which has been my other project in the tech world, but this talk is not about ZTech. I'll try not to mention it again. So what is TechWorks? I've titled this talk TechWorks for Newcomers and I think I can interpret that in two ways. Firstly I want to introduce TechWorks to people here who may not have seen it before. I've talked about it at one or two meetings in Europe, but I don't think I've done one in North America before, so there may be people for whom it's new. But also TechWorks is designed particularly to be appropriate for newcomers to the tech world. It's designed to make tech that little bit more approachable, easy to get started with. And then we'll also look at some things that I knew in TechWorks now that weren't there when it first came out with TechLive last year. So by way of background, I'm sure we've all seen many demonstrations using TechShop on the Mac with many thanks to Dick. And TechShop has been, I think, one of the outstanding success stories in the tech world over the past, I don't know how many years now. But it's done a huge amount to make tech attractive to Mac users. It's a great program. The one shortcoming it has is that it's only on the Mac. But it offers this very simple, minimalist user interface that I think many users find straightforward, simple to work with. It works directly with PDF tech to create a PDF file which everyone knows what to do with. Nobody knows what a DVI file is. Well, obviously we all do. But all those people out there who might use tech if they weren't so scared of it, they've got no idea what a DVI is or what to do with one. But PDF they understand. And of course TechShop has this delightful user interface that fits right into the operating system and gives you lovely touches like the magnifying glass and now sync tech support to get between PDF and source. So TechWorks was conceived to try and bring a similar kind of experience to users who don't happen to use a Mac. Of course, an awful lot of people out there don't happen to use a Mac. They use Windows or they use Linux or they use BSD or whatever. So the TechWorks project with much encouragement from Carl and Dick, it sort of began a couple of years ago when we had dinner at a tug meeting and decided to try and do this. The idea was to bring that kind of experience to new users, whatever platform they might happen to be using. So here's a typical example of what interfaces, this one's on Windows, isn't it, to tech look like? If you're a newcomer to the tech world and you launch a program and it looks like this, I think for many people the reaction is one of horror. It looks complex. It looks intimidating. It presents you with, I don't know, how many dozen little buttons with cryptic icons on them. If all I want to do is type once upon a time in a galaxy called, there was a computer named Story from the TechBook, I want to type a letter or something. This is, well, it's overkill. I'm not saying this is a bad interface, but it's not the right interface for every kind of user. And I think for many non-technical potential users, it's a scary interface. Here's another one with special symbols and Greek letters and so on all over the place and a zillion buttons and a little area where you can type. Here's another example. These are just random screenshots I took a couple of years ago, so they may be out of date, but of what various tech interfaces look like. And for the people they're designed for, I think they're great. They offer lots of tools, but I think there's also a lot of people for whom they're just intimidating, they're frightening, they're confusing. So this was TechShop. Just a whole lot simpler, cleaner, very little to get in your face and confuse you. Just the bare minimum you need to start typing a document, type set it and see some output. TechWorks aims to bring that same experience to users across a much wider spectrum. So the goal was to develop this using free software tools components so that it could be distributed freely with TechLive or other distributions. So TechWorks is built using Poplar, which is a free library that gives us PDF display and QT, which is a framework for building applications and made it possible to put together a reasonably modern, GUI application in a finite amount of time. So what are the features that we have to offer? Well, it's in many ways a lot like the features TechShop offers, a straightforward text editor with the usual kind of features that people expect, including syntax coloring for tech and latex, auto completion of tech commands that is available there for people who know what they want to do, but you don't have to use it. It's not going to get in your face if all you want to do is type. Then there's the ability to execute the type setting engine to generate formatted output and then other tools like BibTek or MakeIndex and a window to view the output, which is based on PDF display. So by default, we expect people to be running tools like PDF tech or Z tech or Lua tech now that directly generate PDF. It shares a lot of interface features with TechShop. I don't know what I would have done without Dick as a model. So we have the same ability to retype set with one click from either the source or the output window. We can jump between the source and the output using sync tech features. The interface is localizable. So currently, you can run the tech works interface in 19 different languages, thanks to a whole bunch of people who have translated it into their particular favorite. Of course, there's a lot of room for growth, a lot of more power user features that would be nice to have somewhere down the road in the future. But one key consideration, I think, is that any power user features that we add must not get in the way of a newcomer. They must not complicate the interface so that someone coming to this for the first time wanting to work through a little tutorial type, their first tech document, isn't going to be faced with a thousand and one features that were specialized for people writing a physics paper or a math paper or something. But they're never going to understand. Actually one of those power user features is there now, a scripting language for extensibility. The idea is that tech works itself, the core application, will try to stay simple and straightforward. But now that we have the ability to add, to use a scripting language to extend that, then users with specialized needs or more advanced needs can customize it to suit their particular needs without us having to build that into the core program and complicate life for everyone. In fact, we have several scripting languages. We'll see that in a moment. You can choose now between three different languages to write your scripts. So hopefully that will avoid some of the language wars about which one should we do. Is it going to be Lua or is it going to be Python or is it going to be Ruby? Well, take your pick. Actually, we don't have Ruby at the moment, but somebody could do it if they want. So tech works was released last year, the time of the tech live release, version 0.2 was the first stable version that we released. There had been experimental prototypes before that. For Windows it shipped with tech live. For the Mac it also shipped with the Mac tech distribution. Mac tech picked it up at about the same time and so it is installed as a standard part of Mac tech for the past year or so. And there are people packaging tech works for various different Linux distributions and other types of, I think there have been some BSD packages. I don't know much about that. That's totally out of my hands, but obviously I'm very happy for people to do that and make it available through the appropriate channels for each different environment. So what's coming soon in this summer's release, which will be 0.4, not out yet. We're still in the experimental release stage, but very, very soon now. There will be extensibility via scripting languages. What goes into the application is QT script, which is like JavaScript for those who have done some web development. But then we also support plugins that can interface other scripting languages to the same core functions in the program. And we have plugins for Lua and for Python. And there are two basic categories of scripts that are supported. We call standalone scripts, which appear in the menu of the application and can do whatever you want them to do, insert a special bit of text or make changes to your document or something. And then there are hooks, which are scripts, which are automatically activated at certain times, such as when a new file is opened or when a type setting job has just finished. And then those script can step in and do some additional operation. So I'll show a few examples of those. So demo time. Let's hope this works. Let me see. This is actually TechWorks that I've been showing the slides from here. And it's really confusing with the resolution being different. Let's open up a new file. So this is a simple LaTeX sample document that everybody's seen, sample2e. And TechWorks editor shows it with syntax highlighting, which can be customized by the user if you want to. And if I rerun PDF. It types it and here's the output on the other side, which we can zoom in and look at. Let's enlarge that a little bit at least. Now what did I want to demonstrate while I have this open? Okay, well, first of all, let's just show that we can change the language that we're running in. So, for example, Bruno's here. So let's run it in French. There we go. And TechWorks menus are now French. Or if we bring up the preferences dialog, again, that's now in French. We could even go with Russian, for example. And now we're running in Russian. Or how about Chinese? Yes, that works too. So here's TechWorks in Chinese. Let's get back to English so I don't get too lost. Because those are coming from a list that's not part of TechWorks itself. They're coming from the language resources. Potentially we could try and do that sometime. But yes, there are certain things that don't show up localized right now, but almost everything does. Yeah. Okay, let's see. Sync text. If I can command click at a point in the source here and my PDF view has suddenly jumped to show the same point. Highlighting in the PDF. Or if I scroll to a different place in the view and command click here, it will jump to the corresponding place in the source. That's the sync tech feature at work to navigate between source and preview. Experimental new thing that we have in here now is autofollow option, which as I move about in the source file, it will automatically highlight the corresponding place in the PDF. So when I go on to the next page, it will automatically follow where I'm editing and show. Personally, I don't much like that, but a user was asking for it, so we thought we'd give it a try. Is the which? The output is paginated, yes. So that's viewing the full page, but if I zoom in a little bit more, then you can see it more closely. Let's enlarge that a bit more. Let's see. Okay. Features in the editor. One would be command completion, which again is modeled on TechShop. If I want to insert a new section command in here, I could just type it in completely manually, but if I just begin typing it and hit tab, it can also complete the command for me. There's a customizable list of all those completions if I wanted to insert a figure. So I need a begin figure, end figure frame. I could just use BF. That first expanded to text BF, but there are alternate expansions that I can cycle through. And so it can be very efficient to enter text once you're familiar with a set of abbreviations and say those can be customized by the user. There's just a simple text file that lists those. Because it's a TechAware editor, if I turn on spell checking, let's make it English, it knows to not spell check the latech commands in here, so we're not seeing errors. That would show up better, of course, if we pick a different language, like if we tell it this is French, then it's almost all spelled incorrectly. But it still doesn't highlight latech here because it's a command control sequence. It will try to spell check, well, except the math will mostly be control sequences, so then it will ignore them. It's not clever about that. Let's see. Okay, let's show a few examples of what you can do with scripting in the new version that's coming this summer. Yeah? By default, it will soft wrap as you type. There is an option to apply hard wrapping to the text, so if you want to do that, you can. It doesn't automatically hard wrap as you type at the moment, at least. That's a feature that has been asked for, perhaps we'll get it done. Let's look at scripts a little bit. Start with something very simple. So I don't have enough screen space here. Okay, let's put that out of the way. I don't want to build in a lot of features into tech works that are oriented to one specific format, such as latex, then all the people using context, those features will just get in their way, cluster the interface. So things like adding specific latex markup are things that can be added with scripts for the people who want that, and the context users can do something completely different, and the plain tech users can do their own thing. So examples of latex styles would be bold. I have a script that will apply bold tagging around the selected text. It's actually a script that's smart enough to toggle, so if I do it again here, it will take it away. So let's have a look at how that's done if we bring back managed scripts, toggle bold. So is that at all readable from back there? This is written in QT script, the JavaScript version. And because I wanted it to be the smart thing that recognizes if the markup is already there so it can toggle it on and off, it has a function here that I'm not going to try and go through or anything, but it looks at the text that's selected in the document to see whether the boldface markup is there around it, and if so, it will take it away, and if not, then it will add it in. And so we can call that function and just pass it the markup. And I've got another one that does exactly the same thing for emphasize text, and so that's based on the same function, just adding mf instead of text bf. You can apply those so we can make that bold and we can even do both. If I am bold, it won't take the bold away because it's not directly nested, it will add it again. So we can undo them in reverse sequence. Another one that's again done with a script so that it can be customized is title case. There are built-in uppercase and lowercase operations that you can apply to selected text. Title case is a bit trickier because it's very language specific. I don't want to hard code that into the application, but I do have a script that will apply a title case transform to the selected text, and it knows about words like of that should be skipped. And because it's a script, that's straightforward to customize for your particular needs in title casing. It's not hardwired into the program. Okay, let's look at what you can do with hook scripts. I have several here, but they're currently turned off. So if I put a couple of errors into my document here, let's take that away, but we'll add in break here, which is going to cause an extremely under full line, and let's mistype a command here as well. Right now, if I run that, I just get the standard latex log here with error messages hidden away in the middle of it, rather hard to find. But if I find, where's my scripts window gone? Manage scripts, here it is. If I turn on a script here, this is a hook that will run after the typesetting job, and then it analyzes the log to try and locate the error messages and present them in a nicer form. So if I rerun this now, then I've got two panels out, but I've got the standard console output, but I've also got this latex errors summary, and that was extracted by the script from the log, and I can click on that to get to the place in the source where that message came from, or the undefined control sequence here, which we can go and fix. So that makes it a lot easier to navigate the messages that the job produced. And again, because that's a script rather than a hard coded feature in the program, it can be adapted to suit different formats, context, I don't know, probably generates error messages that are quite different from what latex generates. It would be appropriate to have a different script to analyze the results of the run. Let's see, another one that a user asked for just very recently was, if I open a.bib file, I have TechWorks set by default to show latex syntax coloring, but in a.bib file, that's not really very appropriate. It only colors occasional fragments. Very important, I also have my editor configured to do smart quotes by default, so that if I just use the double quote key on my keyboard, it will generate the text style open quotes, and at the other end here, it will generate the close quotes. But if I'm editing my.bib file, I need to use real double quote characters, and it's going to be wrong if we start entering a new record and put text style quote marks around fields. So to deal with that, how about having a special mode for.bib files? Well again, that's getting very narrow and specialized, and I don't want to build that into the program, but I have somewhere here a script, let's see, manage scripts again, yeah, set bibtech mode, just a very simple script which looks at the file name that's just been opened. This is a script that runs on load file. If the file name ends with.bib, then it will turn off the smart quotes mode, and it will turn off the latex syntax coloring. That can, but you can choose your defaults to have. Yes, it probably should be and will be. So if I turn that script on, and then reopen my.bib file, it will come up without the syntax coloring, and if I type quote marks, I just get the plain ASCII quote marks. I haven't done yet, but the syntax coloring again is customizable, so if somebody wants to write a bibtech version, be welcome to have a go. Okay, just a couple more things that we can do with scripts. It's possible for scripts to present user interface of their own, so if I had a block of lines here that I wanted to turn into a latex list, I have a little script that can do that, and it puts up an interface to ask which kind of list do you want. So let's have an enumerate, for example, and it will wrap that block of text. An enumerate with item on each line. We can do the same thing, but with maybe a custom MyList environment that I might have defined in the preamble, and that is entirely again controlled by that particular one that's written in Python, so there's a Python script that calls back into techworks to put up its own custom user interface, take the results from that, put it into the document. So those kinds of features, I think, don't belong as built into the editor, but the extensibility is there for people who want to go further and customize it to suit their particular needs. One more fun one is to show that it's possible for a script to actually execute system commands, if I type ls-l in here and run a system script here, it will execute that as a shell command and put the results back in my document. Obviously, the potential there is to do all sorts of external manipulations that you might want to do as you develop a document. Running ls isn't particularly useful. Okay, let's quickly just finish up here. Come on, yes, there we go. So yes, one minute the right way up. Techworks is a free open source project. I'd love to have more people contributing. I do want to just give a special mention to Stefan Löffler, who over the past year has been a huge contributor. A lot of the new features that are there this year that weren't in Techworks last year are thanks to his work, and I'm as much just monitoring and managing as writing code anymore. It's great. Also, many thanks to the localizers and those who've contributed in that way. Alan Delmotte has written a manual that came out with last year's release of Techworks. I hope he'll have a chance to update that for the new version, but obviously that will depend on his time. That's really, I think, what I wanted to cover today. So there you have it. That's Techworks. Thank you. I'll say some questions for the break and just ask you personally. Is there any BIDI BIDI editor support at all in Techworks? Can you switch it like in like Notepad? Can you switch it to the, instead of left to right, but type from right to left? Okay. Yes, you can. That's one thing that works better on some platforms than others, I believe, because of how the underlying QT frameworks work. Probably the best for us to look at that kind of hands-on and see just how well it works. I know there are some Persian guys and Arabic users who are using it, but I don't really know much detail of exactly how well it works. You can switch it to right to left mode, or is it just follow the bi-directional algorithm? It should follow the bi-directional algorithm. I think the default direction switches if you choose the Arabic or Persian interface language, I think, but I'm not even totally sure on that because it's not something I use myself. All right. I know we don't have time. I'll save my next question for when I talk to you privately. You started with showing some additive is lots of icons and whatever. If I look at what you showed, there's a danger that it gets replaced by a lot of menus and options and scripts and whatever. My question is, how easy is it to configure techworks in such a way that it starts with only the specific subsets of features that you want? I tried to do something with context by having a set of setup files that it would use for start-up, but it's not trivial because techworks generates some structure itself and things like that. Is that on the agenda to make it so that you can say we can start up context beginners mode with only a limited menu? That was the original idea to keep it simple. At the moment, you can't customize the built-in menu commands at all. The customization is all in the extension of syntax coloring modes, indent modes, scripts and so on. Those you could customize and ship just a limited set or a more complete set. We do want to make it possible for scripts to actually not just add to the script's menu, but to modify all the existing menus as well, but that's not in place yet. You would be able to use a script to customize the content of the edit menu or something and take away the commands you don't want to show. Can you customize the key bindings, say Emacs style or whatever the user wants? As far as I know, I don't believe you can customize the key bindings built into the editor. You can customize the shortcut keys to all menu items and so on, but not the basic editing functions. Those are built into the QT editor that we're using. Hopefully that'll be a forthcoming feature. I mean, if you want to have a good user interface, we shouldn't have to relearn how to type. I'd agree that would be a good thing. I don't currently have a plan of, well, we can override everything QT does and we do override a few things. I don't think it's impossible, but it's not currently being worked on. Thank you. This goal is to give newcomers an easy to use interface. How is there a way for them to upgrade their installation when the next version? That would be nice. There's not currently any built-in support for that. I guess distributions like MiG-Tech or Tech Live will replace when a new version comes out, but there's not anything built into the program itself. I'd like to do that, but being a cross-platform product makes that pretty hard. Solutions to that tend to be very platform-specific. Okay. Thank you again. Thank you.
 So people who have been at conferences before may have also heard me talk about ZTech, which  has been my other project in the tech world, but this talk is not about ZTech.  I'll try not to mention it again.  So what is TechWorks?  I've titled this talk TechWorks for Newcomers and I think I can interpret that in two ways.  Firstly I want to introduce TechWorks to people here who may not have seen it before.  I've talked about it at one or two meetings in Europe, but I don't think I've done one  in North America before, so there may be people for whom it's new.  But also TechWorks is designed particularly to be appropriate for newcomers to the tech  world.  It's designed to make tech that little bit more approachable, easy to get started with.  And then we'll also look at some things that I knew in TechWorks now that weren't there  when it first came out with TechLive last year.  So by way of background, I'm sure we've all seen many demonstrations using TechShop on  the Mac with many thanks to Dick.  And TechShop has been, I think, one of the outstanding success stories in the tech world  over the past, I don't know how many years now.  But it's done a huge amount to make tech attractive to Mac users.  It's a great program.  The one shortcoming it has is that it's only on the Mac.  But it offers this very simple, minimalist user interface that I think many users find  straightforward, simple to work with.  It works directly with PDF tech to create a PDF file which everyone knows what to do  with.  Nobody knows what a DVI file is.  Well, obviously we all do.  But all those people out there who might use tech if they weren't so scared of it, they've  got no idea what a DVI is or what to do with one.  But PDF they understand.  And of course TechShop has this delightful user interface that fits right into the operating  system and gives you lovely touches like the magnifying glass and now sync tech support  to get between PDF and source.  So TechWorks was conceived to try and bring a similar kind of experience to users who  don't happen to use a Mac.  Of course, an awful lot of people out there don't happen to use a Mac.  They use Windows or they use Linux or they use BSD or whatever.  So the TechWorks project with much encouragement from Carl and Dick, it sort of began a couple  of years ago when we had dinner at a tug meeting and decided to try and do this.  The idea was to bring that kind of experience to new users, whatever platform they might  happen to be using.  So here's a typical example of what interfaces, this one's on Windows, isn't it, to tech  look like?  If you're a newcomer to the tech world and you launch a program and it looks like this,  I think for many people the reaction is one of horror.  It looks complex.  It looks intimidating.  It presents you with, I don't know, how many dozen little buttons with cryptic icons on  them.  If all I want to do is type once upon a time in a galaxy called, there was a computer named  Story from the TechBook, I want to type a letter or something.  This is, well, it's overkill.  I'm not saying this is a bad interface, but it's not the right interface for every kind  of user.  And I think for many non-technical potential users, it's a scary interface.  Here's another one with special symbols and Greek letters and so on all over the place  and a zillion buttons and a little area where you can type.  Here's another example.  These are just random screenshots I took a couple of years ago, so they may be out of  date, but of what various tech interfaces look like.  And for the people they're designed for, I think they're great.  They offer lots of tools, but I think there's also a lot of people for whom they're just  intimidating, they're frightening, they're confusing.  So this was TechShop.  Just a whole lot simpler, cleaner, very little to get in your face and confuse you.  Just the bare minimum you need to start typing a document, type set it and see some output.  TechWorks aims to bring that same experience to users across a much wider spectrum.  So the goal was to develop this using free software tools components so that it could  be distributed freely with TechLive or other distributions.  So TechWorks is built using Poplar, which is a free library that gives us PDF display  and QT, which is a framework for building applications and made it possible to put together  a reasonably modern, GUI application in a finite amount of time.  So what are the features that we have to offer?  Well, it's in many ways a lot like the features TechShop offers, a straightforward text editor  with the usual kind of features that people expect, including syntax coloring for tech  and latex, auto completion of tech commands that is available there for people who know  what they want to do, but you don't have to use it.  It's not going to get in your face if all you want to do is type.  Then there's the ability to execute the type setting engine to generate formatted output  and then other tools like BibTek or MakeIndex and a window to view the output, which is  based on PDF display.  So by default, we expect people to be running tools like PDF tech or Z tech or Lua tech  now that directly generate PDF.  It shares a lot of interface features with TechShop.  I don't know what I would have done without Dick as a model.  So we have the same ability to retype set with one click from either the source or the  output window.  We can jump between the source and the output using sync tech features.  The interface is localizable.  So currently, you can run the tech works interface in 19 different languages, thanks  to a whole bunch of people who have translated it into their particular favorite.  Of course, there's a lot of room for growth, a lot of more power user features that would  be nice to have somewhere down the road in the future.  But one key consideration, I think, is that any power user features that we add must not  get in the way of a newcomer.  They must not complicate the interface so that someone coming to this for the first time  wanting to work through a little tutorial type, their first tech document, isn't going to  be faced with a thousand and one features that were specialized for people writing a  physics paper or a math paper or something.  But they're never going to understand.  Actually one of those power user features is there now, a scripting language for extensibility.  The idea is that tech works itself, the core application, will try to stay simple and straightforward.  But now that we have the ability to add, to use a scripting language to extend that, then  users with specialized needs or more advanced needs can customize it to suit their particular  needs without us having to build that into the core program and complicate life for everyone.  In fact, we have several scripting languages.  We'll see that in a moment.  You can choose now between three different languages to write your scripts.  So hopefully that will avoid some of the language wars about which one should we do.  Is it going to be Lua or is it going to be Python or is it going to be Ruby?  Well, take your pick.  Actually, we don't have Ruby at the moment, but somebody could do it if they want.  So tech works was released last year, the time of the tech live release, version 0.2  was the first stable version that we released.  There had been experimental prototypes before that.  For Windows it shipped with tech live.  For the Mac it also shipped with the Mac tech distribution.  Mac tech picked it up at about the same time and so it is installed as a standard part  of Mac tech for the past year or so.  And there are people packaging tech works for various different Linux distributions and  other types of, I think there have been some BSD packages.  I don't know much about that.  That's totally out of my hands, but obviously I'm very happy for people to do that and make  it available through the appropriate channels for each different environment.  So what's coming soon in this summer's release, which will be 0.4, not out yet.  We're still in the experimental release stage, but very, very soon now.  There will be extensibility via scripting languages.  What goes into the application is QT script, which is like JavaScript for those who have  done some web development.  But then we also support plugins that can interface other scripting languages to the  same core functions in the program.  And we have plugins for Lua and for Python.  And there are two basic categories of scripts that are supported.  We call standalone scripts, which appear in the menu of the application and can do whatever  you want them to do, insert a special bit of text or make changes to your document or  something.  And then there are hooks, which are scripts, which are automatically activated at certain  times, such as when a new file is opened or when a type setting job has just finished.  And then those script can step in and do some additional operation.  So I'll show a few examples of those.  So demo time.  Let's hope this works.  Let me see.  This is actually TechWorks that I've been showing the slides from here.  And it's really confusing with the resolution being different.  Let's open up a new file.  So this is a simple LaTeX sample document that everybody's seen, sample2e.  And TechWorks editor shows it with syntax highlighting, which can be customized by the user if you  want to.  And if I rerun PDF.  It types it and here's the output on the other side, which we can zoom in and look at.  Let's enlarge that a little bit at least.  Now what did I want to demonstrate while I have this open?  Okay, well, first of all, let's just show that we can change the language that we're  running in.  So, for example, Bruno's here.  So let's run it in French.  There we go.  And TechWorks menus are now French.  Or if we bring up the preferences dialog, again, that's now in French.  We could even go with Russian, for example.  And now we're running in Russian.  Or how about Chinese?  Yes, that works too.  So here's TechWorks in Chinese.  Let's get back to English so I don't get too lost.  Because those are coming from a list that's not part of TechWorks itself.  They're coming from the language resources.  Potentially we could try and do that sometime.  But yes, there are certain things that don't show up localized right now, but almost everything  does.  Yeah.  Okay, let's see.  Sync text.  If I can command click at a point in the source here and my PDF view has suddenly jumped  to show the same point.  Highlighting in the PDF.  Or if I scroll to a different place in the view and command click here, it will jump  to the corresponding place in the source.  That's the sync tech feature at work to navigate between source and preview.  Experimental new thing that we have in here now is autofollow option, which as I move  about in the source file, it will automatically highlight the corresponding place in the PDF.  So when I go on to the next page, it will automatically follow where I'm editing and  show.  Personally, I don't much like that, but a user was asking for it, so we thought we'd  give it a try.  Is the which?  The output is paginated, yes.  So that's viewing the full page, but if I zoom in a little bit more, then you can see  it more closely.  Let's enlarge that a bit more.  Let's see.  Okay.  Features in the editor.  One would be command completion, which again is modeled on TechShop.  If I want to insert a new section command in here, I could just type it in completely  manually, but if I just begin typing it and hit tab, it can also complete the command for  me.  There's a customizable list of all those completions if I wanted to insert a figure.  So I need a begin figure, end figure frame.  I could just use BF.  That first expanded to text BF, but there are alternate expansions that I can cycle through.  And so it can be very efficient to enter text once you're familiar with a set of abbreviations  and say those can be customized by the user.  There's just a simple text file that lists those.  Because it's a TechAware editor, if I turn on spell checking, let's make it English,  it knows to not spell check the latech commands in here, so we're not seeing errors.  That would show up better, of course, if we pick a different language, like if we tell  it this is French, then it's almost all spelled incorrectly.  But it still doesn't highlight latech here because it's a command control sequence.  It will try to spell check, well, except the math will mostly be control sequences, so  then it will ignore them.  It's not clever about that.  Let's see.  Okay, let's show a few examples of what you can do with scripting in the new version that's  coming this summer.  Yeah?  By default, it will soft wrap as you type.  There is an option to apply hard wrapping to the text, so if you want to do that, you  can.  It doesn't automatically hard wrap as you type at the moment, at least.  That's a feature that has been asked for, perhaps we'll get it done.  Let's look at scripts a little bit.  Start with something very simple.  So I don't have enough screen space here.  Okay, let's put that out of the way.  I don't want to build in a lot of features into tech works that are oriented to one specific  format, such as latex, then all the people using context, those features will just get  in their way, cluster the interface.  So things like adding specific latex markup are things that can be added with scripts  for the people who want that, and the context users can do something completely different,  and the plain tech users can do their own thing.  So examples of latex styles would be bold.  I have a script that will apply bold tagging around the selected text.  It's actually a script that's smart enough to toggle, so if I do it again here, it will  take it away.  So let's have a look at how that's done if we bring back managed scripts, toggle bold.  So is that at all readable from back there?  This is written in QT script, the JavaScript version.  And because I wanted it to be the smart thing that recognizes if the markup is already there  so it can toggle it on and off, it has a function here that I'm not going to try and go through  or anything, but it looks at the text that's selected in the document to see whether the  boldface markup is there around it, and if so, it will take it away, and if not, then  it will add it in.  And so we can call that function and just pass it the markup.  And I've got another one that does exactly the same thing for emphasize text, and so  that's based on the same function, just adding mf instead of text bf.  You can apply those so we can make that bold and we can even do both.  If I am bold, it won't take the bold away because it's not directly nested, it will  add it again.  So we can undo them in reverse sequence.  Another one that's again done with a script so that it can be customized is title case.  There are built-in uppercase and lowercase operations that you can apply to selected  text.  Title case is a bit trickier because it's very language specific.  I don't want to hard code that into the application, but I do have a script that will apply a  title case transform to the selected text, and it knows about words like of that should  be skipped.  And because it's a script, that's straightforward to customize for your particular needs in  title casing.  It's not hardwired into the program.  Okay, let's look at what you can do with hook scripts.  I have several here, but they're currently turned off.  So if I put a couple of errors into my document here, let's take that away, but we'll add  in break here, which is going to cause an extremely under full line, and let's mistype  a command here as well.  Right now, if I run that, I just get the standard latex log here with error messages hidden  away in the middle of it, rather hard to find.  But if I find, where's my scripts window gone?  Manage scripts, here it is.  If I turn on a script here, this is a hook that will run after the typesetting job, and  then it analyzes the log to try and locate the error messages and present them in a nicer  form.  So if I rerun this now, then I've got two panels out, but I've got the standard console  output, but I've also got this latex errors summary, and that was extracted by the script  from the log, and I can click on that to get to the place in the source where that message  came from, or the undefined control sequence here, which we can go and fix.  So that makes it a lot easier to navigate the messages that the job produced.  And again, because that's a script rather than a hard coded feature in the program,  it can be adapted to suit different formats, context, I don't know, probably generates  error messages that are quite different from what latex generates.  It would be appropriate to have a different script to analyze the results of the run.  Let's see, another one that a user asked for just very recently was, if I open a.bib  file, I have TechWorks set by default to show latex syntax coloring, but in a.bib file,  that's not really very appropriate.  It only colors occasional fragments.  Very important, I also have my editor configured to do smart quotes by default, so that if  I just use the double quote key on my keyboard, it will generate the text style open quotes,  and at the other end here, it will generate the close quotes.  But if I'm editing my.bib file, I need to use real double quote characters, and it's  going to be wrong if we start entering a new record and put text style quote marks around  fields.  So to deal with that, how about having a special mode for.bib files?  Well again, that's getting very narrow and specialized, and I don't want to build that  into the program, but I have somewhere here a script, let's see, manage scripts again,  yeah, set bibtech mode, just a very simple script which looks at the file name that's  just been opened.  This is a script that runs on load file.  If the file name ends with.bib, then it will turn off the smart quotes mode, and it will  turn off the latex syntax coloring.  That can, but you can choose your defaults to have.  Yes, it probably should be and will be.  So if I turn that script on, and then reopen my.bib file, it will come up without the  syntax coloring, and if I type quote marks, I just get the plain ASCII quote marks.  I haven't done yet, but the syntax coloring again is customizable, so if somebody wants  to write a bibtech version, be welcome to have a go.  Okay, just a couple more things that we can do with scripts.  It's possible for scripts to present user interface of their own, so if I had a block  of lines here that I wanted to turn into a latex list, I have a little script that can  do that, and it puts up an interface to ask which kind of list do you want.  So let's have an enumerate, for example, and it will wrap that block of text.  An enumerate with item on each line.  We can do the same thing, but with maybe a custom MyList environment that I might have  defined in the preamble, and that is entirely again controlled by that particular one that's  written in Python, so there's a Python script that calls back into techworks to put up its  own custom user interface, take the results from that, put it into the document.  So those kinds of features, I think, don't belong as built into the editor, but the extensibility  is there for people who want to go further and customize it to suit their particular  needs.  One more fun one is to show that it's possible for a script to actually execute system commands,  if I type ls-l in here and run a system script here, it will execute that as a shell command  and put the results back in my document.  Obviously, the potential there is to do all sorts of external manipulations that you might  want to do as you develop a document.  Running ls isn't particularly useful.  Okay, let's quickly just finish up here.  Come on, yes, there we go.  So yes, one minute the right way up.  Techworks is a free open source project.  I'd love to have more people contributing.  I do want to just give a special mention to Stefan Löffler, who over the past year has  been a huge contributor.  A lot of the new features that are there this year that weren't in Techworks last year are  thanks to his work, and I'm as much just monitoring and managing as writing code anymore.  It's great.  Also, many thanks to the localizers and those who've contributed in that way.  Alan Delmotte has written a manual that came out with last year's release of Techworks.  I hope he'll have a chance to update that for the new version, but obviously that will  depend on his time.  That's really, I think, what I wanted to cover today.  So there you have it.  That's Techworks.  Thank you.  I'll say some questions for the break and just ask you personally.  Is there any BIDI BIDI editor support at all in Techworks?  Can you switch it like in like Notepad?  Can you switch it to the, instead of left to right, but type from right to left?  Okay.  Yes, you can.  That's one thing that works better on some platforms than others, I believe, because of  how the underlying QT frameworks work.  Probably the best for us to look at that kind of hands-on and see just how well it works.  I know there are some Persian guys and Arabic users who are using it, but I don't really  know much detail of exactly how well it works.  You can switch it to right to left mode, or is it just follow the bi-directional algorithm?  It should follow the bi-directional algorithm.  I think the default direction switches if you choose the Arabic or Persian interface language,  I think, but I'm not even totally sure on that because it's not something I use myself.  All right.  I know we don't have time.  I'll save my next question for when I talk to you privately.  You started with showing some additive is lots of icons and whatever.  If I look at what you showed, there's a danger that it gets replaced by a lot of menus and  options and scripts and whatever.  My question is, how easy is it to configure techworks in such a way that it starts with  only the specific subsets of features that you want?  I tried to do something with context by having a set of setup files that it would use for  start-up, but it's not trivial because techworks generates some structure itself and things  like that.  Is that on the agenda to make it so that you can say we can start up context beginners  mode with only a limited menu?  That was the original idea to keep it simple.  At the moment, you can't customize the built-in menu commands at all.  The customization is all in the extension of syntax coloring modes, indent modes, scripts  and so on.  Those you could customize and ship just a limited set or a more complete set.  We do want to make it possible for scripts to actually not just add to the script's menu,  but to modify all the existing menus as well, but that's not in place yet.  You would be able to use a script to customize the content of the edit menu or something  and take away the commands you don't want to show.  Can you customize the key bindings, say Emacs style or whatever the user wants?  As far as I know, I don't believe you can customize the key bindings built into the  editor.  You can customize the shortcut keys to all menu items and so on, but not the basic editing  functions.  Those are built into the QT editor that we're using.  Hopefully that'll be a forthcoming feature.  I mean, if you want to have a good user interface, we shouldn't have to relearn how to type.  I'd agree that would be a good thing.  I don't currently have a plan of, well, we can override everything QT does and we do  override a few things.  I don't think it's impossible, but it's not currently being worked on.  Thank you.  This goal is to give newcomers an easy to use interface.  How is there a way for them to upgrade their installation when the next version?  That would be nice.  There's not currently any built-in support for that.  I guess distributions like MiG-Tech or Tech Live will replace when a new version comes  out, but there's not anything built into the program itself.  I'd like to do that, but being a cross-platform product makes that pretty hard.  Solutions to that tend to be very platform-specific.  Okay.  Thank you again.  Thank you.
TeXworks_for_newcomers-and_what_s_new_for_old_hands_0_59.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_60_1631.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_1632_3599.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_3600_4583.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_4584_6191.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_6192_6479.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_6480_7079.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_7080_7655.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_7656_8531.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_8532_9251.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_9252_9599.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_9600_10547.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_10548_10943.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_10944_13559.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_13560_15023.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_15024_16835.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_16836_16967.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_16968_17267.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_17268_17363.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_17364_19019.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_19020_19115.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_19116_19199.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_19200_21227.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_21228_22367.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_22368_23855.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_23856_24239.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_24240_27719.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_27720_29063.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_29064_30995.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_30996_31055.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_31056_31835.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_31836_32339.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_32340_35819.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_35820_35879.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_35880_36299.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_36300_36587.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_36588_36707.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_36708_37463.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_37464_37511.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_37512_38111.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_38112_38255.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_38256_38531.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_38532_40175.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_40176_40307.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_40308_41351.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_41352_41699.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_41700_49847.png TeXworks_for_newcomers-and_what_s_new_for_old_hands_49848_49890.png
So people who have been at conferences before may have also heard me talk about ZTech, which has been my other project in the tech world, but this talk is not about ZTech. I'll try not to mention it again. So what is TechWorks? I've titled this talk TechWorks for Newcomers and I think I can interpret that in two ways. Firstly I want to introduce TechWorks to people here who may not have seen it before. I've talked about it at one or two meetings in Europe, but I don't think I've done one in North America before, so there may be people for whom it's new. But also TechWorks is designed particularly to be appropriate for newcomers to the tech world. It's designed to make tech that little bit more approachable, easy to get started with. And then we'll also look at some things that I knew in TechWorks now that weren't there when it first came out with TechLive last year. So by way of background, I'm sure we've all seen many demonstrations using TechShop on the Mac with many thanks to Dick. And TechShop has been, I think, one of the outstanding success stories in the tech world over the past, I don't know how many years now. But it's done a huge amount to make tech attractive to Mac users. It's a great program. The one shortcoming it has is that it's only on the Mac. But it offers this very simple, minimalist user interface that I think many users find straightforward, simple to work with. It works directly with PDF tech to create a PDF file which everyone knows what to do with. Nobody knows what a DVI file is. Well, obviously we all do. But all those people out there who might use tech if they weren't so scared of it, they've got no idea what a DVI is or what to do with one. But PDF they understand. And of course TechShop has this delightful user interface that fits right into the operating system and gives you lovely touches like the magnifying glass and now sync tech support to get between PDF and source. So TechWorks was conceived to try and bring a similar kind of experience to users who don't happen to use a Mac. Of course, an awful lot of people out there don't happen to use a Mac. They use Windows or they use Linux or they use BSD or whatever. So the TechWorks project with much encouragement from Carl and Dick, it sort of began a couple of years ago when we had dinner at a tug meeting and decided to try and do this. The idea was to bring that kind of experience to new users, whatever platform they might happen to be using. So here's a typical example of what interfaces, this one's on Windows, isn't it, to tech look like? If you're a newcomer to the tech world and you launch a program and it looks like this, I think for many people the reaction is one of horror. It looks complex. It looks intimidating. It presents you with, I don't know, how many dozen little buttons with cryptic icons on them. If all I want to do is type once upon a time in a galaxy called, there was a computer named Story from the TechBook, I want to type a letter or something. This is, well, it's overkill. I'm not saying this is a bad interface, but it's not the right interface for every kind of user. And I think for many non-technical potential users, it's a scary interface. Here's another one with special symbols and Greek letters and so on all over the place and a zillion buttons and a little area where you can type. Here's another example. These are just random screenshots I took a couple of years ago, so they may be out of date, but of what various tech interfaces look like. And for the people they're designed for, I think they're great. They offer lots of tools, but I think there's also a lot of people for whom they're just intimidating, they're frightening, they're confusing. So this was TechShop. Just a whole lot simpler, cleaner, very little to get in your face and confuse you. Just the bare minimum you need to start typing a document, type set it and see some output. TechWorks aims to bring that same experience to users across a much wider spectrum. So the goal was to develop this using free software tools components so that it could be distributed freely with TechLive or other distributions. So TechWorks is built using Poplar, which is a free library that gives us PDF display and QT, which is a framework for building applications and made it possible to put together a reasonably modern, GUI application in a finite amount of time. So what are the features that we have to offer? Well, it's in many ways a lot like the features TechShop offers, a straightforward text editor with the usual kind of features that people expect, including syntax coloring for tech and latex, auto completion of tech commands that is available there for people who know what they want to do, but you don't have to use it. It's not going to get in your face if all you want to do is type. Then there's the ability to execute the type setting engine to generate formatted output and then other tools like BibTek or MakeIndex and a window to view the output, which is based on PDF display. So by default, we expect people to be running tools like PDF tech or Z tech or Lua tech now that directly generate PDF. It shares a lot of interface features with TechShop. I don't know what I would have done without Dick as a model. So we have the same ability to retype set with one click from either the source or the output window. We can jump between the source and the output using sync tech features. The interface is localizable. So currently, you can run the tech works interface in 19 different languages, thanks to a whole bunch of people who have translated it into their particular favorite. Of course, there's a lot of room for growth, a lot of more power user features that would be nice to have somewhere down the road in the future. But one key consideration, I think, is that any power user features that we add must not get in the way of a newcomer. They must not complicate the interface so that someone coming to this for the first time wanting to work through a little tutorial type, their first tech document, isn't going to be faced with a thousand and one features that were specialized for people writing a physics paper or a math paper or something. But they're never going to understand. Actually one of those power user features is there now, a scripting language for extensibility. The idea is that tech works itself, the core application, will try to stay simple and straightforward. But now that we have the ability to add, to use a scripting language to extend that, then users with specialized needs or more advanced needs can customize it to suit their particular needs without us having to build that into the core program and complicate life for everyone. In fact, we have several scripting languages. We'll see that in a moment. You can choose now between three different languages to write your scripts. So hopefully that will avoid some of the language wars about which one should we do. Is it going to be Lua or is it going to be Python or is it going to be Ruby? Well, take your pick. Actually, we don't have Ruby at the moment, but somebody could do it if they want. So tech works was released last year, the time of the tech live release, version 0.2 was the first stable version that we released. There had been experimental prototypes before that. For Windows it shipped with tech live. For the Mac it also shipped with the Mac tech distribution. Mac tech picked it up at about the same time and so it is installed as a standard part of Mac tech for the past year or so. And there are people packaging tech works for various different Linux distributions and other types of, I think there have been some BSD packages. I don't know much about that. That's totally out of my hands, but obviously I'm very happy for people to do that and make it available through the appropriate channels for each different environment. So what's coming soon in this summer's release, which will be 0.4, not out yet. We're still in the experimental release stage, but very, very soon now. There will be extensibility via scripting languages. What goes into the application is QT script, which is like JavaScript for those who have done some web development. But then we also support plugins that can interface other scripting languages to the same core functions in the program. And we have plugins for Lua and for Python. And there are two basic categories of scripts that are supported. We call standalone scripts, which appear in the menu of the application and can do whatever you want them to do, insert a special bit of text or make changes to your document or something. And then there are hooks, which are scripts, which are automatically activated at certain times, such as when a new file is opened or when a type setting job has just finished. And then those script can step in and do some additional operation. So I'll show a few examples of those. So demo time. Let's hope this works. Let me see. This is actually TechWorks that I've been showing the slides from here. And it's really confusing with the resolution being different. Let's open up a new file. So this is a simple LaTeX sample document that everybody's seen, sample2e. And TechWorks editor shows it with syntax highlighting, which can be customized by the user if you want to. And if I rerun PDF. It types it and here's the output on the other side, which we can zoom in and look at. Let's enlarge that a little bit at least. Now what did I want to demonstrate while I have this open? Okay, well, first of all, let's just show that we can change the language that we're running in. So, for example, Bruno's here. So let's run it in French. There we go. And TechWorks menus are now French. Or if we bring up the preferences dialog, again, that's now in French. We could even go with Russian, for example. And now we're running in Russian. Or how about Chinese? Yes, that works too. So here's TechWorks in Chinese. Let's get back to English so I don't get too lost. Because those are coming from a list that's not part of TechWorks itself. They're coming from the language resources. Potentially we could try and do that sometime. But yes, there are certain things that don't show up localized right now, but almost everything does. Yeah. Okay, let's see. Sync text. If I can command click at a point in the source here and my PDF view has suddenly jumped to show the same point. Highlighting in the PDF. Or if I scroll to a different place in the view and command click here, it will jump to the corresponding place in the source. That's the sync tech feature at work to navigate between source and preview. Experimental new thing that we have in here now is autofollow option, which as I move about in the source file, it will automatically highlight the corresponding place in the PDF. So when I go on to the next page, it will automatically follow where I'm editing and show. Personally, I don't much like that, but a user was asking for it, so we thought we'd give it a try. Is the which? The output is paginated, yes. So that's viewing the full page, but if I zoom in a little bit more, then you can see it more closely. Let's enlarge that a bit more. Let's see. Okay. Features in the editor. One would be command completion, which again is modeled on TechShop. If I want to insert a new section command in here, I could just type it in completely manually, but if I just begin typing it and hit tab, it can also complete the command for me. There's a customizable list of all those completions if I wanted to insert a figure. So I need a begin figure, end figure frame. I could just use BF. That first expanded to text BF, but there are alternate expansions that I can cycle through. And so it can be very efficient to enter text once you're familiar with a set of abbreviations and say those can be customized by the user. There's just a simple text file that lists those. Because it's a TechAware editor, if I turn on spell checking, let's make it English, it knows to not spell check the latech commands in here, so we're not seeing errors. That would show up better, of course, if we pick a different language, like if we tell it this is French, then it's almost all spelled incorrectly. But it still doesn't highlight latech here because it's a command control sequence. It will try to spell check, well, except the math will mostly be control sequences, so then it will ignore them. It's not clever about that. Let's see. Okay, let's show a few examples of what you can do with scripting in the new version that's coming this summer. Yeah? By default, it will soft wrap as you type. There is an option to apply hard wrapping to the text, so if you want to do that, you can. It doesn't automatically hard wrap as you type at the moment, at least. That's a feature that has been asked for, perhaps we'll get it done. Let's look at scripts a little bit. Start with something very simple. So I don't have enough screen space here. Okay, let's put that out of the way. I don't want to build in a lot of features into tech works that are oriented to one specific format, such as latex, then all the people using context, those features will just get in their way, cluster the interface. So things like adding specific latex markup are things that can be added with scripts for the people who want that, and the context users can do something completely different, and the plain tech users can do their own thing. So examples of latex styles would be bold. I have a script that will apply bold tagging around the selected text. It's actually a script that's smart enough to toggle, so if I do it again here, it will take it away. So let's have a look at how that's done if we bring back managed scripts, toggle bold. So is that at all readable from back there? This is written in QT script, the JavaScript version. And because I wanted it to be the smart thing that recognizes if the markup is already there so it can toggle it on and off, it has a function here that I'm not going to try and go through or anything, but it looks at the text that's selected in the document to see whether the boldface markup is there around it, and if so, it will take it away, and if not, then it will add it in. And so we can call that function and just pass it the markup. And I've got another one that does exactly the same thing for emphasize text, and so that's based on the same function, just adding mf instead of text bf. You can apply those so we can make that bold and we can even do both. If I am bold, it won't take the bold away because it's not directly nested, it will add it again. So we can undo them in reverse sequence. Another one that's again done with a script so that it can be customized is title case. There are built-in uppercase and lowercase operations that you can apply to selected text. Title case is a bit trickier because it's very language specific. I don't want to hard code that into the application, but I do have a script that will apply a title case transform to the selected text, and it knows about words like of that should be skipped. And because it's a script, that's straightforward to customize for your particular needs in title casing. It's not hardwired into the program. Okay, let's look at what you can do with hook scripts. I have several here, but they're currently turned off. So if I put a couple of errors into my document here, let's take that away, but we'll add in break here, which is going to cause an extremely under full line, and let's mistype a command here as well. Right now, if I run that, I just get the standard latex log here with error messages hidden away in the middle of it, rather hard to find. But if I find, where's my scripts window gone? Manage scripts, here it is. If I turn on a script here, this is a hook that will run after the typesetting job, and then it analyzes the log to try and locate the error messages and present them in a nicer form. So if I rerun this now, then I've got two panels out, but I've got the standard console output, but I've also got this latex errors summary, and that was extracted by the script from the log, and I can click on that to get to the place in the source where that message came from, or the undefined control sequence here, which we can go and fix. So that makes it a lot easier to navigate the messages that the job produced. And again, because that's a script rather than a hard coded feature in the program, it can be adapted to suit different formats, context, I don't know, probably generates error messages that are quite different from what latex generates. It would be appropriate to have a different script to analyze the results of the run. Let's see, another one that a user asked for just very recently was, if I open a.bib file, I have TechWorks set by default to show latex syntax coloring, but in a.bib file, that's not really very appropriate. It only colors occasional fragments. Very important, I also have my editor configured to do smart quotes by default, so that if I just use the double quote key on my keyboard, it will generate the text style open quotes, and at the other end here, it will generate the close quotes. But if I'm editing my.bib file, I need to use real double quote characters, and it's going to be wrong if we start entering a new record and put text style quote marks around fields. So to deal with that, how about having a special mode for.bib files? Well again, that's getting very narrow and specialized, and I don't want to build that into the program, but I have somewhere here a script, let's see, manage scripts again, yeah, set bibtech mode, just a very simple script which looks at the file name that's just been opened. This is a script that runs on load file. If the file name ends with.bib, then it will turn off the smart quotes mode, and it will turn off the latex syntax coloring. That can, but you can choose your defaults to have. Yes, it probably should be and will be. So if I turn that script on, and then reopen my.bib file, it will come up without the syntax coloring, and if I type quote marks, I just get the plain ASCII quote marks. I haven't done yet, but the syntax coloring again is customizable, so if somebody wants to write a bibtech version, be welcome to have a go. Okay, just a couple more things that we can do with scripts. It's possible for scripts to present user interface of their own, so if I had a block of lines here that I wanted to turn into a latex list, I have a little script that can do that, and it puts up an interface to ask which kind of list do you want. So let's have an enumerate, for example, and it will wrap that block of text. An enumerate with item on each line. We can do the same thing, but with maybe a custom MyList environment that I might have defined in the preamble, and that is entirely again controlled by that particular one that's written in Python, so there's a Python script that calls back into techworks to put up its own custom user interface, take the results from that, put it into the document. So those kinds of features, I think, don't belong as built into the editor, but the extensibility is there for people who want to go further and customize it to suit their particular needs. One more fun one is to show that it's possible for a script to actually execute system commands, if I type ls-l in here and run a system script here, it will execute that as a shell command and put the results back in my document. Obviously, the potential there is to do all sorts of external manipulations that you might want to do as you develop a document. Running ls isn't particularly useful. Okay, let's quickly just finish up here. Come on, yes, there we go. So yes, one minute the right way up. Techworks is a free open source project. I'd love to have more people contributing. I do want to just give a special mention to Stefan Löffler, who over the past year has been a huge contributor. A lot of the new features that are there this year that weren't in Techworks last year are thanks to his work, and I'm as much just monitoring and managing as writing code anymore. It's great. Also, many thanks to the localizers and those who've contributed in that way. Alan Delmotte has written a manual that came out with last year's release of Techworks. I hope he'll have a chance to update that for the new version, but obviously that will depend on his time. That's really, I think, what I wanted to cover today. So there you have it. That's Techworks. Thank you. I'll say some questions for the break and just ask you personally. Is there any BIDI BIDI editor support at all in Techworks? Can you switch it like in like Notepad? Can you switch it to the, instead of left to right, but type from right to left? Okay. Yes, you can. That's one thing that works better on some platforms than others, I believe, because of how the underlying QT frameworks work. Probably the best for us to look at that kind of hands-on and see just how well it works. I know there are some Persian guys and Arabic users who are using it, but I don't really know much detail of exactly how well it works. You can switch it to right to left mode, or is it just follow the bi-directional algorithm? It should follow the bi-directional algorithm. I think the default direction switches if you choose the Arabic or Persian interface language, I think, but I'm not even totally sure on that because it's not something I use myself. All right. I know we don't have time. I'll save my next question for when I talk to you privately. You started with showing some additive is lots of icons and whatever. If I look at what you showed, there's a danger that it gets replaced by a lot of menus and options and scripts and whatever. My question is, how easy is it to configure techworks in such a way that it starts with only the specific subsets of features that you want? I tried to do something with context by having a set of setup files that it would use for start-up, but it's not trivial because techworks generates some structure itself and things like that. Is that on the agenda to make it so that you can say we can start up context beginners mode with only a limited menu? That was the original idea to keep it simple. At the moment, you can't customize the built-in menu commands at all. The customization is all in the extension of syntax coloring modes, indent modes, scripts and so on. Those you could customize and ship just a limited set or a more complete set. We do want to make it possible for scripts to actually not just add to the script's menu, but to modify all the existing menus as well, but that's not in place yet. You would be able to use a script to customize the content of the edit menu or something and take away the commands you don't want to show. Can you customize the key bindings, say Emacs style or whatever the user wants? As far as I know, I don't believe you can customize the key bindings built into the editor. You can customize the shortcut keys to all menu items and so on, but not the basic editing functions. Those are built into the QT editor that we're using. Hopefully that'll be a forthcoming feature. I mean, if you want to have a good user interface, we shouldn't have to relearn how to type. I'd agree that would be a good thing. I don't currently have a plan of, well, we can override everything QT does and we do override a few things. I don't think it's impossible, but it's not currently being worked on. Thank you. This goal is to give newcomers an easy to use interface. How is there a way for them to upgrade their installation when the next version? That would be nice. There's not currently any built-in support for that. I guess distributions like MiG-Tech or Tech Live will replace when a new version comes out, but there's not anything built into the program itself. I'd like to do that, but being a cross-platform product makes that pretty hard. Solutions to that tend to be very platform-specific. Okay. Thank you again. Thank you.
designed particularly to be appropriate for find straightforward, simple to work with. It letters and so on all over the place and a TechWorks is built using Poplar, which is a free is based on PDF display. So by default, we expect newcomer. They must not complicate the interface channels for each different environment. So the user. There's just a simple text file that