cross-platform

C++ proc_open analogue

↘锁芯ラ 提交于 2019-12-11 02:14:08
问题 There's a handy function in PHP called proc_open. It could be used to call an executable, opening its stdin , stdout and stderr as pipes. Is there a good cross-platform version of this function in C++? The only googlable thing is this tutorial for Windows (though code from it just hangs). 回答1: You could probably get 'somewhere' with popen (http://linux.die.net/man/3/popen) pstreams library (POSIX process control) - I have no prior experience with this, but it looks solid and was written by

Digital Signatures of XML, PDF and Office Documents on every platform

南笙酒味 提交于 2019-12-11 02:08:25
问题 I'm trying to develop a website that performs digital signatures on client-side and then sent the signed document to the server-side. I want to do the signatures on client, due to the fact of not sending away the user's private key. This key (in theory) must be always with the user and it must not be sent to the web (even if protected with SSL, for example). I want that every platform may be able to sign the documents. I've already developed a Java Applet with the signing algorithms, but Java

How to handle screen rotation/orientation in Xamarin Forms?

佐手、 提交于 2019-12-11 01:51:39
问题 Is there a (half) generic way to handle rotation/orientation in Xamarin Forms for different views and platforms (Android, iOS, WinPhone)? The UI does rotate, and that is nice enough, though it wreaks havoc to my layout (absolute layout right now). I suppose with a Stacklayout I could make it a litte more flexible, but would then hit a road block somewhere else when the layout is more intricate. Can I somehow display different views for portrait and landscape, with the same ViewModel? (I am

How to deal with newline char across different platforms

浪子不回头ぞ 提交于 2019-12-11 00:05:56
问题 I have a Linux system and Windows system send text to each other and each one of them update a text file with the received text, now i have a problem when the text contain LF/CR char, i need to unify the newline char sent by both of them, i tried to use only \n (replacing \r by empty string before sending the string) but it doesn't work , is there a known solution for this issue ? 回答1: Don't unifying, just accommodate for it in every environment, like Git does. When sending from Windows to

Using Java to develop cross-platform, fonts scaling differently on different platforms

牧云@^-^@ 提交于 2019-12-10 23:08:11
问题 I am making some software for my university. A GUI is required. In the first revision of it, I had it use the System Look and Feel (so it would look like a native application within Linux/Mac/Windows). I found this to be cumbersome as I had to make all of my JLabels different sized based on the OS (regardless of resolution/pixel density/etc). After doing this I was like "okay, I'm NOT going to go through with this again" so I decided to not use the System look and feel and try out Nimbus. It

cross-platform phone development environment

帅比萌擦擦* 提交于 2019-12-10 23:00:01
问题 I'm working on guidance for development of mobile applications in a -mainly- .Net shop. How do you tackle the different platforms when developing mobile applications from the perspective of a .Net developer? What are advantages and disadvantages of these approaches? Probably the simplest approach is to just stick to web-based development (HTML5, jquery mobile, etc). But I can imagine this won't be enough for any and all applications. I have looked at Titanium, which claims to be a platform

Cross developing targeting both Java Swing and GWT

风格不统一 提交于 2019-12-10 20:54:26
问题 Does anyone know of any tool that can facilitate/ease porting of an app to both Java Swing and GWT? I've got a few "screens" that makes complete sense to have both in a desktop app and in a browser and I was wondering if there was some kind of common API that could be targeted that would facilitate creating these two different "views" (see my comment)? 回答1: I think it's entirely possible, but it would mean a different take on the server side of things. If you do interface-based POJO

Web app needs to communicate with serial port

风流意气都作罢 提交于 2019-12-10 20:33:46
问题 I'm writing an application that needs access to a serial port (it's a credit card reader). I'd like to be able to read and write to the port. The following seems like it would let me do exactly that: http://www.activexperts.com/serial-port-component/howto/html/. However, this deals with ActiveX/COM which means I'm tied to Windows. Any better solutions for me? Would be nice if the solution would work on multiple platforms, not just Windows. I'm using PHP. 回答1: Does the device emulate a

Monodevelop .Net cross platform custom drawing application

北战南征 提交于 2019-12-10 20:17:41
问题 I'm looking for good suggestions on where to start with an educational application I am designing. I want my application to be compatible with Windows and OSX - my research seems to suggest that about 40% of the audience would be using a mac. I'm keen to stick to .net/c sharp and the Mono framework. The application is reasonably simple - it would be graphical, containing a tool bar with a menu and a few buttons. The main area on screen will contain custom graphics - I would draw onto an area

How to catch exceptions with Qt platform independently?

て烟熏妆下的殇ゞ 提交于 2019-12-10 20:04:48
问题 I'm using boost::date_time in my project. When date is not valid it thorws std::out_of_range C++ exception. In Qt's gui application on windows platform it becomes SEH exception, so it doesn't catched with try|catch paradigm and programm dies. How can I catch the exception platform independently? try{ std::string ts("9999-99-99 99:99:99.999"); ptime t(time_from_string(ts)) } catch(...) { // doesn't work on windows } EDITED: If somebody didn't understand, I wrote another example: Qt pro file: