Daily Archives

Articles indexed Sunday September 9 2012

Page 8/14 | < Previous Page | 4 5 6 7 8 9 10 11 12 13 14  | Next Page >

  • Windows audio service fails to automatically start after VirtualBox install

    - by humble_coder
    I'm having a completely nonsensical issue in Windows XP SP3. Basically my "Windows Audio" service no longer starts automatically. Despite being set to "Automatic" I have to manually go in and start it. This issue didn't start until the most recent update of VirtualBox, but I can't find anything on the forums related to this specific issue. I've tried reinstalling the RealTek drivers as well, in the event that that had something to do with it. Any assistance is most appreciated! EDIT 1: It is the host's audio that won't start. The update of Virtualbox was merely the "marker" of when these events started occurring. Given it's the only variable/change I'm assuming a correlation.

    Read the article

  • Setting XFCE terminal PS1 value and making it permanent

    - by Matt
    I'm trying to add the value PS1='\u@\h: \w\$ ' to my terminal in XFCE. I added the line to (what I think is) the correct area in /etc/profile. The relevant segment is: # Set a default shell prompt: #PS1='`hostname`:`pwd`# ' PS1='\u@\h: \w\$ ' if [ "$SHELL" = "/bin/pdksh" ]; then # PS1='! $ ' PS1='\u@\h: \w\$ ' elif [ "$SHELL" = "/bin/ksh" ]; then # PS1='! ${PWD/#$HOME/~}$ ' PS1='\u@\h: \w\$ ' elif [ "$SHELL" = "/bin/zsh" ]; then # PS1='%n@%m:%~%# ' PS1='\u@\h: \w\$ ' elif [ "$SHELL" = "/bin/ash" ]; then # PS1='$ ' PS1='\u@\h: \w\$ ' else PS1='\u@\h: \w\$ ' fi Most of that was already there, I just commented out the existing value and added the one I want. By manually opening the terminal and doing . profile, I can load these values, but they don't stick - I close the terminal and reopen, and I'm back to sh-4.1$. Maybe I'm doing this in the wrong place, but how can I make that value stick? All the info I've found on google is Fedora/Ubuntu-specific. I use Slackware. Any help on this matter would be greatly appreciated.

    Read the article

  • Application windows have colossal fonts in Enlightenment 17, while system windows are untouched

    - by Matt
    I'm trying to get used to using Enlightenment instead of KDE on my Slackware64 multilib computer, but I'm having a terrible time getting one problem fixed. My fonts are HUGE on application windows - from Firefox to Gimp to Xchat to anything else, all the fonts are 3x the size they should be. But at the same time, the system menu is the correct size. I'm at a loss - I want the applications to have the same DPI as the system menu. When I'm in KDE, they all look normal. I've included a screenshot to show what I'm talking about.

    Read the article

  • Why do most routers not include local DNS?

    - by user785194
    I need to change my firewall/router, and I'd prefer something with built-in DNS to resolve queries on the local subnets. I've got a mixed Linux/Windows system, often with only one computer turned on, and I frequently have problems resolving local names. I don't want to keep a Linux box permanently on just for DNS, and I'd prefer to have DNS in my router appliance, which is always on. I search Google for this occasionally but never find anything. You always get the obvious answers - it's not possible, put everything in /etc/hosts, NetBIOS, dedicated box, etc. So what am I missing? Why don't "cheap" routers let you do this? I'm pretty sure that Cisco kit does this. Almost all cheap routers will let you do MAC address reservation, to let them assign static IP addresses for DHCP. So why can't they simply do DNS as well for everything on the local subnets, just passing through remote domains to the ISP?

    Read the article

  • How to stop switchable graphics from switching to high-power GPU when charging the laptop?

    - by Saifallah
    I've an Acer laptop with Windows 7 64 bit and an ATI Radeon HD 6550M Graphics card. Whenever I connect the power to charge the battery it automatically switches to the high-power GPU (ATI) instead of the low-power (Intel) GPU. There's an option in the bios to stop such thing but it makes the GPU runs always on high-power and I can't switch to the low-power GPU. How can I prevent the switchable graphics from automatically using the high-power GPU when charging?

    Read the article

  • What are the replacement options for an IDE hard disk for a DOS based system?

    - by dummzeuch
    I have got a few "embedded" systems running MSDOS 6.2 which boot from and store data to IDE hard disks. Since these drives are nearing their end of life, the question arises how we can replace them. The requirements are: DOS must be able to install and boot from these drives. They must be able to sustain heavy (mostly) write access. If possible, they should be able to survive moderate vibrations (not too bad since the current hard disks have survived several years of that) I considered the following options so far: other ide hard drives: Unfortunately modern IDE drives are too large so DOS cannot boot from them even if I create small partitions. Older IDE drives are just that: old, so they are probably not the most reliable ones any more. SSDs: There are a few SSDs with IDE interface available. I have not yet tried them. Does anybody have any experience with them? They look like the ideal replacement provided that DOS can boot from them and that writing speed does not deteriorate too much (the old hard disks are no race cars either). Compact Flash: There are adapters for using CF with IDE controllers and they work fine. DOS can boot from them and they have no problems at all with vibrations. What I am not sure about is their durability. DOS uses FAT so some very few sectors are written every time the medium is being written to. IDE to SATA converters: I have no idea whether they are any good. Has anybody tried them? It might be an option to use one of these to connect an SATA SSD to the system. Are there any alternatives that I have missed? (We are working on replacing these systems, but it will still take a few years.)

    Read the article

  • Uninstall Perl 5.10 and Install 5.8 on Ubuntu 10.04

    - by user48848
    I was using Ubuntu 8.04 with installed Perl 5.8.8. I had installed Bugzilla 3.4.4 with some custom scripts and it was working fine. I had to upgrade Ubuntu from 8.04 to 10.04 and automatically Perl is also upgraded from Perl 5.8 to 5.10. Now, accessing Bugzilla displays an error message related to Perl module. While trying to run checksetup.pl, I am getting the following error message: root@cvsnew:/var/www/bugzilla-3.4# perl checksetup.pl * This is Bugzilla 3.4.3 on perl 5.10.1 * Running on Linux 2.6.32-24-generic-pae #39-Ubuntu SMP Wed Jul 28 07:39:26 UTC 2010 Checking perl modules... Checking for CGI.pm (v3.33) ok: found v3.48 perl: symbol lookup error: lib/i486-linux-gnu-thread-multi/auto/Digest/SHA/SHA.so: undefined symbol: Perl_Tstack_sp_ptr Accessing Bugzilla throws : "500 Internal Server Error". I explored this issue and found that this issue has come up because upgrading Ubuntu upgrades Perl 5.8 to 5.10 automatically. It seems like Perl 5.10.1 isn't binary compatible with the previous. Now, I want to uninstall Perl 5.10.1 and Install Perl 5.8.8 on my Ubuntu 10.04 box. I will appreciate if someone has already done that or share the required steps/commands to do it.

    Read the article

  • Week in Geek: Windows 8 Users at Risk Due to Missing IE 10 Flash Update

    - by Asian Angel
    This week’s edition of WIG is filled with news link goodness covering topics such as Windows 8 Pro downgrades to Windows 7 and Vista will be possible, the Ubuntu Live CD is now dead, Guild Wars 2 is suffering an ongoing password attack, and more. HTG Explains: Is ReadyBoost Worth Using? HTG Explains: What The Windows Event Viewer Is and How You Can Use It HTG Explains: How Windows Uses The Task Scheduler for System Tasks

    Read the article

  • invite: PARTNER WEBCAST: INNOVATIONS IN PRODUCTS - PROGRAM

    - by mseika
    PARTNER WEBCAST: INNOVATIONS IN PRODUCTS - PROGRAMOCTOBER 1ST, 2012 AT 04:00 PM CET (03:00 PM GMT)Dear partner I am pleased to invite you to join the Innovations in Products – webcast. Innovations in Products will present Oracle Product's new functions and features including sales positioning. The key objectives of these webcasts are to inspire System Integrator's implementation personnel to conduct successful after sales in their Customer projects. Innovations in Products will be presented on the 1st Monday of each quarter after the billable day (4:00 to 5:00 PM CET). The webcast is intended for System Integrator's Implementation Certified Specialists but Innovations in Products is open for other system Integrator's personnel as well. At first, two Oracle representatives will discuss Oracle's contribution to partners. Then you will see product breakout session followed by Q&A with Oracle Experts. Each session will last for maximum 1 hour. A Q&A document covering all questions and answers will be made available after the webcast. What are the Benefits for partners? Find out how Innovations in Products helps you to improve your after sales Discover new functions and features so you can enrich your Customers's solution Learn more about Oracle products, especially sales positioning Hear crucial questions raised by colleague alike, learn from their interest Engage and present your questions to subject experts Be inspired of the richness of Oracle's product portfolio – for your and your customer’s benefit. Note: Should you already be familiar with a specific Product, then choose another one. Doing so you would expand your knowledge of the overall product portfolio. Some presentations contain product demonstration, although these presentations are not intended to be extremely detailed technical presentations. Product breakout sessions available on October 1st - please click here.  To access previously presented 23 Applications Products presentations and 6 Public Sector Value Proposition presentations, please click here. You might want to bookmark the overall registration page Innovations in Products October 1st and the global event calendar page events.oracle.com. Delivery Format Innovations in Products – program is a series of FREE prerecorded Oracle product presentations followed by Q&A. It will be delivered over the Web. Participants have the opportunity to submit questions during the web cast via chat and subject matter experts will provide verbal answers live. Innovations in Products consists of several parallel prerecorded product breakout sessions, each lasting for max. 1 hour. At first, two Oracle representatives will discuss Oracle’s contribution to Partners. Then you’ll see the product breakout sessions followed by Q&A with Oracle Experts. A Q&A document covering all questions and answers will be made available after the webcast. You can also see Innovations in Products afterwards as its content will be available online for the next 6-12 months.The next Innovations in Products web casts will be presented as follows: October 1st 2012 January 14th 2013 April 8th 2013. Note: Depending on local network bandwidth please allow some seconds time the presentations to download. You might want to refresh your screen by pressing F5. DurationMaximum 1 hour For further information please contact me Markku Rouhiainen. Best regards Markku RouhiainenDirector, Applications Partner Enablement EMEA

    Read the article

  • Oracle Application in DMZ (Demilitarized Zone)

    - by PRajkumar
     Business Needs Large Organizations want to expose their Oracle Application services outside their private network (HTTP/HTTPS and SSL). Usually these exposures must exist to promote external communication. So they want to separate an external network from directly referencing an internal network   Business Challenges ·         Business does not want to compromise with security information ·         Business cannot expose internal domain or internal URL information   Business Solution DMZ is the solution of this problem. In Oracle application we can achieve this by following way –   ·         Oracle Application consists of fleet nodes (FND_NODES) so first decide which node have to expose to public ·         To expose the node to public use the profile “Node Trust Level” ·         Set node to Public/Private (Normal -> private, External -> public) ·         Set "Responsibility Trust Level" profile to decide whether to expose Application Responsibility to inside or outside firewall         Solution Features   ·         Exposed web services can be accessed by both internal and external users ·         Configurable and can be very easily rolled out ·         Internal network and business data is secured from outside traffic ·         Unauthorized access to internal network from outside is prohibited ·         No need for VPN and Secure FTP server   Benefits  ·       Large Organizations having Oracle Application can expose their web services like (HTTP/HTTPS and SSL) to the internet without compromise with security information and without exposing their internal domain   Possible Week Points  ·         If external firewall is compromised, then external application server is also compromised, exposing an attack on E-Business Suite database ·         There’s nothing to prevent internal users from attacking internal application server, also exposing an attack on E-Business Suite database   Reference Links  ·         https://blogs.oracle.com/manojmadhusoodanan/tags/dmz

    Read the article

  • 24 Hours of PASS coming up soon!

    - by Rob Farley
    Massive thanks to all the people that have been shouting about this event already. I’ve seen quite a number of blog posts about it, and rather than listing some and missing others, please assume I’ve noticed your blog and accept my thanks. But in case this is all news to you – the next 24 Hours of PASS event is less than a fortnight away (Sep 20/21)! And there’s lots of info about it at http://www.sqlpass.org/24hours/fall2012/  (Don’t ask why it’s “Fall 2012”. Apparently that’s what this time of year is called in at least two countries. I would call it “Spring”, personally, but do appreciate that it’s “Autumn” in the Northern Hemisphere...) Yes, I blogged about it on the PASS blog a few weeks ago, but haven’t got around to writing about it here yet. As always, 24HOP is going to have some amazing content. But it’s going to be pointing at the larger event, which now less than two months away. That’s right, this 24HOP is the Summit 2012 Preview event. Most of the precon speakers are going to be represented, as are half-day session presenters, quite a few of the Spotlight presenters and some of the Microsoft speakers too. When you look down the list of sessions at http://www.sqlpass.org/24hours/fall2012/SessionsbySchedule.aspx, you’ll find yourself wondering how you can fit them all in. Luckily, that’s not my problem. For me, it’s just about making sure that you can get to hear these people present, and get a taste for the amazing time that you’ll have if you can come to the Summit. I see this 24HOP as the kind of thing that will just drive you crazy if you can’t get to the Summit. There will be so much great content, and every one of these presenters will be delivering even more than this at the Summit itself. If you tune into Jason Strate’s 24HOP session on the Plan Cache and are impressed – well, you can get to a longer session by him on that same topic at the Summit. And the same goes for all of them. If you’re anything like me, you’ll find yourself looking at the Summit schedule, wishing you could get to several presentations for every time slot. So get yourself registered for 24HOP and help yourself make that decision. And if you can’t go to the Summit, tune in anyway. You’ll still learn a lot, and you might just be able to help persuade someone to send you to the Summit after all (before the price goes up after Sep 30).

    Read the article

  • How can I implement a database TableView like thing in C++?

    - by Industrial-antidepressant
    How can I implement a TableView like thing in C++? I want to emulating a tiny relation database like thing in C++. I have data tables, and I want to transform it somehow, so I need a TableView like class. I want filtering, sorting, freely add and remove items and transforming (ex. view as UPPERCASE and so on). The whole thing is inside a GUI application, so datatables and views are attached to a GUI (or HTML or something). So how can I identify an item in the view? How can I signal it when the table is changed? Is there some design pattern for this? Here is a simple table, and a simple data item: #include <string> #include <boost/multi_index_container.hpp> #include <boost/multi_index/member.hpp> #include <boost/multi_index/ordered_index.hpp> #include <boost/multi_index/random_access_index.hpp> using boost::multi_index_container; using namespace boost::multi_index; struct Data { Data() {} int id; std::string name; }; struct row{}; struct id{}; struct name{}; typedef boost::multi_index_container< Data, indexed_by< random_access<tag<row> >, ordered_unique<tag<id>, member<Data, int, &Data::id> >, ordered_unique<tag<name>, member<Data, std::string, &Data::name> > > > TDataTable; class DataTable { public: typedef Data item_type; typedef TDataTable::value_type value_type; typedef TDataTable::const_reference const_reference; typedef TDataTable::index<row>::type TRowIndex; typedef TDataTable::index<id>::type TIdIndex; typedef TDataTable::index<name>::type TNameIndex; typedef TRowIndex::iterator iterator; DataTable() : row_index(rule_table.get<row>()), id_index(rule_table.get<id>()), name_index(rule_table.get<name>()), row_index_writeable(rule_table.get<row>()) { } TDataTable::const_reference operator[](TDataTable::size_type n) const { return rule_table[n]; } std::pair<iterator,bool> push_back(const value_type& x) { return row_index_writeable.push_back(x); } iterator erase(iterator position) { return row_index_writeable.erase(position); } bool replace(iterator position,const value_type& x) { return row_index_writeable.replace(position, x); } template<typename InputIterator> void rearrange(InputIterator first) { return row_index_writeable.rearrange(first); } void print_table() const; unsigned size() const { return row_index.size(); } TDataTable rule_table; const TRowIndex& row_index; const TIdIndex& id_index; const TNameIndex& name_index; private: TRowIndex& row_index_writeable; }; class DataTableView { DataTableView(const DataTable& source_table) {} // How can I implement this? // I want filtering, sorting, signaling upper GUI layer, and sorting, and ... }; int main() { Data data1; data1.id = 1; data1.name = "name1"; Data data2; data2.id = 2; data2.name = "name2"; DataTable table; table.push_back(data1); DataTable::iterator it1 = table.row_index.iterator_to(table[0]); table.erase(it1); table.push_back(data1); Data new_data(table[0]); new_data.name = "new_name"; table.replace(table.row_index.iterator_to(table[0]), new_data); for (unsigned i = 0; i < table.size(); ++i) std::cout << table[i].name << std::endl; #if 0 // using scenarios: DataTableView table_view(table); table_view.fill_from_source(); // synchronization with source table_view.remove(data_item1); // remove item from view table_view.add(data_item2); // add item from source table table_view.filter(filterfunc); // filtering table_view.sort(sortfunc); // sorting // modifying from source_able, hot to signal the table_view? // FYI: Table view is atteched to a GUI item table.erase(data); table.replace(data); #endif return 0; }

    Read the article

  • Defining formula through user interface in user form

    - by BriskLabs Pakistan
    I am a student and developing a simple assignment - windows form application in visual studio 2010. The application is suppose to construct formulas as per user requirement. The process: It has to pick data from columns of Microsoft Access database and the user should be able to pick the data by column name like we do in a drop down menu. and create reusable formulas in it ( configure it once and can change it again). followings are column titles from database that can be picked for example. e.g Col -1 : Marks in Maths Col -2 : Total Marks in Maths Col -3 : Marks in science Col -4 : Total marks in science Finally we should be able to construct any formula in the UI like (Col 1 + Col 3 ) / ( col 2 + col 4) = Formula 1 once this is formula is set saved and a name is assigned to it by user. he/she can use the formula and results shall appear in a window below. i.e He would be able to calculate his desired figures (formula) by only manipulating underlying data on the UI layer....choose the data for a period and apply the formula and get the answer Problem: It looks like I have to create an app where rules are set through UI....... this means no stored procedures are required in SQL.... please suggest the right approach.

    Read the article

  • Is catching general exceptions really a bad thing?

    - by Bob Horn
    I typically agree with most code analysis warnings, and I try to adhere to them. However, I'm having a harder time with this one: CA1031: Do not catch general exception types I understand the rationale for this rule. But, in practice, if I want to take the same action regardless of the exception thrown, why would I handle each one specifically? Furthermore, if I handle specific exceptions, what if the code I'm calling changes to throw a new exception in the future? Now I have to change my code to handle that new exception. Whereas if I simply caught Exception my code doesn't have to change. For example, if Foo calls Bar, and Foo needs to stop processing regardless of the type of exception thrown by Bar, is there any advantage in being specific about the type of exception I'm catching?

    Read the article

  • Super constructor must be a first statement in Java constructor [closed]

    - by Val
    I know the answer: "we need rules to prevent shooting into your own foot". Ok, I make millions of programming mistakes every day. To be prevented, we need one simple rule: prohibit all JLS and do not use Java. If we explain everything by "not shooting your foot", this is reasonable. But there is not much reason is such reason. When I programmed in Delphy, I always wanted the compiler to check me if I read uninitializable. I have discovered myself that is is stupid to read uncertain variable because it leads unpredictable result and is errorenous obviously. By just looking at the code I could see if there is an error. I wished if compiler could do this job. It is also a reliable signal of programming error if function does not return any value. But I never wanted it do enforce me the super constructor first. Why? You say that constructors just initialize fields. Super fields are derived; extra fields are introduced. From the goal point of view, it does not matter in which order you initialize the variables. I have studied parallel architectures and can say that all the fields can even be assigned in parallel... What? Do you want to use the unitialized fields? Stupid people always want to take away our freedoms and break the JLS rules the God gives to us! Please, policeman, take away that person! Where do I say so? I'm just saying only about initializing/assigning, not using the fields. Java compiler already defends me from the mistake of accessing notinitialized. Some cases sneak but this example shows how this stupid rule does not save us from the read-accessing incompletely initialized in construction: public class BadSuper { String field; public String toString() { return "field = " + field; } public BadSuper(String val) { field = val; // yea, superfirst does not protect from accessing // inconstructed subclass fields. Subclass constr // must be called before super()! System.err.println(this); } } public class BadPost extends BadSuper { Object o; public BadPost(Object o) { super("str"); this. o = o; } public String toString() { // superconstructor will boom here, because o is not initialized! return super.toString() + ", obj = " + o.toString(); } public static void main(String[] args) { new BadSuper("test 1"); new BadPost(new Object()); } } It shows that actually, subfields have to be inilialized before the supreclass! Meantime, java requirement "saves" us from writing specializing the class by specializing what the super constructor argument is, public class MyKryo extends Kryo { class MyClassResolver extends DefaultClassResolver { public Registration register(Registration registration) { System.out.println(MyKryo.this.getDepth()); return super.register(registration); } } MyKryo() { // cannot instantiate MyClassResolver in super super(new MyClassResolver(), new MapReferenceResolver()); } } Try to make it compilable. It is always pain. Especially, when you cannot assign the argument later. Initialization order is not important for initialization in general. I could understand that you should not use super methods before initializing super. But, the requirement for super to be the first statement is different. It only saves you from the code that does useful things simply. I do not see how this adds safety. Actually, safety is degraded because we need to use ugly workarounds. Doing post-initialization, outside the constructors also degrades safety (otherwise, why do we need constructors?) and defeats the java final safety reenforcer. To conclude Reading not initialized is a bug. Initialization order is not important from the computer science point of view. Doing initalization or computations in different order is not a bug. Reenforcing read-access to not initialized is good but compilers fail to detect all such bugs Making super the first does not solve the problem as it "Prevents" shooting into right things but not into the foot It requires to invent workarounds, where, because of complexity of analysis, it is easier to shoot into the foot doing post-initialization outside the constructors degrades safety (otherwise, why do we need constructors?) and that degrade safety by defeating final access modifier When there was java forum alive, java bigots attecked me for these thoughts. Particularly, they dislaked that fields can be initialized in parallel, saying that natural development ensures correctness. When I replied that you could use an advanced engineering to create a human right away, without "developing" any ape first, and it still be an ape, they stopped to listen me. Cos modern technology cannot afford it. Ok, Take something simpler. How do you produce a Renault? Should you construct an Automobile first? No, you start by producing a Renault and, once completed, you'll see that this is an automobile. So, the requirement to produce fields in "natural order" is unnatural. In case of alarmclock or armchair, which are still chair and clock, you may need first develop the base (clock and chair) and then add extra. So, I can have examples where superfields must be initialized first and, oppositely, when they need to be initialized later. The order does not exist in advance. So, the compiler cannot be aware of the proper order. Only programmer/constructor knows is. Compiler should not take more responsibility and enforce the wrong order onto programmer. Saying that I cannot initialize some fields because I did not ininialized the others is like "you cannot initialize the thing because it is not initialized". This is a kind of argument we have. So, to conclude once more, the feature that "protects" me from doing things in simple and right way in order to enforce something that does not add noticeably to the bug elimination at that is a strongly negative thing and it pisses me off, altogether with the all the arguments to support it I've seen so far. It is "a conceptual question about software development" Should there be the requirement to call super() first or not. I do not know. If you do or have an idea, you have place to answer. I think that I have provided enough arguments against this feature. Lets appreciate the ones who benefit form it. Let it just be something more than simple abstract and stupid "write your own language" or "protection" kind of argument. Why do we need it in the language that I am going to develop?

    Read the article

  • One page using querystring or many folders and pages?

    - by ClarkeyBoy
    I have an application where I have the 'core' code in one folder for which there is a virtual directory in the root, such that I can include any core files using /myApp/core/bla.asp. I then have two folders outside of this with a default.asp which currently use the querystring to define what page should be displayed. One page is for general users, the other will only be accessible to users who have permission to manage users / usergroups / permissions. The core code checks the querystring and then checks the permissions for that user. An example of this as it is now is default.asp?action=view&viewtype=list&objectid=server. I am not worried about SEO as this is an internal app and uses Windows Auth. My question is, is it better the way it is now or would it be better to have something like the following: /server/view/list/ /server/view/?id=123 /server/create/ /server/edit/?id=123 /server/remove/?id=123 In the above folders I would have a home page which defines all the variables which are currently determined by the querystring - in /server/create/ for example, I would define the action as 'create', object name as 'server' and so on. In terms of future development, I really have no idea which method would be best. I think the 2nd method would be best in terms of following what page does what but this is such a huge change to make at this stage that I would really like some opinions, preferably based on experience. PS Sorry if the tags are wrong - I am new to this forum and thought this was a bit too much of a discussion for StackOverflow as that is very much right / wrong answer based. I got the idea SE is more discussion based.

    Read the article

  • Data classes: getters and setters or different method design

    - by Frog
    I've been trying to design an interface for a data class I'm writing. This class stores styles for characters, for example whether the character is bold, italic or underlined. But also the font-size and the font-family. So it has different types of member variables. The easiest way to implement this would be to add getters and setters for every member variable, but this just feels wrong to me. It feels way more logical (and more OOP) to call style.format(BOLD, true) instead of style.setBold(true). So to use logical methods insteads of getters/setters. But I am facing two problems while implementing these methods: I would need a big switch statement with all member variables, since you can't access a variable by the contents of a string in C++. Moreover, you can't overload by return type, which means you can't write one getter like style.getFormatting(BOLD) (I know there are some tricks to do this, but these don't allow for parameters, which I would obviously need). However, if I would implement getters and setters, there are also issues. I would have to duplicate quite some code because styles can also have a parent styles, which means the getters have to look not only at the member variables of this style, but also at the variables of the parent styles. Because I wasn't able to figure out how to do this, I decided to ask a question a couple of weeks ago. See Object Oriented Programming: getters/setters or logical names. But in that question I didn't stress it would be just a data object and that I'm not making a text rendering engine, which was the reason one of the people that answered suggested I ask another question while making that clear (because his solution, the decorator pattern, isn't suitable for my problem). So please note that I'm not creating my own text rendering engine, I just use these classes to store data. Because I still haven't been able to find a solution to this problem I'd like to ask this question again: how would you design a styles class like this? And why would you do that? Thanks on forehand!

    Read the article

  • Can we ask idea of software?

    - by jailed abroad
    I am new to Programmers Stack Exchange. I have read the faq. I have a basic question here that can I ask about the idea of developing software. Just for sake of example, I have started a job in software house and my CEO hands me a project. And I have no idea or flow chart in my mind through which I would develop that application. For example client needs an E-diary. I have idea of WPF but lacking flow of app. So my question is can I ask about the app that "what would be the idea to develop the application"?

    Read the article

  • Learning Java for electrical engineering [closed]

    - by MohdAziz
    I'm an electrical engineering student ( Power, control & instrumentation). 2 months ago I started learning C, and I found programming something really enjoyable and I'd like to continue learning C and few other programming languages along with my electrical engineering degree. So my university is offering an extensive Java Oracle course for 7 days (like 5-6 hours a day) for a really decent price, do you think as an electrical engineer this would help me in my future career? What are the benefits of learning Java for an electrical engineer of my specialization? Do you think it's a good idea for someone in my case to take such an extensive course? I'm hardworker and I really enjoy these things, so I don't think that would be a problem for me.

    Read the article

  • Design patterns and multiple programming languages

    - by Eduard Florinescu
    I am referring here to the design patterns found in the GOF book. First, how I see it, there are a few peculiarities to design pattern and knowing multiple languages, for example in Java you really need a singleton but in Python you can do without it you write a module, I saw somewhere a wiki trying to write all GOF patterns for JavaScript and all the entries were empty, I guess because it might be a daunting task to do that adaptation. If there is someone who is using design patterns and is programming multiple languages supporting the OOP paradigm and can give me a hint on how should I approach design patterns. An approach that might help me in all languages I use(Java, JavaScript, Python, Ruby): Can I write good application without knowing exactly the GOF design patterns or I might need just some of them which might be crucial and if yes which one, are there alternatives to GOF for specific languages, and should a programmer or a team make their own design patterns set?

    Read the article

  • Build automation: Is it usual to use QMake for non-Qt projects?

    - by Raphael
    So, I'm planning to write a C++ library and I want it to be cross-platform, and as this library won't deal with UI and I want it to have as little dependencies as possible, I won't be using Qt (actually Qt won't really help me to achieve what I want, all I plan on using is STL and Boost). Now when it comes to build a cross-platform project, I really like QMake as it's extremely easy to use and I have experience with it. I also heard good things about CMake, though I really doubt it's as easy to use as QMake. Anyway, here is my question: Should I stick with build automation tool that I know or is QMake just out of context for a non-Qt project? Should I take this as an opportunity to learn CMake? Or is there a better alternative to these two?

    Read the article

  • I can't get ubunutu installation to start

    - by tyler
    AZUS Sabertooth Motherboard, Intel I5 2500 CPU, Windows 7 installed I'm trying to install linux. I first attempted to install pin guy. I burned the ISO; booted from it; got the initial menu; attempting either run the live version from DVD, or install to system; the process stops at a blank screen with the blinking cursor in left corner. So I downloaded Ubuntu and got the same results. Then tried wubi, and ended up in the same position; blinking cursor in left corner.

    Read the article

  • How can I use a CanoScan N640Pex scanner over a USB/parallel cable?

    - by detly
    I have an old CanoScan N640Pex flat bed scanner and a USB-to-parallel port cable through which I can connect it to my PC. Unfortunately neither Simple Scan nor XSane detect the scanner. I'm running Ubuntu 12.04 (plus updates and backports) with kernel 3.2.0-31-generic. dmesg tells me this when I plus the cable in: [256411.641910] usb 7-1: new full-speed USB device number 10 using uhci_hcd [256411.872392] usblp0: USB Bidirectional printer dev 10 if 0 alt 1 proto 2 vid 0x067B pid 0x2305 [256411.872417] usbcore: registered new interface driver usblp lsusb shows this device for my cable: Bus 007 Device 010: ID 067b:2305 Prolific Technology, Inc. PL2305 Parallel Port The device node created is /dev/usb/lp0 crw-rw---- 1 root lp 180, 0 Sep 9 17:46 /dev/usb/lp0 There is no extra information from any of these commands when I attach the scanner to the cable and power it on, though. I suspect I might need to change something in /etc/sane.d/canon_pp.conf, but I have no idea what to put for the ieee1284 line, since there is pretty much zero documentation for that parameter. So how can I get it to work?

    Read the article

  • Custom trackpad mapping doesn't work for all applications

    - by picheto
    I found out I could invert my trackpad scrolling, so as to work more like the OS X "natural scrolling", which I liked better. To do that, I run the following command on startup: xinput set-button-map 11 1 2 3 5 4 7 6 Where 11 is the touchpad id (found with xinput list and xinput test 11). This inverts the vertical and horizontal two-finger scrolling, and works fine in Terminal, Chrome, Document Viewer, etc. However, it doesn't work in Nautilus and some applications such as the Update Manager, as they keep the usual mapping. I'm running Ubuntu 12.04 x64 Why does this mapping work for some applications but not for others? I know there is software I can download to do the same, but this method seemed "cleaner". Thanks

    Read the article

  • Periodic script execution

    - by Vagelism
    I made a script that sends my local sensors temperature to a server in the internet and then I can see a graph of it. Everything works fine when I execute it manully. I have the latest ubuntu version. When it comes to run periodically every minute with crontab then nothing works. It doesnt send anything. I tried to run it as SUDO and as user, I tried to add it in the crontab file to run it from several locations like /bin/myscript.sh , /user/Desktop and many others...Nothing seems to work. Any Idea how to solve it? Thank you!

    Read the article

< Previous Page | 4 5 6 7 8 9 10 11 12 13 14  | Next Page >