How to simulate Touch event in Linux/Mac/Windows? - linux

I wanna to simulate touch event in Windows / Mac OS X or Linux (OS is not critical).

Under Windows Vista and Windows 7, the Multi-Touch Vista drivers let you use 2 mice to simulate multi-touch gestures. It should degrade nicely to the "normal" touch experience. In my experience, it can be fairly tricky, but it works.
It really kind of depends on what you're working on and what the goal is. If you can separate the response from the action in your application, that will make it a lot easier to test something like this without going through a lot of hassle.
If you wind up needing a touch device, Wikipedia has a nice list of multi-touch devices.

A lot of time passed since this question, however, maybe someone will google for similar question and find that there is another option:
If you have android device, you can use your device as touch screen for windows.
Maybe there are other software to do this, but I used following one:
https://play.google.com/store/apps/details?id=com.tnksoft.winmultitouchfree
This program from some japanese guy coupled with desktop app does the trick.
You can get desktop app from his site http://www.tnksoft.com/ .
Unluckily it is japanese site, but it's not hard to find necessary program there(it has easily recognisible icon)>
Alternatively you can get link once you install android app.

Related

How can I make a application launcher from scratch in xorg

So in linux there are all kinds of menus and application launchers, but no one of them suits my needs.
Please, let me explain you what I want to do.
I student in a school now so we have fancy dreams and all those never getting involved ideas, but luckily I try to realize some of them.
I want to build an open source gaming platform, a video game console with a linux distro that is based on debian stable liquorix kernel and all that kind of stuff, but it needs its custom DE and something different from the PC interface as it will be controlled by a gamepad and will be a video game console, people must think it is not like a PC, people must see the cool interface and kind of realize that it is different.
The problem is:
All applications menus from other Desktop environments are a bit too windows-like which does not provide a video game console experience.
What do I need for that? How can I read a source code from other applications menus? How can I make something rounded in xorg, as I want to make it a cs:go-like rounded menu (CS GO is just for a reference, I don't play that!)?

How to simultaneously run multiple window managers (esp. xmonad) for VNC

I'll start with a little background. A small project of mine has been to try to use my Android tablet as an external monitor for my laptop using a VNC client (vnc4server). There are two main options for doing this that I have seen. The simplest is to use xrandr and widen the screen, creating a section just for the tablet. However, this can cause some graphics issues if I understand correctly, although it has the benefit of permitting windows to cross displays. The other option is to run a separate desktop session for the VNC server.
I have chosen to go the route of a second desktop as the session can live and die without significantly affecting my main session and can in theory be tailored specifically to the tablet. A little tool called x2vnc allows me to connect to the VNC server in a similar manner to the more popular Synergy and use it like a n external monitor. I also have the nice little benefit of being able to easily and cleanly switch from landscape to portrait using xrandr.
This brings me to my current issue. So far, I have only been able to reliably use plain x-windows. Although this is entirely functional, I would prefer something more complete. Although xstartup examples have been posted for a variety of window managers, none of these seem to run properly. I suspect all of these are for headless systems. Gnome/Unity are each unforgivably slow and seem to conflict with my existing session. I also feel that these are a little too cluttered for my ten inch tablet. On the other hand, Xmonad simply crashes as soon as I try to open a second window in addition to not updating the graphics properly.
I would like to know anything that will lead me in the direction of a better stable desktop environment. This includes configuration tips and alternate window managers.
I am currently running Ubuntu 12.04 with gnome-xmonad (recently Unity). My xstartup is plain x-window-manager. I have tried any readily available examples for gnome and xmonad that I have been able to find.

Looking for a super tiny linux distro that's sole purpose is running an AIR application?

I'm looking for a really really small linux distribution or process of making my own that's sole purpose is to get an air application to launch full screen and stay there; Essentially I'm building a home kitchen computer that runs entirely as an AIR app.
I have looked into using windows xp; and windows xp embedded but they pose so many issues I figured I'd try modern linux.
I have also seen TinyCore Linux which looks interestingly small but not sure what issues that poses in regards to running AIR and "hardware" accelerated display. I've also thought about stripping down an Ubuntu installation but I'm sure somebody must have done this already; google is just failing me right now...
I'm also interested in running an "embedded" version of say android and running the air app on some arm-based hardware again; with just the AIR runtimes only - although this is less preferred as it's more complex.
I'm also hooking this up to a touch screen monitor (not yet arrived) so I'll need to hunt down or write some drivers for translating the touch events into something AIR can understand... (this was my main intention for using windows in that all the drivers will just work).
What I'm after
Minified Linux kernel with JUST the drivers for the box I need
X Display with accelerated graphics support (Doesn't have to be X if AIR can run on a frame buffer?)
Running a Full screen AIR application (simple enough)
Ability to write back to the filesystem (enough support for AIR)
SSH Access for remote control
Samba for updating the filesystem (easier to maintain the system)
Touch screen support (3M Ex III I think...)
Audio support
Don't need
Don't need any window manager or any other GUI tools unless required by AIR
Don't need any toolbars or file managers or anything; The AIR app is the "OS"
Don't need any package managers or repos
Don't need multi user or logging in; everything can just run as an unprivileged account
Don't need to
I don't mind hand crafting the filesystem and configs if that makes it easier; I'm mainly looking for a "filesystem" that is as tiny as possible that I can just plop my AIR app into and write some scripts to get it to start when the X server starts
Thanks,
Chris
Try an embedded Linux build system such as Buildroot. It can build an entire system from source, and be very lightweight. The basic system is less than 1 MB in size.
Ended up going with Tiny Core. Very tiny and quick to boot up. You can also write extensions for it and you don't have a persistent drive which allows you to just switch the thing off without worry that it's going to break something -- exactly what you need in a kitchen :-D.
My current plan is to:
Just set up a working version using Ubuntu as this is mostly supported by Adobe
Slowly strip it back and try and get as little things to start as possible on boot
Try building my own distro/package from source and selecting only the packages I need
Compile my own kernel with nearly everything turned off and just leave on the things I need

What are the pros and cons of using a Mac for web development? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
I have been using Fedora Linux for quite some time now for web development (and for other dev stuff as well). But just recently, someone told me that since I'm doing web development, I might as well use a Mac. I feel like Macs are overrated. Why should I (or should I not) use a Mac?
Ok, here is my 2 cents.
I am a PC guy, have been for years.
I purchased a MAC about 3 years ago, and installed the Macromedia Tools (Dreamwaver, etc).
Despite my best attempts, I just could not be productive -- I was just so used to the way things worked in Windows, the MAC OS (while very nice) felt counter-productive to me.
So, I am back to the PC (have been for years).
My point is, whatever OS you are USED to is the one you will be the most productive on, with the only exception being if there is a particular APP that is only available on another OS.
So, I would stick with what you know (apparently, LINUX), or be prepared to lose some productivity for a while.
I have been doing web development on Linux for years. Despite owning a Mac, I have never once needed to use it for web development.
VIM, Apache, MySQL, Inkscape, Gimp, GEdit, Firefox+addons
That is all I need.
I will test in IE and Safari and others, but that is testing, not development.
unless you can think of a reason, why should you?
I can think of one good reason, there's an OSX software called CSSEdit which could be the best CSS editor I ever used. It supports something similar to #region found in VS and also have a good hierarchy view on rules and classes.
I really enjoy using my MacBook Pro for all kinds of development, not just web development, but not for any of the reasons anyone has mentioned. Sure it has nice Unix underpinnings, and is very pretty to look at. The main reason I use the Mac and OS X for development is how well and consistently it works. The keyboard shortcuts are consistent across all applications, and the keyboard is laid out in a way that makes it very natural to use the operating system's commands. For me, it's much easier and faster to use the Mac Keyboard in conjunction with OS X for development, even on a laptop, than it is to use a mouse/keyboard on a desktop. I also don't have to worry about drivers or programs working, like I do with Linux (e.g. Adobe Flex).
I've been using Mac for web development for the past year and have recently moved over to Ubuntu Linux and am having a much better time.
Here's why:
Integrated package management: while macs have macports, this isn't integrated across the whole OS. With ubuntu I can type in a couple of commands (or use a GUI if I were so inclined) and have LAMP up and running in about 3 minutes flat. This is without the user of any shrink-wrapped 'LAMP Installations' like XAMMP or MAMP or EasyPHP, just the raw software itself. This becomes a lot more important when you start using tools like pear, phpunit, rubygems etc which are much less hassle to configure and get working on ubuntu than they were on the Mac.
Nice Terminal: Relevant only to Unix based developers I guess, but it has a nice multi-tabbed terminal (iterm on mac has this, but it became face-achingly slow for some reason) that expands to a complete fullscreen.
UPDATE: I'm still on Tiger. Leopard, admittedly has a pretty good terminal.
Easy Virtualization: Again, Mac may have options for this but I probably gave up trying to install them. I'm currently using wine and virtualbox for virtualizing windows and testing IE for web dev projects.
Nice Open Source Alternatives To Graphics Software: I don't like stealing software, and I can't afford photoshop etc. GIMP and Inkscape are good enough for me. Again these are available on the Mac, but the X windowing system that GIMP uses doesn't work so well on OSX. Flawless in ubuntu however.
Overall I'm just way more productive on a linux machine. This could be because I like things at the terminal rather than with GUI's, but the big win for me is definitely the ease of installing new programmer-relevant software with apt-get.
I personally don't think there are any cons (unlike when I have to develop on windows box GRRRRRR!). The pros are as follows
Test in any browser on on any platform
Apache built in (But I recommend MAMP)
Great native developer tools (Coda BBEdit et al)
A major con is the lack of Internet explorer. That being said, I have Internet Explorer 6 installed Via Wine, so I can use it like any other Mac program (in X11).
It also probably takes more work to get ASP setup on a mac, like installing mono, but even that is easy enough.
There is a lot of great web software that I LOVE on the mac, such as Coda, Transmit, CSSEdit and TextMate.
I'm a PHP programmer, and having developed on a Mac for 2 years, I've come to the conclusion I would rather be using anything else.
Since the original question was in regards to using a Mac instead of Linux for web development, that's how I've rephrased my pros & cons.
Pros of Mac over Linux:
Fully supported by commercial grade products (Adobe, for example).
Cons of Mac over Linux:
Larger than normal buy-in cost for a complete system.
Closed system - no hardware upgrades except maybe HDD & RAM.
Edit: In regards to the comments I've received, I've re-evaluated my response to be more in line with the original question.
It really doesn't matter when coming to the Web. Adobe's products are considered some of the best in the industry - such as Flash and Photoshop. You can easily get these on Windows too.
I think that web development is one of the things Linux is very good at, because you can easily setup all the standard server side components. On a mac you can do that too but MacPorts and Fink just don't are the same quality and so updated as Debian, Ubuntu, Fedora, etc.
One point for the Mac may be the availability of good commercial development products.
For web development it really doesn't matter what kind of operating system you are using. Even though I am using a Mac, web developers using Windows may have the advantage of running Internet Explorer native while the rest has to use virtual machines for that. But again, it doesn't really matter then.
The only pro-point I can think of is that 90% of the design folks are using Macs, so you would be able to keep up with the coolness-factor many of them are trying to pull-off.
Well if I remember correctly, you can't really do flash developmenton Linux. Plus, as much as people praise the merits of GIMP, I don't think it's quite on par with Photoshop / Illustrator in term of ease of use (heck there is a part in the FAQ that explain you how to draw a circle).
I tend to prefer Windows for whatever developpement though as I really like Visual Studio.
It's my impression that a lot of Ruby on Rails and other relatively new and cool languages have good support on the Mac. I often read about Silicon Valley hipsters (there's that word again) being Mac-centric.
Also, obviously, if you ever intend to get into iPhone development, you'd be all set.
CSSEdit + Adobe Dreamweaver + TextMate + Transmit FTP + Firefox with FireBug and FirePHP and you good to go on MAC ;)
I moved to MAC 2 years ago, no regrets.
It's certainly handy to have a Mac around, if nothing else to check for Safari compatibility, but most of the better tools I've encountered are pretty much platform independent (outside of the .Net world anyway, and even they have Mono).
All of the following are available on all the major platforms
Firefox/firebug for browser debugging (on Mac, Windows and Linux)
Eclipse or Netbeans for IDE (ditto)
Tomcat
Xampp is available on all major platforms in slightly different flavours and gives you most of the tools you'd need for a whole class of development.
The only reason I can see to tie yourself to a particular platform If you have a particular niche you need to target and the application only runs on that one platform. But as this is web development you're talking about you may well find yourself excluding most of the world.
After juggling with various environments. I finally have the following configuration.
Use Windows for Visual Studio Team System development.
Use WinSCP, Notepad++ on Windows to connect to a Linux machine via sFTP and develop PHP
Use terminal on MAC for mysql development. Sometimes I use putty on Windows as well.
Use MAC for Flash CS4 and Flex development.
Overall, in my context, I found Windows to be much stronger platform than MAC for web development.
Really, the issue is that Apple sells hardware and a user experience. With the Mac you would be able to bring the computer to any local apple store for rapid repair and tech support. They wrap the open-source BSD like Darwin OS with a convenient GUI that they control to present a unified experience. So it's just as powerful as you are used to an OS being but has amazing convenience for both software and hardware.
As others mentioned you can run IE with wine, so there's nothing you can't do on it for web development, plus there are great mac only webdev apps (read the other posts).
e.g. I develop on my mac using the full power of *nix (the differences are negligible, like if you need to use RC for anything and don't want to mess with OSX's launched). If anything goes wrong with the hardware I go to the local mall, they fix it asap, and I'm back to programming.
Do you really want to buy your Dell and mess with installing whatever OS then when it breaks talking with some guy in India before they'll let you ship it to Kazmandu for fixes?
Why not give it a try?
While developing any commercial web based application it is important to give "Look n Feel" and "Usability" its due importance. DUring development phase the application looks and works excellent on MAC but when run on Windows, it starts to show problems.
Considering the large number of target audience who use Windows or Linux, I feel that development of Web Applications is better done on Windows or Linux.
Pros: TextMate & CSSedit
Cons:
here is what I see that are good on Mac's for web dev
CSSEdit (only for Mac) - this package makes CSS editing so much easier. The X-ray function is a must have. Firebug has somewhat similar capability and free, but it's just not as well implemented as CSSEdit, and I searched for Windows equivalent and found none.
Probably better support with Adobe software than Linux :p
Coda or Espresso (only for Mac) are two other web developing suit I personally think are much better then Dreamweaver.
System is fairly hassle free. Less time dealing with system. More time for coding, or whatever it is that you want to do.
Exposé windows management is a great time saver too
Time machine back up is another gem. Easy to setup, and saved my butt quite a few times.
Colors system on Macs are better than Windows as far as I know
Parallels Desktop or VMWare are fast enough to debug IE, so no reboot or a separate computer necessary. (Sorry, not sure what the Fedora situation is though)
OS interface is much better than windows (again, no Fedora experience here). It takes about 2 weeks to get used to (from several friends experience). After that, there is usually no turning back.
There are cons of course, but right now I can only think of one:
Notebook's screen sucks… all TN panels. They are maybe good enough for average users, but for any color critical work, it's just no up to the snuff, so if you get a notebook, you wanna get a decent external monitor.
The Mac doesn't really have an edge over Linux for Web Development. If your comfortable and productive on Linux don't bother switching.
However, If the thought of having Unix with a pretty face and well thought out GUI appeals to you then the Mac is an excellent choice. I have one for development at work and use Linux at home for personal projects. For development work there isn't much difference. The difference is in all the non-development stuff.
For instance I absolutely love Quicksilver on the Mac. It's a wonderful interface to most of what I do. I almost never use it when doing code though. It comes in handy when I launch music or open a web page or play a video or any one of a hundred other things I do on that machine. The polish is nice but when it comes time to get serious I just pull up a shell and get just as productive as I am on Linux.
I cannot speak for myself, as I don't own a Mac (or have consistently worked on one), but I work in an environment full of Macs. And I can tell you, most of them are mac users that happen to be web developers as well. They are productive because they take advantage of whatever the features a Mac offers them, and can control their environment. This applies to all operating systems, but the switch involves a learning curve that you must be willing to accept.
You should also consider compatibility, when working on a team. We usually don't have any problems setting up the application environment or working consistently with the code between different OS. But if you need to do image edition stuff, work with very Mac specific tools or need specific software (IE comes to mind), you may be tied to the OS.
The short answer: it depends on how much effort do you require for adapting. The user experience in Mac seems to be the killer feature over deciding. Other than that, they are pretty much the same in term of productiveness, except maybe for the software some people has pointed out already.

First steps to begin developing with J2ME

I am a .NET programmer who needs to port one good Desktop OTP system already at work to be used into cell phones. As far I know J2ME is the correct answer to do it. I'll appreciate any good advice about IDE, first steps, books or any other information.
Well, Eclipse IDE have good J2ME support, or so I've heard.
For api, read the javadocs:
http://java.sun.com/javame/reference/apis.jsp
You'll have to figure out which device you want to target, and grab its emulator.
Then, proceed making a hello world app with the aid of tutorials.
I would give NetBeans a try as well. Eclipse and NetBeans are very similar, but the differences can be night and day depending on your personal preferences. NetBeans also has great J2ME project support, and it is plug and play for any emulator of a device you may need to target, though I recommend sticking to the default or SonyEricsson's. Motorola's was always buggy and never reflected the device at all, and Nokia's was always sloooow.
Also, there are a ton of devices out there. Before you jump head first into this you should define a scope of exactly which devices you will need to target. This will have a huge impact on scheduling as porting is no small task.
Finally, just get your hands on the actual devices you need to target. Emulator is a good way to start, but there are always so many nuances and problems that pop up once you throw the app on the device that it's best to have your target devices from day one.

Resources